From 94822bf51dd59e6f63fddfc0c025b72f0a398bd3 Mon Sep 17 00:00:00 2001 From: Petro Kurbatskyi Date: Thu, 14 Mar 2024 14:21:23 +0100 Subject: [PATCH 1/5] Set up branch to become 5.0 in the future --- composer.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/composer.json b/composer.json index a21a6269..d2b62487 100644 --- a/composer.json +++ b/composer.json @@ -30,7 +30,7 @@ "ext-libxml": "*", "ext-simplexml": "*", "ext-xmlwriter": "*", - "ibexa/core": "~4.6.0@dev", + "ibexa/core": "~5.0.0@dev", "symfony/http-kernel": "^5.3", "symfony/dependency-injection": "^5.3", "symfony/routing": "^5.3", @@ -47,7 +47,7 @@ }, "require-dev": { "ibexa/ci-scripts": "^0.2@dev", - "ibexa/doctrine-schema": "~4.6.0@dev", + "ibexa/doctrine-schema": "~5.0.0@dev", "ibexa/code-style": "^1.0", "ibexa/test-core": "^0.1.x-dev", "friendsofphp/php-cs-fixer": "^3.0", @@ -79,7 +79,7 @@ }, "extra": { "branch-alias": { - "dev-main": "4.6.x-dev" + "dev-main": "5.0.x-dev" } } } From 5e3f35aaf951086d214e1caf54a377bab87c4173 Mon Sep 17 00:00:00 2001 From: Petro Kurbatskyi Date: Wed, 27 Mar 2024 15:45:12 +0100 Subject: [PATCH 2/5] Removed repository-wide pull request template --- .github/pull_request_template.md | 15 --------------- 1 file changed, 15 deletions(-) delete mode 100644 .github/pull_request_template.md diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md deleted file mode 100644 index 55faee54..00000000 --- a/.github/pull_request_template.md +++ /dev/null @@ -1,15 +0,0 @@ -| Question | Answer -| ------------------ | ------------------ -| **JIRA issue** | [IBX-XXXXX](https://issues.ibexa.co/browse/IBX-XXXXX) -| **Type**| bug/feature/improvement -| **Target version** | e.g.: Ibexa `v4.0` -| **BC breaks** | yes/no -| **Tests pass** | yes/no -| **Doc needed** | yes/no - - - -**TODO**: -- [ ] Implement tests. -- [ ] Fix new code according to Coding Standards (`$ composer fix-cs`). -- [ ] Ask for Code Review. From e272fe246d6e85105b0cb08b331c5a28606f455a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Niedzielski?= Date: Fri, 26 Apr 2024 20:43:01 +0200 Subject: [PATCH 3/5] IBX-8119: Upgraded minimum PHP version to 8.3 https://github.com/ibexa/rest/pull/89 --- .github/workflows/ci.yaml | 14 +++---- .../workflows/integration-tests-callable.yaml | 8 ++-- composer.json | 39 ++++++++++--------- 3 files changed, 30 insertions(+), 31 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index e7f7db8e..c1f82d73 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -12,17 +12,17 @@ jobs: name: Run code style check runs-on: "ubuntu-22.04" steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Setup PHP Action uses: shivammathur/setup-php@v2 with: - php-version: '8.1' + php-version: '8.3' coverage: none extensions: 'pdo_sqlite, gd' tools: cs2pr - - uses: ramsey/composer-install@v2 + - uses: ramsey/composer-install@v3 with: dependency-versions: highest @@ -38,12 +38,10 @@ jobs: fail-fast: false matrix: php: - - '7.4' - - '8.0' - - '8.2' + - '8.3' steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Setup PHP Action uses: shivammathur/setup-php@v2 @@ -53,7 +51,7 @@ jobs: extensions: pdo_sqlite, gd tools: cs2pr - - uses: ramsey/composer-install@v2 + - uses: ramsey/composer-install@v3 with: dependency-versions: highest diff --git a/.github/workflows/integration-tests-callable.yaml b/.github/workflows/integration-tests-callable.yaml index f5104348..cd20c3b5 100644 --- a/.github/workflows/integration-tests-callable.yaml +++ b/.github/workflows/integration-tests-callable.yaml @@ -16,7 +16,7 @@ jobs: timeout-minutes: 15 steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 - name: Set project version run: | @@ -26,14 +26,14 @@ jobs: - name: Setup PHP Action uses: shivammathur/setup-php@v2 with: - php-version: 7.4 + php-version: 8.3 coverage: none - name: Cache dependencies uses: actions/cache@v2 with: path: ${{ env.COMPOSER_CACHE_DIR }} - key: ${{ env.PROJECT_EDITION }}-${{ env.version }}-${{ github.sha }} + key: "${{ env.PROJECT_EDITION }}-${{ env.version }}-${{ github.sha }}" restore-keys: | ${{ env.PROJECT_EDITION }}-${{ env.version }} @@ -41,7 +41,7 @@ jobs: run: | curl -L "https://raw.githubusercontent.com/ibexa/ci-scripts/main/bin/${{ env.version }}/prepare_project_edition.sh" > prepare_project_edition.sh chmod +x prepare_project_edition.sh - ./prepare_project_edition.sh ${{ env.PROJECT_EDITION }} ${{ env.version }} ${{ env.SETUP }} + ./prepare_project_edition.sh ${{ env.PROJECT_EDITION }} ${{ env.version }} ${{ env.SETUP }} ghcr.io/ibexa/docker/php:8.3-node18 - name: Run setup command run: | diff --git a/composer.json b/composer.json index d2b62487..1f3998c3 100644 --- a/composer.json +++ b/composer.json @@ -24,50 +24,51 @@ } }, "require": { - "php": "^7.4 || ^8.0", + "php": " >=8.3", "ext-dom": "*", "ext-json": "*", "ext-libxml": "*", "ext-simplexml": "*", "ext-xmlwriter": "*", - "ibexa/core": "~5.0.0@dev", - "symfony/http-kernel": "^5.3", - "symfony/dependency-injection": "^5.3", - "symfony/routing": "^5.3", - "symfony/http-foundation": "^5.3", + "ibexa/core": "~5.0.x-dev", + "ibexa/templated-uri-bundle": "^3.2", + "lexik/jwt-authentication-bundle": "^2.8", "symfony/config": "^5.3", - "symfony/yaml": "^5.3", + "symfony/dependency-injection": "^5.3", "symfony/event-dispatcher": "^5.3", - "symfony/security-csrf": "^5.3", "symfony/expression-language": "^5.3", "symfony/form": "^5.3", + "symfony/http-foundation": "^5.3", + "symfony/http-kernel": "^5.3", + "symfony/routing": "^5.3", "symfony/security-bundle": "^5.3", - "ibexa/templated-uri-bundle": "^3.2", - "lexik/jwt-authentication-bundle": "^2.8" + "symfony/security-csrf": "^5.3", + "symfony/yaml": "^5.3" }, "require-dev": { + "friendsofphp/php-cs-fixer": "^3.0", "ibexa/ci-scripts": "^0.2@dev", - "ibexa/doctrine-schema": "~5.0.0@dev", "ibexa/code-style": "^1.0", + "ibexa/doctrine-schema": "~5.0.x-dev", "ibexa/test-core": "^0.1.x-dev", - "friendsofphp/php-cs-fixer": "^3.0", - "phpunit/phpunit": "^8.5", + "justinrainbow/json-schema": "^5.2", "matthiasnoback/symfony-dependency-injection-test": "^4.1", "nyholm/psr7": "^1.1", - "symfony/http-client": "^5.3", - "symfony/browser-kit": "^5.3", - "justinrainbow/json-schema": "^5.2", "phpstan/phpstan": "^1.10", - "phpstan/phpstan-symfony": "^1.3", "phpstan/phpstan-phpunit": "^1.3", - "phpstan/phpstan-webmozart-assert": "^1.2" + "phpstan/phpstan-symfony": "^1.3", + "phpstan/phpstan-webmozart-assert": "^1.2", + "phpunit/phpunit": "^8.5", + "symfony/browser-kit": "^5.3", + "symfony/http-client": "^5.3" }, "config": { "allow-plugins": { "composer/package-versions-deprecated": true, "*": false }, - "process-timeout": 600 + "process-timeout": 600, + "sort-packages": true }, "scripts": { "fix-cs": "php-cs-fixer fix --config=.php-cs-fixer.php -v --show-progress=dots", From cf7d4434834fdcf294d34fa97a9f62f9ddfff352 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Niedzielski?= Date: Fri, 10 May 2024 09:32:42 +0200 Subject: [PATCH 4/5] IBX-8121: Fixed code style for 5.0 https://github.com/ibexa/rest/pull/91 --- composer.json | 5 +- phpunit.functional.xml | 3 +- phpunit.integration.xml | 3 +- phpunit.xml | 3 +- src/bundle/ApiLoader/Factory.php | 1 + src/bundle/CorsOptions/RestProvider.php | 1 + .../Compiler/FieldTypeProcessorPass.php | 1 + .../Compiler/InputHandlerPass.php | 1 + .../Compiler/InputParserPass.php | 1 + .../Compiler/OutputVisitorPass.php | 1 + .../Compiler/ValueObjectVisitorPass.php | 1 + .../DependencyInjection/Configuration.php | 1 + .../IbexaRestExtension.php | 1 + .../Security/RestSessionBasedFactory.php | 1 + src/bundle/EventListener/CsrfListener.php | 1 + src/bundle/EventListener/RequestListener.php | 1 + src/bundle/EventListener/ResponseListener.php | 1 + src/bundle/IbexaRestBundle.php | 1 + src/bundle/RequestParser/Router.php | 1 + src/bundle/RestEvents.php | 1 + src/bundle/Routing/OptionsLoader.php | 1 + src/bundle/Routing/OptionsLoader/Mapper.php | 1 + .../OptionsLoader/RouteCollectionMapper.php | 1 + .../Exceptions/ForbiddenException.php | 1 + .../Exceptions/InvalidArgumentException.php | 1 + .../Exceptions/NotFoundException.php | 1 + src/contracts/Exceptions/Parser.php | 1 + src/contracts/FieldTypeProcessor.php | 1 + src/contracts/Input/Handler.php | 1 + src/contracts/Input/Parser.php | 1 + src/contracts/Input/ParsingDispatcher.php | 1 + .../Exceptions/InvalidTypeException.php | 1 + .../Exceptions/NoVisitorFoundException.php | 1 + .../Exceptions/OutputGeneratorException.php | 1 + src/contracts/Output/Generator.php | 1 + src/contracts/Output/ValueObjectVisitor.php | 1 + .../Output/ValueObjectVisitorDispatcher.php | 1 + src/contracts/Output/Visitor.php | 1 + .../FieldTypeProcessor/AuthorProcessor.php | 1 + .../BaseRelationProcessor.php | 1 + .../BinaryInputProcessor.php | 1 + .../FieldTypeProcessor/BinaryProcessor.php | 1 + .../DateAndTimeProcessor.php | 1 + src/lib/FieldTypeProcessor/DateProcessor.php | 1 + src/lib/FieldTypeProcessor/FloatProcessor.php | 1 + src/lib/FieldTypeProcessor/ImageProcessor.php | 1 + src/lib/FieldTypeProcessor/MediaProcessor.php | 1 + .../RelationListProcessor.php | 1 + .../FieldTypeProcessor/RelationProcessor.php | 1 + .../FieldTypeProcessor/StringProcessor.php | 1 + src/lib/FieldTypeProcessor/TimeProcessor.php | 1 + src/lib/FieldTypeProcessor/UserProcessor.php | 1 + src/lib/FieldTypeProcessorRegistry.php | 1 + src/lib/Input/BaseParser.php | 1 + src/lib/Input/Dispatcher.php | 1 + src/lib/Input/FieldTypeParser.php | 1 + src/lib/Input/Handler/Json.php | 1 + src/lib/Input/Handler/Xml.php | 1 + src/lib/Input/Parser/ContentObjectStates.php | 1 + src/lib/Input/ParserTools.php | 1 + src/lib/Message.php | 1 + src/lib/Output/FieldTypeSerializer.php | 1 + src/lib/Output/Generator/Json.php | 1 + src/lib/Output/Generator/Json/ArrayObject.php | 1 + .../Generator/Json/FieldTypeHashGenerator.php | 1 + src/lib/Output/Generator/Json/JsonObject.php | 1 + src/lib/Output/Generator/Xml.php | 1 + .../Generator/Xml/FieldTypeHashGenerator.php | 1 + .../ContentObjectStates.php | 1 + src/lib/RequestParser.php | 1 + src/lib/RequestParser/EzPublish.php | 2 + src/lib/RequestParser/Pattern.php | 1 + src/lib/Server/Controller.php | 1 + src/lib/Server/Controller/BinaryContent.php | 1 + src/lib/Server/Controller/Content.php | 1 + src/lib/Server/Controller/ContentType.php | 1 + src/lib/Server/Controller/Location.php | 1 + src/lib/Server/Controller/ObjectState.php | 1 + src/lib/Server/Controller/Options.php | 1 + src/lib/Server/Controller/Role.php | 1 + src/lib/Server/Controller/Root.php | 1 + src/lib/Server/Controller/Section.php | 1 + src/lib/Server/Controller/Services.php | 1 + .../Server/Controller/SessionController.php | 1 + src/lib/Server/Controller/Trash.php | 1 + src/lib/Server/Controller/URLAlias.php | 1 + src/lib/Server/Controller/URLWildcard.php | 1 + src/lib/Server/Controller/User.php | 1 + src/lib/Server/Controller/Views.php | 1 + .../AuthenticationFailedException.php | 1 + .../Server/Exceptions/BadRequestException.php | 1 + .../ContentFieldValidationException.php | 1 + .../Server/Exceptions/ForbiddenException.php | 1 + .../Exceptions/InvalidUserTypeException.php | 1 + .../Exceptions/UserConflictException.php | 1 + src/lib/Server/Input/Parser/ContentCreate.php | 1 + src/lib/Server/Input/Parser/ContentQuery.php | 1 + .../Server/Input/Parser/ContentTypeCreate.php | 1 + .../Input/Parser/ContentTypeGroupInput.php | 1 + .../Server/Input/Parser/ContentTypeUpdate.php | 1 + src/lib/Server/Input/Parser/ContentUpdate.php | 1 + src/lib/Server/Input/Parser/Criterion.php | 1 + .../Input/Parser/Criterion/Ancestor.php | 1 + .../Input/Parser/Criterion/ContentId.php | 1 + .../Parser/Criterion/ContentRemoteId.php | 1 + .../Parser/Criterion/ContentTypeGroupId.php | 1 + .../Input/Parser/Criterion/ContentTypeId.php | 1 + .../Criterion/ContentTypeIdentifier.php | 1 + .../Input/Parser/Criterion/DateMetadata.php | 1 + .../Server/Input/Parser/Criterion/Field.php | 1 + .../Input/Parser/Criterion/FullText.php | 1 + .../Input/Parser/Criterion/LanguageCode.php | 1 + .../Input/Parser/Criterion/LocationId.php | 1 + .../Parser/Criterion/LocationRemoteId.php | 1 + .../Input/Parser/Criterion/LogicalAnd.php | 1 + .../Input/Parser/Criterion/LogicalNot.php | 1 + .../Parser/Criterion/LogicalOperator.php | 1 + .../Input/Parser/Criterion/LogicalOr.php | 1 + .../Input/Parser/Criterion/MoreLikeThis.php | 1 + .../Input/Parser/Criterion/ObjectStateId.php | 1 + .../Input/Parser/Criterion/Operator.php | 1 + .../Parser/Criterion/ParentLocationId.php | 1 + .../Criterion/ParentLocationRemoteId.php | 1 + .../Input/Parser/Criterion/SectionId.php | 1 + .../Server/Input/Parser/Criterion/Subtree.php | 1 + .../Input/Parser/Criterion/UserMetadata.php | 1 + .../Input/Parser/Criterion/Visibility.php | 1 + .../Parser/FacetBuilder/ContentTypeParser.php | 1 + .../Parser/FacetBuilder/CriterionParser.php | 1 + .../Parser/FacetBuilder/DateRangeParser.php | 1 + .../Input/Parser/FacetBuilder/FieldParser.php | 1 + .../Parser/FacetBuilder/FieldRangeParser.php | 1 + .../Parser/FacetBuilder/LocationParser.php | 1 + .../Parser/FacetBuilder/SectionParser.php | 1 + .../Input/Parser/FacetBuilder/TermParser.php | 1 + .../Input/Parser/FacetBuilder/UserParser.php | 1 + .../Input/Parser/FieldDefinitionCreate.php | 1 + .../Input/Parser/FieldDefinitionUpdate.php | 1 + .../PathStringRouteBasedLimitationParser.php | 1 + .../Limitation/RouteBasedLimitationParser.php | 1 + .../Server/Input/Parser/LocationCreate.php | 1 + src/lib/Server/Input/Parser/LocationQuery.php | 1 + .../Server/Input/Parser/LocationUpdate.php | 1 + .../Server/Input/Parser/ObjectStateCreate.php | 1 + .../Input/Parser/ObjectStateGroupCreate.php | 1 + .../Input/Parser/ObjectStateGroupUpdate.php | 1 + .../Server/Input/Parser/ObjectStateUpdate.php | 1 + src/lib/Server/Input/Parser/PolicyCreate.php | 1 + src/lib/Server/Input/Parser/PolicyUpdate.php | 1 + src/lib/Server/Input/Parser/Query.php | 1 + .../Server/Input/Parser/RelationCreate.php | 1 + .../Server/Input/Parser/RoleAssignInput.php | 1 + src/lib/Server/Input/Parser/RoleInput.php | 1 + src/lib/Server/Input/Parser/SectionInput.php | 1 + src/lib/Server/Input/Parser/SessionInput.php | 1 + .../SortClause/DataKeyValueObjectClass.php | 1 + .../Server/Input/Parser/SortClause/Field.php | 1 + .../Server/Input/Parser/URLAliasCreate.php | 1 + .../Server/Input/Parser/URLWildcardCreate.php | 1 + src/lib/Server/Input/Parser/UserCreate.php | 1 + .../Server/Input/Parser/UserGroupCreate.php | 1 + .../Server/Input/Parser/UserGroupUpdate.php | 1 + src/lib/Server/Input/Parser/UserUpdate.php | 1 + src/lib/Server/Input/Parser/VersionUpdate.php | 1 + src/lib/Server/Input/Parser/ViewInput.php | 1 + .../Input/Parser/ViewInputOneDotOne.php | 1 + .../BadRequestException.php | 1 + .../ValueObjectVisitor/BadStateException.php | 1 + .../Output/ValueObjectVisitor/CachedValue.php | 1 + .../Output/ValueObjectVisitor/Conflict.php | 1 + .../ContentFieldValidationException.php | 1 + .../Output/ValueObjectVisitor/ContentList.php | 1 + .../ValueObjectVisitor/ContentTypeGroup.php | 1 + .../ContentTypeGroupList.php | 1 + .../ContentTypeGroupRefList.php | 1 + .../ContentTypeInfoList.php | 1 + .../ValueObjectVisitor/ContentTypeList.php | 1 + .../Output/ValueObjectVisitor/CountryList.php | 1 + .../ValueObjectVisitor/CreatedContent.php | 1 + .../ValueObjectVisitor/CreatedContentType.php | 1 + .../CreatedContentTypeGroup.php | 1 + .../CreatedFieldDefinition.php | 1 + .../ValueObjectVisitor/CreatedLocation.php | 1 + .../ValueObjectVisitor/CreatedObjectState.php | 1 + .../CreatedObjectStateGroup.php | 1 + .../ValueObjectVisitor/CreatedPolicy.php | 1 + .../ValueObjectVisitor/CreatedRelation.php | 1 + .../Output/ValueObjectVisitor/CreatedRole.php | 1 + .../ValueObjectVisitor/CreatedSection.php | 1 + .../ValueObjectVisitor/CreatedURLAlias.php | 1 + .../ValueObjectVisitor/CreatedURLWildcard.php | 1 + .../Output/ValueObjectVisitor/CreatedUser.php | 1 + .../ValueObjectVisitor/CreatedUserGroup.php | 1 + .../ValueObjectVisitor/CreatedVersion.php | 1 + .../ValueObjectVisitor/DeletedUserSession.php | 1 + .../Output/ValueObjectVisitor/Exception.php | 1 + .../FieldDefinitionList.php | 1 + .../ValueObjectVisitor/ForbiddenException.php | 1 + .../ValueObjectVisitor/HttpException.php | 1 + .../ValueObjectVisitor/ImageVariation.php | 1 + .../InvalidArgumentException.php | 1 + .../Output/ValueObjectVisitor/Location.php | 1 + .../ValueObjectVisitor/LocationList.php | 1 + .../Output/ValueObjectVisitor/NoContent.php | 1 + .../ValueObjectVisitor/NotFoundException.php | 1 + .../NotImplementedException.php | 1 + .../Server/Output/ValueObjectVisitor/OK.php | 1 + .../ValueObjectVisitor/ObjectStateGroup.php | 1 + .../ObjectStateGroupList.php | 1 + .../ValueObjectVisitor/ObjectStateList.php | 1 + .../Output/ValueObjectVisitor/Options.php | 1 + .../ValueObjectVisitor/PermanentRedirect.php | 1 + .../Output/ValueObjectVisitor/Policy.php | 1 + .../Output/ValueObjectVisitor/PolicyList.php | 1 + .../ValueObjectVisitor/PublishedRole.php | 1 + .../ValueObjectVisitor/RelationList.php | 1 + .../ValueObjectVisitor/ResourceCreated.php | 1 + .../Output/ValueObjectVisitor/RestContent.php | 1 + .../ValueObjectVisitor/RestContentType.php | 1 + .../RestContentTypeBase.php | 1 + .../ValueObjectVisitor/RestExecutedView.php | 1 + .../RestFieldDefinition.php | 1 + .../ValueObjectVisitor/RestLocation.php | 1 + .../ValueObjectVisitor/RestObjectState.php | 1 + .../ValueObjectVisitor/RestRelation.php | 1 + .../ValueObjectVisitor/RestTrashItem.php | 1 + .../Output/ValueObjectVisitor/RestUser.php | 1 + .../ValueObjectVisitor/RestUserGroup.php | 1 + .../RestUserGroupRoleAssignment.php | 1 + .../RestUserRoleAssignment.php | 1 + .../Server/Output/ValueObjectVisitor/Role.php | 1 + .../ValueObjectVisitor/RoleAssignmentList.php | 1 + .../Output/ValueObjectVisitor/RoleList.php | 1 + .../Server/Output/ValueObjectVisitor/Root.php | 1 + .../Output/ValueObjectVisitor/Section.php | 1 + .../Output/ValueObjectVisitor/SectionList.php | 1 + .../Output/ValueObjectVisitor/SeeOther.php | 1 + .../ValueObjectVisitor/TemporaryRedirect.php | 1 + .../Output/ValueObjectVisitor/Trash.php | 1 + .../Output/ValueObjectVisitor/URLAlias.php | 1 + .../ValueObjectVisitor/URLAliasList.php | 1 + .../ValueObjectVisitor/URLAliasRefList.php | 1 + .../Output/ValueObjectVisitor/URLWildcard.php | 1 + .../ValueObjectVisitor/URLWildcardList.php | 1 + .../UnauthorizedException.php | 1 + .../ValueObjectVisitor/UserGroupList.php | 1 + .../ValueObjectVisitor/UserGroupRefList.php | 1 + .../Output/ValueObjectVisitor/UserList.php | 1 + .../Output/ValueObjectVisitor/UserRefList.php | 1 + .../Output/ValueObjectVisitor/UserSession.php | 1 + .../Output/ValueObjectVisitor/Version.php | 1 + .../Output/ValueObjectVisitor/VersionInfo.php | 1 + .../Output/ValueObjectVisitor/VersionList.php | 1 + .../VersionTranslationInfo.php | 1 + src/lib/Server/Security/CsrfTokenManager.php | 1 + src/lib/Server/Security/RestAuthenticator.php | 2 + src/lib/Server/Security/RestLogoutHandler.php | 1 + .../Service/RootResourceBuilderInterface.php | 1 + src/lib/Server/Values/CachedValue.php | 2 + src/lib/Server/Values/Conflict.php | 1 + src/lib/Server/Values/ContentList.php | 1 + .../Server/Values/ContentTypeGroupList.php | 1 + .../Server/Values/ContentTypeGroupRefList.php | 1 + src/lib/Server/Values/ContentTypeInfoList.php | 1 + src/lib/Server/Values/ContentTypeList.php | 1 + src/lib/Server/Values/CountryList.php | 1 + src/lib/Server/Values/CreatedContent.php | 1 + src/lib/Server/Values/CreatedContentType.php | 1 + .../Server/Values/CreatedContentTypeGroup.php | 1 + .../Server/Values/CreatedFieldDefinition.php | 1 + src/lib/Server/Values/CreatedLocation.php | 1 + src/lib/Server/Values/CreatedObjectState.php | 1 + .../Server/Values/CreatedObjectStateGroup.php | 1 + src/lib/Server/Values/CreatedPolicy.php | 1 + src/lib/Server/Values/CreatedRelation.php | 1 + src/lib/Server/Values/CreatedRole.php | 1 + src/lib/Server/Values/CreatedSection.php | 1 + src/lib/Server/Values/CreatedURLAlias.php | 1 + src/lib/Server/Values/CreatedURLWildcard.php | 1 + src/lib/Server/Values/CreatedUser.php | 1 + src/lib/Server/Values/CreatedUserGroup.php | 1 + src/lib/Server/Values/CreatedVersion.php | 1 + src/lib/Server/Values/DeletedUserSession.php | 1 + src/lib/Server/Values/FieldDefinitionList.php | 1 + src/lib/Server/Values/LocationList.php | 1 + src/lib/Server/Values/NoContent.php | 1 + src/lib/Server/Values/OK.php | 1 + .../Server/Values/ObjectStateGroupList.php | 1 + src/lib/Server/Values/ObjectStateList.php | 1 + src/lib/Server/Values/Options.php | 1 + src/lib/Server/Values/PermanentRedirect.php | 1 + src/lib/Server/Values/PolicyList.php | 1 + src/lib/Server/Values/PublishedRole.php | 1 + src/lib/Server/Values/RelationList.php | 1 + src/lib/Server/Values/ResourceCreated.php | 1 + src/lib/Server/Values/RestContent.php | 1 + .../Server/Values/RestContentCreateStruct.php | 1 + src/lib/Server/Values/RestContentType.php | 1 + src/lib/Server/Values/RestExecutedView.php | 1 + src/lib/Server/Values/RestFieldDefinition.php | 1 + src/lib/Server/Values/RestLocation.php | 1 + .../Values/RestLocationUpdateStruct.php | 1 + src/lib/Server/Values/RestRelation.php | 1 + src/lib/Server/Values/RestRole.php | 1 + src/lib/Server/Values/RestTrashItem.php | 1 + src/lib/Server/Values/RestUser.php | 1 + src/lib/Server/Values/RestUserGroup.php | 1 + .../Values/RestUserGroupRoleAssignment.php | 1 + .../Values/RestUserGroupUpdateStruct.php | 1 + .../Server/Values/RestUserRoleAssignment.php | 1 + .../Server/Values/RestUserUpdateStruct.php | 1 + src/lib/Server/Values/RestViewInput.php | 1 + src/lib/Server/Values/RoleAssignment.php | 1 + src/lib/Server/Values/RoleAssignmentList.php | 1 + src/lib/Server/Values/RoleList.php | 1 + src/lib/Server/Values/SectionList.php | 1 + src/lib/Server/Values/SeeOther.php | 1 + src/lib/Server/Values/SessionInput.php | 1 + src/lib/Server/Values/TemporaryRedirect.php | 1 + src/lib/Server/Values/Trash.php | 1 + src/lib/Server/Values/URLAliasList.php | 1 + src/lib/Server/Values/URLAliasRefList.php | 1 + src/lib/Server/Values/URLWildcardList.php | 1 + src/lib/Server/Values/UserGroupList.php | 1 + src/lib/Server/Values/UserGroupRefList.php | 1 + src/lib/Server/Values/UserList.php | 1 + src/lib/Server/Values/UserRefList.php | 1 + src/lib/Server/Values/UserSession.php | 1 + src/lib/Server/Values/Version.php | 1 + src/lib/Server/Values/VersionList.php | 1 + .../Server/Values/VersionTranslationInfo.php | 1 + .../View/AcceptHeaderVisitorDispatcher.php | 1 + src/lib/Value.php | 1 + src/lib/Values/ContentObjectStates.php | 1 + src/lib/Values/Resource.php | 1 + .../RestContentMetadataUpdateStruct.php | 1 + src/lib/Values/RestObjectState.php | 1 + src/lib/Values/Root.php | 1 + tests/bundle/CorsOptions/RestProviderTest.php | 9 +- .../Compiler/FieldTypeProcessorPassTest.php | 1 + .../Compiler/InputHandlerPassTest.php | 1 + .../Compiler/InputParserPassTest.php | 1 + .../Compiler/OutputVisitorPassTest.php | 1 + .../Compiler/ValueObjectVisitorPassTest.php | 1 + .../bundle/EventListener/CsrfListenerTest.php | 26 +-- .../EventListener/EventListenerTest.php | 9 +- .../EventListener/RequestListenerTest.php | 1 + .../EventListener/ResponseListenerTest.php | 7 +- tests/bundle/Functional/BinaryContentTest.php | 1 + tests/bundle/Functional/ContentTest.php | 2 + tests/bundle/Functional/ContentTypeTest.php | 2 + tests/bundle/Functional/LocationTest.php | 1 + tests/bundle/Functional/ObjectStateTest.php | 2 + tests/bundle/Functional/RelationTest.php | 1 + tests/bundle/Functional/RoleTest.php | 2 + tests/bundle/Functional/RootTest.php | 1 + tests/bundle/Functional/SectionTest.php | 2 + tests/bundle/Functional/SessionTest.php | 1 + tests/bundle/Functional/SortClauseTest.php | 1 + tests/bundle/Functional/TestCase.php | 1 + tests/bundle/Functional/TrashTest.php | 1 + tests/bundle/Functional/UrlAliasTest.php | 2 + tests/bundle/Functional/UrlWildcardTest.php | 3 + tests/bundle/Functional/UserTest.php | 3 + tests/bundle/Functional/ViewTest.php | 1 + tests/bundle/RequestParser/RouterTest.php | 2 +- .../Routing/OptionsLoader/MapperTest.php | 1 + .../RouteCollectionMapperTest.php | 1 + tests/bundle/Routing/OptionsLoaderTest.php | 8 +- tests/lib/AssertXmlTagTrait.php | 1 + .../AuthorProcessorTest.php | 7 +- .../BinaryInputProcessorTest.php | 11 +- .../BinaryProcessorTest.php | 3 +- .../DateAndTimeProcessorTest.php | 7 +- .../FieldTypeProcessor/DateProcessorTest.php | 7 +- .../FieldTypeProcessor/ImageProcessorTest.php | 5 +- .../FieldTypeProcessor/MediaProcessorTest.php | 7 +- .../RelationListProcessorTest.php | 21 ++- .../RelationProcessorTest.php | 23 +-- .../FieldTypeProcessor/TimeProcessorTest.php | 7 +- tests/lib/FieldTypeProcessorRegistryTest.php | 13 +- tests/lib/Input/DispatcherTest.php | 19 +- tests/lib/Input/FieldTypeParserTest.php | 117 +++++++------ tests/lib/Input/Handler/JsonTest.php | 5 +- tests/lib/Input/Handler/XmlTest.php | 5 +- tests/lib/Input/ParserToolsTest.php | 25 +-- tests/lib/Input/ParsingDispatcherTest.php | 17 +- tests/lib/MessageTest.php | 9 +- tests/lib/Output/FieldTypeSerializerTest.php | 51 +++--- .../FieldTypeHashGeneratorBaseTest.php | 3 +- .../Json/FieldTypeHashGeneratorTest.php | 1 + tests/lib/Output/Generator/JsonTest.php | 33 ++-- .../Xml/FieldTypeHashGeneratorTest.php | 1 + tests/lib/Output/Generator/XmlTest.php | 33 ++-- tests/lib/Output/GeneratorTest.php | 7 +- tests/lib/Output/ValueObject.php | 1 + .../lib/Output/ValueObjectVisitorBaseTest.php | 17 +- .../ValueObjectVisitorDispatcherTest.php | 9 +- tests/lib/Output/VisitorTest.php | 31 ++-- tests/lib/Server/BaseTest.php | 1 + tests/lib/Server/Input/Parser/BaseTest.php | 3 +- .../Server/Input/Parser/ContentCreateTest.php | 37 ++-- .../Input/Parser/ContentObjectStatesTest.php | 13 +- .../Input/Parser/ContentTypeCreateTest.php | 37 ++-- .../Parser/ContentTypeGroupInputTest.php | 13 +- .../Input/Parser/ContentTypeUpdateTest.php | 31 ++-- .../Server/Input/Parser/ContentUpdateTest.php | 3 +- .../Parser/Criterion/DateMetadataTest.php | 4 +- .../Input/Parser/Criterion/LogicalAndTest.php | 1 + .../Input/Parser/Criterion/LogicalOrTest.php | 1 + .../Input/Parser/Criterion/SiblingTest.php | 2 +- .../Parser/Criterion/UserMetadataTest.php | 3 +- .../FacetBuilder/FacetBuilderBaseTest.php | 1 + .../FacetBuilder/FacetBuilderParserTest.php | 21 +-- .../Parser/FieldDefinitionCreateTest.php | 39 +++-- .../Parser/FieldDefinitionUpdateTest.php | 39 +++-- ...thStringRouteBasedLimitationParserTest.php | 1 + .../RouteBasedLimitationParserTest.php | 1 + .../Input/Parser/LocationCreateTest.php | 19 +- .../Input/Parser/LocationUpdateTest.php | 29 +-- .../Input/Parser/ObjectStateCreateTest.php | 17 +- .../Parser/ObjectStateGroupCreateTest.php | 15 +- .../Parser/ObjectStateGroupUpdateTest.php | 13 +- .../Input/Parser/ObjectStateUpdateTest.php | 13 +- .../Server/Input/Parser/PolicyCreateTest.php | 23 +-- .../Server/Input/Parser/PolicyUpdateTest.php | 15 +- .../Server/Input/Parser/QueryParserTest.php | 23 +-- .../Input/Parser/RelationCreateTest.php | 3 +- .../Input/Parser/RoleAssignInputTest.php | 9 +- .../lib/Server/Input/Parser/RoleInputTest.php | 9 +- .../Server/Input/Parser/SectionInputTest.php | 5 +- .../Server/Input/Parser/SessionInputTest.php | 3 +- .../DataKeyValueObjectClassTest.php | 3 +- .../Input/Parser/SortClause/FieldTest.php | 3 +- .../Input/Parser/URLWildcardCreateTest.php | 3 +- .../Server/Input/Parser/UserCreateTest.php | 33 ++-- .../Input/Parser/UserGroupCreateTest.php | 27 +-- .../Input/Parser/UserGroupUpdateTest.php | 27 +-- .../Server/Input/Parser/UserUpdateTest.php | 29 +-- .../Server/Input/Parser/VersionUpdateTest.php | 11 +- .../Input/Parser/ViewInputOneDotOneTest.php | 9 +- .../lib/Server/Input/Parser/ViewInputTest.php | 5 +- .../BadRequestExceptionTest.php | 1 + .../BadStateExceptionTest.php | 1 + .../ValueObjectVisitor/BookmarkListTest.php | 4 +- .../ValueObjectVisitor/CachedValueTest.php | 43 ++--- .../ValueObjectVisitor/ConflictTest.php | 7 +- .../ContentFieldValidationExceptionTest.php | 3 +- .../ValueObjectVisitor/ContentListTest.php | 7 +- .../ContentObjectStatesTest.php | 3 +- .../ContentTypeGroupListTest.php | 7 +- .../ContentTypeGroupRefListTest.php | 3 +- .../ContentTypeGroupTest.php | 3 +- .../ContentTypeInfoListTest.php | 7 +- .../ContentTypeListTest.php | 7 +- .../ValueObjectVisitor/CountryListTest.php | 3 +- .../DeletedUserSessionTest.php | 13 +- .../ValueObjectVisitor/ExceptionTest.php | 9 +- .../FieldDefinitionListTest.php | 8 +- .../ForbiddenExceptionTest.php | 1 + .../ValueObjectVisitor/ImageVariationTest.php | 16 +- .../InvalidArgumentExceptionTest.php | 1 + .../ValueObjectVisitor/LocationListTest.php | 3 +- .../ValueObjectVisitor/LocationTest.php | 1 + .../ValueObjectVisitor/NoContentTest.php | 7 +- .../NotFoundExceptionTest.php | 1 + .../NotImplementedExceptionTest.php | 1 + .../ObjectStateGroupListTest.php | 7 +- .../ObjectStateGroupTest.php | 3 +- .../ObjectStateListTest.php | 7 +- .../Output/ValueObjectVisitor/OptionsTest.php | 7 +- .../PermanentRedirectTest.php | 11 +- .../ValueObjectVisitor/PolicyListTest.php | 7 +- .../Output/ValueObjectVisitor/PolicyTest.php | 3 +- .../ValueObjectVisitor/RelationListTest.php | 7 +- .../ResourceCreatedTest.php | 11 +- .../ValueObjectVisitor/RestContentTest.php | 11 +- .../RestContentTypeTest.php | 7 +- .../RestExecutedViewTest.php | 4 +- .../RestFieldDefinitionTest.php | 13 +- .../RestLocationRootNodeTest.php | 7 +- .../ValueObjectVisitor/RestLocationTest.php | 7 +- .../RestObjectStateTest.php | 3 +- .../ValueObjectVisitor/RestRelationTest.php | 3 +- .../ValueObjectVisitor/RestTrashItemTest.php | 7 +- .../RestUserGroupRoleAssignmentTest.php | 3 +- .../ValueObjectVisitor/RestUserGroupTest.php | 5 +- .../RestUserRoleAssignmentTest.php | 3 +- .../ValueObjectVisitor/RestUserTest.php | 5 +- .../RoleAssignmentListTest.php | 9 +- .../ValueObjectVisitor/RoleListTest.php | 7 +- .../Output/ValueObjectVisitor/RoleTest.php | 9 +- .../Output/ValueObjectVisitor/RootTest.php | 3 +- .../ValueObjectVisitor/SectionListTest.php | 7 +- .../Output/ValueObjectVisitor/SectionTest.php | 3 +- .../TemporaryRedirectTest.php | 11 +- .../Output/ValueObjectVisitor/TrashTest.php | 7 +- .../ValueObjectVisitor/URLAliasListTest.php | 7 +- .../URLAliasRefListTest.php | 3 +- .../ValueObjectVisitor/URLAliasTest.php | 3 +- .../URLWildcardListTest.php | 7 +- .../ValueObjectVisitor/URLWildcardTest.php | 3 +- .../UnauthorizedExceptionTest.php | 1 + .../ValueObjectVisitor/UserGroupListTest.php | 7 +- .../UserGroupRefListTest.php | 3 +- .../ValueObjectVisitor/UserListTest.php | 7 +- .../ValueObjectVisitor/UserRefListTest.php | 3 +- .../UserSessionCreatedTest.php | 11 +- .../ValueObjectVisitor/UserSessionTest.php | 15 +- .../ValueObjectVisitor/VersionInfoTest.php | 3 +- .../ValueObjectVisitor/VersionListTest.php | 7 +- .../Output/ValueObjectVisitor/VersionTest.php | 3 +- .../Server/Security/CsrfTokenManagerTest.php | 7 +- .../Server/Security/RestLogoutHandlerTest.php | 17 +- .../RestSessionBasedAuthenticatorTest.php | 165 +++++++++--------- tests/lib/UrlHandler/PatternTest.php | 5 +- 516 files changed, 1363 insertions(+), 811 deletions(-) diff --git a/composer.json b/composer.json index 1f3998c3..08453b35 100644 --- a/composer.json +++ b/composer.json @@ -46,9 +46,8 @@ "symfony/yaml": "^5.3" }, "require-dev": { - "friendsofphp/php-cs-fixer": "^3.0", "ibexa/ci-scripts": "^0.2@dev", - "ibexa/code-style": "^1.0", + "ibexa/code-style": "~2.0.0", "ibexa/doctrine-schema": "~5.0.x-dev", "ibexa/test-core": "^0.1.x-dev", "justinrainbow/json-schema": "^5.2", @@ -58,7 +57,7 @@ "phpstan/phpstan-phpunit": "^1.3", "phpstan/phpstan-symfony": "^1.3", "phpstan/phpstan-webmozart-assert": "^1.2", - "phpunit/phpunit": "^8.5", + "phpunit/phpunit": "^9.6", "symfony/browser-kit": "^5.3", "symfony/http-client": "^5.3" }, diff --git a/phpunit.functional.xml b/phpunit.functional.xml index d3a8c8d3..c201013f 100644 --- a/phpunit.functional.xml +++ b/phpunit.functional.xml @@ -1,10 +1,9 @@ diff --git a/phpunit.integration.xml b/phpunit.integration.xml index aedda752..2b44e4a9 100644 --- a/phpunit.integration.xml +++ b/phpunit.integration.xml @@ -1,9 +1,8 @@ diff --git a/phpunit.xml b/phpunit.xml index c232eadb..17d06591 100644 --- a/phpunit.xml +++ b/phpunit.xml @@ -1,10 +1,9 @@ diff --git a/src/bundle/ApiLoader/Factory.php b/src/bundle/ApiLoader/Factory.php index aeb1a111..bdc43b5f 100644 --- a/src/bundle/ApiLoader/Factory.php +++ b/src/bundle/ApiLoader/Factory.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Bundle\Rest\ApiLoader; use Ibexa\Contracts\Core\Repository\Repository; diff --git a/src/bundle/CorsOptions/RestProvider.php b/src/bundle/CorsOptions/RestProvider.php index 0c2300c0..7d62890e 100644 --- a/src/bundle/CorsOptions/RestProvider.php +++ b/src/bundle/CorsOptions/RestProvider.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Bundle\Rest\CorsOptions; use Nelmio\CorsBundle\Options\ProviderInterface; diff --git a/src/bundle/DependencyInjection/Compiler/FieldTypeProcessorPass.php b/src/bundle/DependencyInjection/Compiler/FieldTypeProcessorPass.php index 3e6e551d..d5099794 100644 --- a/src/bundle/DependencyInjection/Compiler/FieldTypeProcessorPass.php +++ b/src/bundle/DependencyInjection/Compiler/FieldTypeProcessorPass.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Bundle\Rest\DependencyInjection\Compiler; use Ibexa\Rest\FieldTypeProcessorRegistry; diff --git a/src/bundle/DependencyInjection/Compiler/InputHandlerPass.php b/src/bundle/DependencyInjection/Compiler/InputHandlerPass.php index 23fdc578..8fd9603e 100644 --- a/src/bundle/DependencyInjection/Compiler/InputHandlerPass.php +++ b/src/bundle/DependencyInjection/Compiler/InputHandlerPass.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Bundle\Rest\DependencyInjection\Compiler; use Ibexa\Rest\Input\Dispatcher; diff --git a/src/bundle/DependencyInjection/Compiler/InputParserPass.php b/src/bundle/DependencyInjection/Compiler/InputParserPass.php index 6564026e..ce9750e6 100644 --- a/src/bundle/DependencyInjection/Compiler/InputParserPass.php +++ b/src/bundle/DependencyInjection/Compiler/InputParserPass.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Bundle\Rest\DependencyInjection\Compiler; use Ibexa\Contracts\Rest\Input\ParsingDispatcher; diff --git a/src/bundle/DependencyInjection/Compiler/OutputVisitorPass.php b/src/bundle/DependencyInjection/Compiler/OutputVisitorPass.php index 4c2545c8..9a2cf739 100644 --- a/src/bundle/DependencyInjection/Compiler/OutputVisitorPass.php +++ b/src/bundle/DependencyInjection/Compiler/OutputVisitorPass.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Bundle\Rest\DependencyInjection\Compiler; use Ibexa\Rest\Server\View\AcceptHeaderVisitorDispatcher; diff --git a/src/bundle/DependencyInjection/Compiler/ValueObjectVisitorPass.php b/src/bundle/DependencyInjection/Compiler/ValueObjectVisitorPass.php index ad774824..f2762391 100644 --- a/src/bundle/DependencyInjection/Compiler/ValueObjectVisitorPass.php +++ b/src/bundle/DependencyInjection/Compiler/ValueObjectVisitorPass.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Bundle\Rest\DependencyInjection\Compiler; use Ibexa\Contracts\Rest\Output\ValueObjectVisitorDispatcher; diff --git a/src/bundle/DependencyInjection/Configuration.php b/src/bundle/DependencyInjection/Configuration.php index 287fa30e..fb8a667c 100644 --- a/src/bundle/DependencyInjection/Configuration.php +++ b/src/bundle/DependencyInjection/Configuration.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Bundle\Rest\DependencyInjection; use Ibexa\Bundle\Core\DependencyInjection\Configuration\SiteAccessAware\Configuration as SiteAccessConfiguration; diff --git a/src/bundle/DependencyInjection/IbexaRestExtension.php b/src/bundle/DependencyInjection/IbexaRestExtension.php index 7994dae4..83f07336 100644 --- a/src/bundle/DependencyInjection/IbexaRestExtension.php +++ b/src/bundle/DependencyInjection/IbexaRestExtension.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Bundle\Rest\DependencyInjection; use Ibexa\Bundle\Core\DependencyInjection\Configuration\SiteAccessAware\ConfigurationProcessor; diff --git a/src/bundle/DependencyInjection/Security/RestSessionBasedFactory.php b/src/bundle/DependencyInjection/Security/RestSessionBasedFactory.php index 778417ca..29101c05 100644 --- a/src/bundle/DependencyInjection/Security/RestSessionBasedFactory.php +++ b/src/bundle/DependencyInjection/Security/RestSessionBasedFactory.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Bundle\Rest\DependencyInjection\Security; use Ibexa\Rest\Server\Security\RestLogoutHandler; diff --git a/src/bundle/EventListener/CsrfListener.php b/src/bundle/EventListener/CsrfListener.php index 93cfa63f..ab211c60 100644 --- a/src/bundle/EventListener/CsrfListener.php +++ b/src/bundle/EventListener/CsrfListener.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Bundle\Rest\EventListener; use Ibexa\Bundle\Rest\RestEvents; diff --git a/src/bundle/EventListener/RequestListener.php b/src/bundle/EventListener/RequestListener.php index 890486ef..2b3a3bdc 100644 --- a/src/bundle/EventListener/RequestListener.php +++ b/src/bundle/EventListener/RequestListener.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Bundle\Rest\EventListener; use Ibexa\Bundle\Rest\UriParser\UriParser; diff --git a/src/bundle/EventListener/ResponseListener.php b/src/bundle/EventListener/ResponseListener.php index 4719084c..f776c694 100644 --- a/src/bundle/EventListener/ResponseListener.php +++ b/src/bundle/EventListener/ResponseListener.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Bundle\Rest\EventListener; use Ibexa\Rest\Server\View\AcceptHeaderVisitorDispatcher; diff --git a/src/bundle/IbexaRestBundle.php b/src/bundle/IbexaRestBundle.php index 1fb730cf..faf21fe9 100644 --- a/src/bundle/IbexaRestBundle.php +++ b/src/bundle/IbexaRestBundle.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Bundle\Rest; use Ibexa\Bundle\Rest\DependencyInjection\Compiler; diff --git a/src/bundle/RequestParser/Router.php b/src/bundle/RequestParser/Router.php index 7483d888..92bab00d 100644 --- a/src/bundle/RequestParser/Router.php +++ b/src/bundle/RequestParser/Router.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Bundle\Rest\RequestParser; use Ibexa\Contracts\Rest\UriParser\UriParserInterface; diff --git a/src/bundle/RestEvents.php b/src/bundle/RestEvents.php index cfd003a2..cbbcc044 100644 --- a/src/bundle/RestEvents.php +++ b/src/bundle/RestEvents.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Bundle\Rest; final class RestEvents diff --git a/src/bundle/Routing/OptionsLoader.php b/src/bundle/Routing/OptionsLoader.php index d72b582f..dcf404ba 100644 --- a/src/bundle/Routing/OptionsLoader.php +++ b/src/bundle/Routing/OptionsLoader.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Bundle\Rest\Routing; use Ibexa\Bundle\Rest\Routing\OptionsLoader\RouteCollectionMapper; diff --git a/src/bundle/Routing/OptionsLoader/Mapper.php b/src/bundle/Routing/OptionsLoader/Mapper.php index 7001fec5..c40f0b27 100644 --- a/src/bundle/Routing/OptionsLoader/Mapper.php +++ b/src/bundle/Routing/OptionsLoader/Mapper.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Bundle\Rest\Routing\OptionsLoader; use Symfony\Component\Routing\Route; diff --git a/src/bundle/Routing/OptionsLoader/RouteCollectionMapper.php b/src/bundle/Routing/OptionsLoader/RouteCollectionMapper.php index 49a0b7b3..bf112726 100644 --- a/src/bundle/Routing/OptionsLoader/RouteCollectionMapper.php +++ b/src/bundle/Routing/OptionsLoader/RouteCollectionMapper.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Bundle\Rest\Routing\OptionsLoader; use Symfony\Component\Routing\RouteCollection; diff --git a/src/contracts/Exceptions/ForbiddenException.php b/src/contracts/Exceptions/ForbiddenException.php index 9f5cbf28..42633464 100644 --- a/src/contracts/Exceptions/ForbiddenException.php +++ b/src/contracts/Exceptions/ForbiddenException.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Contracts\Rest\Exceptions; use InvalidArgumentException; diff --git a/src/contracts/Exceptions/InvalidArgumentException.php b/src/contracts/Exceptions/InvalidArgumentException.php index 7e462c7e..bac9c0df 100644 --- a/src/contracts/Exceptions/InvalidArgumentException.php +++ b/src/contracts/Exceptions/InvalidArgumentException.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Contracts\Rest\Exceptions; use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException as APIInvalidArgumentException; diff --git a/src/contracts/Exceptions/NotFoundException.php b/src/contracts/Exceptions/NotFoundException.php index a78efd35..4ff7c2fb 100644 --- a/src/contracts/Exceptions/NotFoundException.php +++ b/src/contracts/Exceptions/NotFoundException.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Contracts\Rest\Exceptions; use Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException as APINotFoundException; diff --git a/src/contracts/Exceptions/Parser.php b/src/contracts/Exceptions/Parser.php index 1a8ca8c2..5ed8d449 100644 --- a/src/contracts/Exceptions/Parser.php +++ b/src/contracts/Exceptions/Parser.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Contracts\Rest\Exceptions; use InvalidArgumentException as PHPInvalidArgumentException; diff --git a/src/contracts/FieldTypeProcessor.php b/src/contracts/FieldTypeProcessor.php index 08c07f39..833c8c94 100644 --- a/src/contracts/FieldTypeProcessor.php +++ b/src/contracts/FieldTypeProcessor.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Contracts\Rest; /** diff --git a/src/contracts/Input/Handler.php b/src/contracts/Input/Handler.php index 46d6b14c..2b05ac83 100644 --- a/src/contracts/Input/Handler.php +++ b/src/contracts/Input/Handler.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Contracts\Rest\Input; /** diff --git a/src/contracts/Input/Parser.php b/src/contracts/Input/Parser.php index 1c67345b..5bf07051 100644 --- a/src/contracts/Input/Parser.php +++ b/src/contracts/Input/Parser.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Contracts\Rest\Input; /** diff --git a/src/contracts/Input/ParsingDispatcher.php b/src/contracts/Input/ParsingDispatcher.php index 5db04522..0339d327 100644 --- a/src/contracts/Input/ParsingDispatcher.php +++ b/src/contracts/Input/ParsingDispatcher.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Contracts\Rest\Input; use Ibexa\Contracts\Rest\Event\BeforeParseEvent; diff --git a/src/contracts/Output/Exceptions/InvalidTypeException.php b/src/contracts/Output/Exceptions/InvalidTypeException.php index 9e0fb1a2..ceb930fd 100644 --- a/src/contracts/Output/Exceptions/InvalidTypeException.php +++ b/src/contracts/Output/Exceptions/InvalidTypeException.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Contracts\Rest\Output\Exceptions; use RuntimeException; diff --git a/src/contracts/Output/Exceptions/NoVisitorFoundException.php b/src/contracts/Output/Exceptions/NoVisitorFoundException.php index cfa847c0..c40005f4 100644 --- a/src/contracts/Output/Exceptions/NoVisitorFoundException.php +++ b/src/contracts/Output/Exceptions/NoVisitorFoundException.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Contracts\Rest\Output\Exceptions; use RuntimeException; diff --git a/src/contracts/Output/Exceptions/OutputGeneratorException.php b/src/contracts/Output/Exceptions/OutputGeneratorException.php index 2b4f90d7..1bca5990 100644 --- a/src/contracts/Output/Exceptions/OutputGeneratorException.php +++ b/src/contracts/Output/Exceptions/OutputGeneratorException.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Contracts\Rest\Output\Exceptions; use RuntimeException; diff --git a/src/contracts/Output/Generator.php b/src/contracts/Output/Generator.php index 2086294e..57db7b3f 100644 --- a/src/contracts/Output/Generator.php +++ b/src/contracts/Output/Generator.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Contracts\Rest\Output; /** diff --git a/src/contracts/Output/ValueObjectVisitor.php b/src/contracts/Output/ValueObjectVisitor.php index 5591d555..91a1d53b 100644 --- a/src/contracts/Output/ValueObjectVisitor.php +++ b/src/contracts/Output/ValueObjectVisitor.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Contracts\Rest\Output; use Ibexa\Contracts\Core\Repository\Values\Content\Location; diff --git a/src/contracts/Output/ValueObjectVisitorDispatcher.php b/src/contracts/Output/ValueObjectVisitorDispatcher.php index 65bb10a6..c0eaed39 100644 --- a/src/contracts/Output/ValueObjectVisitorDispatcher.php +++ b/src/contracts/Output/ValueObjectVisitorDispatcher.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Contracts\Rest\Output; use Error; diff --git a/src/contracts/Output/Visitor.php b/src/contracts/Output/Visitor.php index 49ab6c84..3a7dac5f 100644 --- a/src/contracts/Output/Visitor.php +++ b/src/contracts/Output/Visitor.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Contracts\Rest\Output; use Symfony\Component\HttpFoundation\Response; diff --git a/src/lib/FieldTypeProcessor/AuthorProcessor.php b/src/lib/FieldTypeProcessor/AuthorProcessor.php index c48f91b8..48f1bd24 100644 --- a/src/lib/FieldTypeProcessor/AuthorProcessor.php +++ b/src/lib/FieldTypeProcessor/AuthorProcessor.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\FieldTypeProcessor; use Ibexa\Contracts\Rest\FieldTypeProcessor; diff --git a/src/lib/FieldTypeProcessor/BaseRelationProcessor.php b/src/lib/FieldTypeProcessor/BaseRelationProcessor.php index cec5eea7..0b81fed0 100644 --- a/src/lib/FieldTypeProcessor/BaseRelationProcessor.php +++ b/src/lib/FieldTypeProcessor/BaseRelationProcessor.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\FieldTypeProcessor; use Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException; diff --git a/src/lib/FieldTypeProcessor/BinaryInputProcessor.php b/src/lib/FieldTypeProcessor/BinaryInputProcessor.php index 15ebafae..f0429a3b 100644 --- a/src/lib/FieldTypeProcessor/BinaryInputProcessor.php +++ b/src/lib/FieldTypeProcessor/BinaryInputProcessor.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\FieldTypeProcessor; use Ibexa\Contracts\Rest\FieldTypeProcessor; diff --git a/src/lib/FieldTypeProcessor/BinaryProcessor.php b/src/lib/FieldTypeProcessor/BinaryProcessor.php index 6877a230..a222b7c9 100644 --- a/src/lib/FieldTypeProcessor/BinaryProcessor.php +++ b/src/lib/FieldTypeProcessor/BinaryProcessor.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\FieldTypeProcessor; class BinaryProcessor extends BinaryInputProcessor diff --git a/src/lib/FieldTypeProcessor/DateAndTimeProcessor.php b/src/lib/FieldTypeProcessor/DateAndTimeProcessor.php index a6e807a6..76c5f286 100644 --- a/src/lib/FieldTypeProcessor/DateAndTimeProcessor.php +++ b/src/lib/FieldTypeProcessor/DateAndTimeProcessor.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\FieldTypeProcessor; use Ibexa\Contracts\Rest\FieldTypeProcessor; diff --git a/src/lib/FieldTypeProcessor/DateProcessor.php b/src/lib/FieldTypeProcessor/DateProcessor.php index c213a3c6..0141f74b 100644 --- a/src/lib/FieldTypeProcessor/DateProcessor.php +++ b/src/lib/FieldTypeProcessor/DateProcessor.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\FieldTypeProcessor; use Ibexa\Contracts\Rest\FieldTypeProcessor; diff --git a/src/lib/FieldTypeProcessor/FloatProcessor.php b/src/lib/FieldTypeProcessor/FloatProcessor.php index cab282f5..bdcc6492 100644 --- a/src/lib/FieldTypeProcessor/FloatProcessor.php +++ b/src/lib/FieldTypeProcessor/FloatProcessor.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\FieldTypeProcessor; use Ibexa\Contracts\Rest\FieldTypeProcessor; diff --git a/src/lib/FieldTypeProcessor/ImageProcessor.php b/src/lib/FieldTypeProcessor/ImageProcessor.php index c1a99cb2..8e73be42 100644 --- a/src/lib/FieldTypeProcessor/ImageProcessor.php +++ b/src/lib/FieldTypeProcessor/ImageProcessor.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\FieldTypeProcessor; use Symfony\Component\Routing\RouterInterface; diff --git a/src/lib/FieldTypeProcessor/MediaProcessor.php b/src/lib/FieldTypeProcessor/MediaProcessor.php index 1d3c632b..6160a63c 100644 --- a/src/lib/FieldTypeProcessor/MediaProcessor.php +++ b/src/lib/FieldTypeProcessor/MediaProcessor.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\FieldTypeProcessor; use Ibexa\Core\FieldType\Media\Type; diff --git a/src/lib/FieldTypeProcessor/RelationListProcessor.php b/src/lib/FieldTypeProcessor/RelationListProcessor.php index 1afa893d..1de8032f 100644 --- a/src/lib/FieldTypeProcessor/RelationListProcessor.php +++ b/src/lib/FieldTypeProcessor/RelationListProcessor.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\FieldTypeProcessor; class RelationListProcessor extends BaseRelationProcessor diff --git a/src/lib/FieldTypeProcessor/RelationProcessor.php b/src/lib/FieldTypeProcessor/RelationProcessor.php index 9713c19f..793d000c 100644 --- a/src/lib/FieldTypeProcessor/RelationProcessor.php +++ b/src/lib/FieldTypeProcessor/RelationProcessor.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\FieldTypeProcessor; class RelationProcessor extends BaseRelationProcessor diff --git a/src/lib/FieldTypeProcessor/StringProcessor.php b/src/lib/FieldTypeProcessor/StringProcessor.php index 996f1110..04e6a83b 100644 --- a/src/lib/FieldTypeProcessor/StringProcessor.php +++ b/src/lib/FieldTypeProcessor/StringProcessor.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\FieldTypeProcessor; use Ibexa\Contracts\Rest\FieldTypeProcessor; diff --git a/src/lib/FieldTypeProcessor/TimeProcessor.php b/src/lib/FieldTypeProcessor/TimeProcessor.php index b8dba802..25728774 100644 --- a/src/lib/FieldTypeProcessor/TimeProcessor.php +++ b/src/lib/FieldTypeProcessor/TimeProcessor.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\FieldTypeProcessor; use Ibexa\Contracts\Rest\FieldTypeProcessor; diff --git a/src/lib/FieldTypeProcessor/UserProcessor.php b/src/lib/FieldTypeProcessor/UserProcessor.php index 91dd90a8..affc88a9 100644 --- a/src/lib/FieldTypeProcessor/UserProcessor.php +++ b/src/lib/FieldTypeProcessor/UserProcessor.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\FieldTypeProcessor; use Ibexa\Contracts\Rest\FieldTypeProcessor; diff --git a/src/lib/FieldTypeProcessorRegistry.php b/src/lib/FieldTypeProcessorRegistry.php index 22c833c5..43d54466 100644 --- a/src/lib/FieldTypeProcessorRegistry.php +++ b/src/lib/FieldTypeProcessorRegistry.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest; use Ibexa\Contracts\Rest\FieldTypeProcessor; diff --git a/src/lib/Input/BaseParser.php b/src/lib/Input/BaseParser.php index 63275754..f32cf3a4 100644 --- a/src/lib/Input/BaseParser.php +++ b/src/lib/Input/BaseParser.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Input; use Ibexa\Contracts\Rest\Input\Parser; diff --git a/src/lib/Input/Dispatcher.php b/src/lib/Input/Dispatcher.php index 308a6f6b..3d9f55f7 100644 --- a/src/lib/Input/Dispatcher.php +++ b/src/lib/Input/Dispatcher.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Input; use Ibexa\Contracts\Rest\Exceptions; diff --git a/src/lib/Input/FieldTypeParser.php b/src/lib/Input/FieldTypeParser.php index deb27407..9558cd6f 100644 --- a/src/lib/Input/FieldTypeParser.php +++ b/src/lib/Input/FieldTypeParser.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Input; use Ibexa\Contracts\Core\Repository\ContentService; diff --git a/src/lib/Input/Handler/Json.php b/src/lib/Input/Handler/Json.php index e33a0d59..05679888 100644 --- a/src/lib/Input/Handler/Json.php +++ b/src/lib/Input/Handler/Json.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Input\Handler; use Ibexa\Contracts\Rest\Exceptions\Parser as ParserException; diff --git a/src/lib/Input/Handler/Xml.php b/src/lib/Input/Handler/Xml.php index c1a7f63f..ed0f4072 100644 --- a/src/lib/Input/Handler/Xml.php +++ b/src/lib/Input/Handler/Xml.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Input\Handler; use Ibexa\Contracts\Rest\Exceptions; diff --git a/src/lib/Input/Parser/ContentObjectStates.php b/src/lib/Input/Parser/ContentObjectStates.php index 2c4f2d11..a6549d79 100644 --- a/src/lib/Input/Parser/ContentObjectStates.php +++ b/src/lib/Input/Parser/ContentObjectStates.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Input\Parser; use Ibexa\Contracts\Rest\Exceptions; diff --git a/src/lib/Input/ParserTools.php b/src/lib/Input/ParserTools.php index 216f8683..7c0da9a9 100644 --- a/src/lib/Input/ParserTools.php +++ b/src/lib/Input/ParserTools.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Input; use Ibexa\Contracts\Core\Repository\Values; diff --git a/src/lib/Message.php b/src/lib/Message.php index cafb8035..93618cae 100644 --- a/src/lib/Message.php +++ b/src/lib/Message.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest; /** diff --git a/src/lib/Output/FieldTypeSerializer.php b/src/lib/Output/FieldTypeSerializer.php index eda28ab5..6d5c7eea 100644 --- a/src/lib/Output/FieldTypeSerializer.php +++ b/src/lib/Output/FieldTypeSerializer.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Output; use Ibexa\Contracts\Core\Repository\FieldType; diff --git a/src/lib/Output/Generator/Json.php b/src/lib/Output/Generator/Json.php index 8a8f4c3a..7e989828 100644 --- a/src/lib/Output/Generator/Json.php +++ b/src/lib/Output/Generator/Json.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Output\Generator; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Output/Generator/Json/ArrayObject.php b/src/lib/Output/Generator/Json/ArrayObject.php index 0522883e..9f10b74a 100644 --- a/src/lib/Output/Generator/Json/ArrayObject.php +++ b/src/lib/Output/Generator/Json/ArrayObject.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Output\Generator\Json; use ArrayObject as NativeArrayObject; diff --git a/src/lib/Output/Generator/Json/FieldTypeHashGenerator.php b/src/lib/Output/Generator/Json/FieldTypeHashGenerator.php index 89af196d..eee424fb 100644 --- a/src/lib/Output/Generator/Json/FieldTypeHashGenerator.php +++ b/src/lib/Output/Generator/Json/FieldTypeHashGenerator.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Output\Generator\Json; use Psr\Log\LoggerAwareInterface; diff --git a/src/lib/Output/Generator/Json/JsonObject.php b/src/lib/Output/Generator/Json/JsonObject.php index b03eeacf..0c8506da 100644 --- a/src/lib/Output/Generator/Json/JsonObject.php +++ b/src/lib/Output/Generator/Json/JsonObject.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Output\Generator\Json; /** diff --git a/src/lib/Output/Generator/Xml.php b/src/lib/Output/Generator/Xml.php index 9ba44b53..85024129 100644 --- a/src/lib/Output/Generator/Xml.php +++ b/src/lib/Output/Generator/Xml.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Output\Generator; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Output/Generator/Xml/FieldTypeHashGenerator.php b/src/lib/Output/Generator/Xml/FieldTypeHashGenerator.php index c3fcaf95..a0e088d2 100644 --- a/src/lib/Output/Generator/Xml/FieldTypeHashGenerator.php +++ b/src/lib/Output/Generator/Xml/FieldTypeHashGenerator.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Output\Generator\Xml; use Psr\Log\LoggerAwareInterface; diff --git a/src/lib/Output/ValueObjectVisitor/ContentObjectStates.php b/src/lib/Output/ValueObjectVisitor/ContentObjectStates.php index 474c6e94..aba0c5b1 100644 --- a/src/lib/Output/ValueObjectVisitor/ContentObjectStates.php +++ b/src/lib/Output/ValueObjectVisitor/ContentObjectStates.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/RequestParser.php b/src/lib/RequestParser.php index 9c22b6fd..dc82d795 100644 --- a/src/lib/RequestParser.php +++ b/src/lib/RequestParser.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest; /** diff --git a/src/lib/RequestParser/EzPublish.php b/src/lib/RequestParser/EzPublish.php index dd95997a..1f899ab0 100644 --- a/src/lib/RequestParser/EzPublish.php +++ b/src/lib/RequestParser/EzPublish.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\RequestParser; /** @@ -15,6 +16,7 @@ class EzPublish extends Pattern * Map of URL types to their URL patterns. * * @var array + * * @todo: Add sensible missing names */ protected $map = [ diff --git a/src/lib/RequestParser/Pattern.php b/src/lib/RequestParser/Pattern.php index c7806c77..8a109723 100644 --- a/src/lib/RequestParser/Pattern.php +++ b/src/lib/RequestParser/Pattern.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\RequestParser; use Ibexa\Contracts\Rest\Exceptions; diff --git a/src/lib/Server/Controller.php b/src/lib/Server/Controller.php index 02ee0383..b0aa9b69 100644 --- a/src/lib/Server/Controller.php +++ b/src/lib/Server/Controller.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server; use Ibexa\Contracts\Core\Repository\Repository; diff --git a/src/lib/Server/Controller/BinaryContent.php b/src/lib/Server/Controller/BinaryContent.php index 5aefb7be..32e9183a 100644 --- a/src/lib/Server/Controller/BinaryContent.php +++ b/src/lib/Server/Controller/BinaryContent.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Controller; use Ibexa\Contracts\Core\Repository\Exceptions\InvalidVariationException; diff --git a/src/lib/Server/Controller/Content.php b/src/lib/Server/Controller/Content.php index d525fd62..f8829246 100644 --- a/src/lib/Server/Controller/Content.php +++ b/src/lib/Server/Controller/Content.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Controller; use Ibexa\Contracts\Core\Repository\Exceptions\ContentFieldValidationException; diff --git a/src/lib/Server/Controller/ContentType.php b/src/lib/Server/Controller/ContentType.php index 7b9ab1f7..21fb8742 100644 --- a/src/lib/Server/Controller/ContentType.php +++ b/src/lib/Server/Controller/ContentType.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Controller; use Ibexa\Contracts\Core\Repository\ContentTypeService; diff --git a/src/lib/Server/Controller/Location.php b/src/lib/Server/Controller/Location.php index fbb1834e..7fac2e44 100644 --- a/src/lib/Server/Controller/Location.php +++ b/src/lib/Server/Controller/Location.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Controller; use Ibexa\Contracts\Core\Repository\ContentService; diff --git a/src/lib/Server/Controller/ObjectState.php b/src/lib/Server/Controller/ObjectState.php index ffc15770..ddf1c88f 100644 --- a/src/lib/Server/Controller/ObjectState.php +++ b/src/lib/Server/Controller/ObjectState.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Controller; use Ibexa\Contracts\Core\Repository\ContentService; diff --git a/src/lib/Server/Controller/Options.php b/src/lib/Server/Controller/Options.php index 4b8a4fe1..53c11b61 100644 --- a/src/lib/Server/Controller/Options.php +++ b/src/lib/Server/Controller/Options.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Controller; use Ibexa\Rest\Server\Controller as RestController; diff --git a/src/lib/Server/Controller/Role.php b/src/lib/Server/Controller/Role.php index 91362d74..5c60d153 100644 --- a/src/lib/Server/Controller/Role.php +++ b/src/lib/Server/Controller/Role.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Controller; use Ibexa\Contracts\Core\Repository\Exceptions\LimitationValidationException; diff --git a/src/lib/Server/Controller/Root.php b/src/lib/Server/Controller/Root.php index c30e33d8..6d29adf0 100644 --- a/src/lib/Server/Controller/Root.php +++ b/src/lib/Server/Controller/Root.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Controller; use Ibexa\Contracts\Rest\Exceptions\NotFoundException; diff --git a/src/lib/Server/Controller/Section.php b/src/lib/Server/Controller/Section.php index 3e153bda..137b2e26 100644 --- a/src/lib/Server/Controller/Section.php +++ b/src/lib/Server/Controller/Section.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Controller; use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException; diff --git a/src/lib/Server/Controller/Services.php b/src/lib/Server/Controller/Services.php index d1cde104..9f2853b1 100644 --- a/src/lib/Server/Controller/Services.php +++ b/src/lib/Server/Controller/Services.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Controller; use Ibexa\Rest\Server\Controller as RestController; diff --git a/src/lib/Server/Controller/SessionController.php b/src/lib/Server/Controller/SessionController.php index e46f2e25..30f043f9 100644 --- a/src/lib/Server/Controller/SessionController.php +++ b/src/lib/Server/Controller/SessionController.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Controller; use Ibexa\Contracts\Core\Repository\PermissionResolver; diff --git a/src/lib/Server/Controller/Trash.php b/src/lib/Server/Controller/Trash.php index 0f73cad1..5442cfbb 100644 --- a/src/lib/Server/Controller/Trash.php +++ b/src/lib/Server/Controller/Trash.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Controller; use Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException; diff --git a/src/lib/Server/Controller/URLAlias.php b/src/lib/Server/Controller/URLAlias.php index 056dea65..bbf530d7 100644 --- a/src/lib/Server/Controller/URLAlias.php +++ b/src/lib/Server/Controller/URLAlias.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Controller; use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException; diff --git a/src/lib/Server/Controller/URLWildcard.php b/src/lib/Server/Controller/URLWildcard.php index 611d48b0..050ca8f9 100644 --- a/src/lib/Server/Controller/URLWildcard.php +++ b/src/lib/Server/Controller/URLWildcard.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Controller; use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException; diff --git a/src/lib/Server/Controller/User.php b/src/lib/Server/Controller/User.php index 2b9fd2eb..83112169 100644 --- a/src/lib/Server/Controller/User.php +++ b/src/lib/Server/Controller/User.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Controller; use Ibexa\Contracts\Core\Repository\ContentService; diff --git a/src/lib/Server/Controller/Views.php b/src/lib/Server/Controller/Views.php index bf704cb0..4b60312f 100644 --- a/src/lib/Server/Controller/Views.php +++ b/src/lib/Server/Controller/Views.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Controller; use Ibexa\Contracts\Core\Repository\Exceptions\NotImplementedException; diff --git a/src/lib/Server/Exceptions/AuthenticationFailedException.php b/src/lib/Server/Exceptions/AuthenticationFailedException.php index 74ecc76c..deeb0bd8 100644 --- a/src/lib/Server/Exceptions/AuthenticationFailedException.php +++ b/src/lib/Server/Exceptions/AuthenticationFailedException.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Exceptions; use InvalidArgumentException; diff --git a/src/lib/Server/Exceptions/BadRequestException.php b/src/lib/Server/Exceptions/BadRequestException.php index bbb5b45c..6a4d266b 100644 --- a/src/lib/Server/Exceptions/BadRequestException.php +++ b/src/lib/Server/Exceptions/BadRequestException.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Exceptions; use InvalidArgumentException; diff --git a/src/lib/Server/Exceptions/ContentFieldValidationException.php b/src/lib/Server/Exceptions/ContentFieldValidationException.php index 2edba442..4240da21 100644 --- a/src/lib/Server/Exceptions/ContentFieldValidationException.php +++ b/src/lib/Server/Exceptions/ContentFieldValidationException.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Exceptions; use Ibexa\Contracts\Core\Repository\Exceptions\ContentFieldValidationException as APIContentFieldValidationException; diff --git a/src/lib/Server/Exceptions/ForbiddenException.php b/src/lib/Server/Exceptions/ForbiddenException.php index 56110264..7047fe54 100644 --- a/src/lib/Server/Exceptions/ForbiddenException.php +++ b/src/lib/Server/Exceptions/ForbiddenException.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Exceptions; use InvalidArgumentException; diff --git a/src/lib/Server/Exceptions/InvalidUserTypeException.php b/src/lib/Server/Exceptions/InvalidUserTypeException.php index 3dc62cba..297ccd83 100644 --- a/src/lib/Server/Exceptions/InvalidUserTypeException.php +++ b/src/lib/Server/Exceptions/InvalidUserTypeException.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Exceptions; use Symfony\Component\Security\Core\Exception\AuthenticationException; diff --git a/src/lib/Server/Exceptions/UserConflictException.php b/src/lib/Server/Exceptions/UserConflictException.php index 055e5d2f..15cbe58e 100644 --- a/src/lib/Server/Exceptions/UserConflictException.php +++ b/src/lib/Server/Exceptions/UserConflictException.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Exceptions; use Symfony\Component\Security\Core\Exception\AuthenticationException; diff --git a/src/lib/Server/Input/Parser/ContentCreate.php b/src/lib/Server/Input/Parser/ContentCreate.php index 50b572c8..d8d0a6fe 100644 --- a/src/lib/Server/Input/Parser/ContentCreate.php +++ b/src/lib/Server/Input/Parser/ContentCreate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use DateTime; diff --git a/src/lib/Server/Input/Parser/ContentQuery.php b/src/lib/Server/Input/Parser/ContentQuery.php index ced52438..09ca3400 100644 --- a/src/lib/Server/Input/Parser/ContentQuery.php +++ b/src/lib/Server/Input/Parser/ContentQuery.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\Content\Query; diff --git a/src/lib/Server/Input/Parser/ContentTypeCreate.php b/src/lib/Server/Input/Parser/ContentTypeCreate.php index 2dc5a9cd..e658c437 100644 --- a/src/lib/Server/Input/Parser/ContentTypeCreate.php +++ b/src/lib/Server/Input/Parser/ContentTypeCreate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use DateTime; diff --git a/src/lib/Server/Input/Parser/ContentTypeGroupInput.php b/src/lib/Server/Input/Parser/ContentTypeGroupInput.php index 1860e2b1..9b694819 100644 --- a/src/lib/Server/Input/Parser/ContentTypeGroupInput.php +++ b/src/lib/Server/Input/Parser/ContentTypeGroupInput.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use DateTime; diff --git a/src/lib/Server/Input/Parser/ContentTypeUpdate.php b/src/lib/Server/Input/Parser/ContentTypeUpdate.php index 53c311e7..4eb9bf83 100644 --- a/src/lib/Server/Input/Parser/ContentTypeUpdate.php +++ b/src/lib/Server/Input/Parser/ContentTypeUpdate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use DateTime; diff --git a/src/lib/Server/Input/Parser/ContentUpdate.php b/src/lib/Server/Input/Parser/ContentUpdate.php index 6a8995c8..ea8f807f 100644 --- a/src/lib/Server/Input/Parser/ContentUpdate.php +++ b/src/lib/Server/Input/Parser/ContentUpdate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use DateTime; diff --git a/src/lib/Server/Input/Parser/Criterion.php b/src/lib/Server/Input/Parser/Criterion.php index bfb08325..aebf8676 100644 --- a/src/lib/Server/Input/Parser/Criterion.php +++ b/src/lib/Server/Input/Parser/Criterion.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Aggregation; diff --git a/src/lib/Server/Input/Parser/Criterion/Ancestor.php b/src/lib/Server/Input/Parser/Criterion/Ancestor.php index 103c8c64..530fc77e 100644 --- a/src/lib/Server/Input/Parser/Criterion/Ancestor.php +++ b/src/lib/Server/Input/Parser/Criterion/Ancestor.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\Ancestor as AncestorCriterion; diff --git a/src/lib/Server/Input/Parser/Criterion/ContentId.php b/src/lib/Server/Input/Parser/Criterion/ContentId.php index 2baf65bf..12225569 100644 --- a/src/lib/Server/Input/Parser/Criterion/ContentId.php +++ b/src/lib/Server/Input/Parser/Criterion/ContentId.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\ContentId as ContentIdCriterion; diff --git a/src/lib/Server/Input/Parser/Criterion/ContentRemoteId.php b/src/lib/Server/Input/Parser/Criterion/ContentRemoteId.php index c0390fb9..ccc519be 100644 --- a/src/lib/Server/Input/Parser/Criterion/ContentRemoteId.php +++ b/src/lib/Server/Input/Parser/Criterion/ContentRemoteId.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\RemoteId as ContentRemoteIdCriterion; diff --git a/src/lib/Server/Input/Parser/Criterion/ContentTypeGroupId.php b/src/lib/Server/Input/Parser/Criterion/ContentTypeGroupId.php index c3a53206..a21418e1 100644 --- a/src/lib/Server/Input/Parser/Criterion/ContentTypeGroupId.php +++ b/src/lib/Server/Input/Parser/Criterion/ContentTypeGroupId.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\ContentTypeGroupId as ContentTypeGroupIdCriterion; diff --git a/src/lib/Server/Input/Parser/Criterion/ContentTypeId.php b/src/lib/Server/Input/Parser/Criterion/ContentTypeId.php index edb11d5e..8dec686c 100644 --- a/src/lib/Server/Input/Parser/Criterion/ContentTypeId.php +++ b/src/lib/Server/Input/Parser/Criterion/ContentTypeId.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\ContentTypeId as ContentTypeIdCriterion; diff --git a/src/lib/Server/Input/Parser/Criterion/ContentTypeIdentifier.php b/src/lib/Server/Input/Parser/Criterion/ContentTypeIdentifier.php index 2826f1f6..395cc3b1 100644 --- a/src/lib/Server/Input/Parser/Criterion/ContentTypeIdentifier.php +++ b/src/lib/Server/Input/Parser/Criterion/ContentTypeIdentifier.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\ContentTypeService; diff --git a/src/lib/Server/Input/Parser/Criterion/DateMetadata.php b/src/lib/Server/Input/Parser/Criterion/DateMetadata.php index d8398a5b..e8ce8aed 100644 --- a/src/lib/Server/Input/Parser/Criterion/DateMetadata.php +++ b/src/lib/Server/Input/Parser/Criterion/DateMetadata.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\DateMetadata as DateMetadataCriterion; diff --git a/src/lib/Server/Input/Parser/Criterion/Field.php b/src/lib/Server/Input/Parser/Criterion/Field.php index d3e6dcc4..980cb396 100644 --- a/src/lib/Server/Input/Parser/Criterion/Field.php +++ b/src/lib/Server/Input/Parser/Criterion/Field.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\Field as FieldCriterion; diff --git a/src/lib/Server/Input/Parser/Criterion/FullText.php b/src/lib/Server/Input/Parser/Criterion/FullText.php index afb6b570..85fc3c4d 100644 --- a/src/lib/Server/Input/Parser/Criterion/FullText.php +++ b/src/lib/Server/Input/Parser/Criterion/FullText.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\FullText as FullTextCriterion; diff --git a/src/lib/Server/Input/Parser/Criterion/LanguageCode.php b/src/lib/Server/Input/Parser/Criterion/LanguageCode.php index 04810fa0..db3c0c4a 100644 --- a/src/lib/Server/Input/Parser/Criterion/LanguageCode.php +++ b/src/lib/Server/Input/Parser/Criterion/LanguageCode.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\LanguageCode as LanguageCodeCriterion; diff --git a/src/lib/Server/Input/Parser/Criterion/LocationId.php b/src/lib/Server/Input/Parser/Criterion/LocationId.php index 51fe9027..18129aa2 100644 --- a/src/lib/Server/Input/Parser/Criterion/LocationId.php +++ b/src/lib/Server/Input/Parser/Criterion/LocationId.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\LocationId as LocationIdCriterion; diff --git a/src/lib/Server/Input/Parser/Criterion/LocationRemoteId.php b/src/lib/Server/Input/Parser/Criterion/LocationRemoteId.php index 5bafbac9..894e07ce 100644 --- a/src/lib/Server/Input/Parser/Criterion/LocationRemoteId.php +++ b/src/lib/Server/Input/Parser/Criterion/LocationRemoteId.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\LocationRemoteId as LocationRemoteIdCriterion; diff --git a/src/lib/Server/Input/Parser/Criterion/LogicalAnd.php b/src/lib/Server/Input/Parser/Criterion/LogicalAnd.php index 001bfc8e..2229180f 100644 --- a/src/lib/Server/Input/Parser/Criterion/LogicalAnd.php +++ b/src/lib/Server/Input/Parser/Criterion/LogicalAnd.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values; diff --git a/src/lib/Server/Input/Parser/Criterion/LogicalNot.php b/src/lib/Server/Input/Parser/Criterion/LogicalNot.php index 5bf03b78..2297d96c 100644 --- a/src/lib/Server/Input/Parser/Criterion/LogicalNot.php +++ b/src/lib/Server/Input/Parser/Criterion/LogicalNot.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\LogicalNot as LogicalNotCriterion; diff --git a/src/lib/Server/Input/Parser/Criterion/LogicalOperator.php b/src/lib/Server/Input/Parser/Criterion/LogicalOperator.php index 155c76f2..ffef50e6 100644 --- a/src/lib/Server/Input/Parser/Criterion/LogicalOperator.php +++ b/src/lib/Server/Input/Parser/Criterion/LogicalOperator.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Rest\Input\ParsingDispatcher; diff --git a/src/lib/Server/Input/Parser/Criterion/LogicalOr.php b/src/lib/Server/Input/Parser/Criterion/LogicalOr.php index e193509a..b84026ee 100644 --- a/src/lib/Server/Input/Parser/Criterion/LogicalOr.php +++ b/src/lib/Server/Input/Parser/Criterion/LogicalOr.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values; diff --git a/src/lib/Server/Input/Parser/Criterion/MoreLikeThis.php b/src/lib/Server/Input/Parser/Criterion/MoreLikeThis.php index 124d1086..53d13e3c 100644 --- a/src/lib/Server/Input/Parser/Criterion/MoreLikeThis.php +++ b/src/lib/Server/Input/Parser/Criterion/MoreLikeThis.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Rest\Input\ParsingDispatcher; diff --git a/src/lib/Server/Input/Parser/Criterion/ObjectStateId.php b/src/lib/Server/Input/Parser/Criterion/ObjectStateId.php index c7af6dd6..64aaec0c 100644 --- a/src/lib/Server/Input/Parser/Criterion/ObjectStateId.php +++ b/src/lib/Server/Input/Parser/Criterion/ObjectStateId.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\ObjectStateId as ObjectStateIdCriterion; diff --git a/src/lib/Server/Input/Parser/Criterion/Operator.php b/src/lib/Server/Input/Parser/Criterion/Operator.php index 26def8c6..b85b5fcb 100644 --- a/src/lib/Server/Input/Parser/Criterion/Operator.php +++ b/src/lib/Server/Input/Parser/Criterion/Operator.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Rest\Input\ParsingDispatcher; diff --git a/src/lib/Server/Input/Parser/Criterion/ParentLocationId.php b/src/lib/Server/Input/Parser/Criterion/ParentLocationId.php index 7df7ea27..d98e87f3 100644 --- a/src/lib/Server/Input/Parser/Criterion/ParentLocationId.php +++ b/src/lib/Server/Input/Parser/Criterion/ParentLocationId.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\ParentLocationId as ParentLocationIdCriterion; diff --git a/src/lib/Server/Input/Parser/Criterion/ParentLocationRemoteId.php b/src/lib/Server/Input/Parser/Criterion/ParentLocationRemoteId.php index dedad939..0a89c294 100644 --- a/src/lib/Server/Input/Parser/Criterion/ParentLocationRemoteId.php +++ b/src/lib/Server/Input/Parser/Criterion/ParentLocationRemoteId.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\LocationService; diff --git a/src/lib/Server/Input/Parser/Criterion/SectionId.php b/src/lib/Server/Input/Parser/Criterion/SectionId.php index 1a5cb7b3..7a533f19 100644 --- a/src/lib/Server/Input/Parser/Criterion/SectionId.php +++ b/src/lib/Server/Input/Parser/Criterion/SectionId.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\SectionId as SectionIdCriterion; diff --git a/src/lib/Server/Input/Parser/Criterion/Subtree.php b/src/lib/Server/Input/Parser/Criterion/Subtree.php index 0523066a..bf96a5ee 100644 --- a/src/lib/Server/Input/Parser/Criterion/Subtree.php +++ b/src/lib/Server/Input/Parser/Criterion/Subtree.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\Subtree as SubtreeCriterion; diff --git a/src/lib/Server/Input/Parser/Criterion/UserMetadata.php b/src/lib/Server/Input/Parser/Criterion/UserMetadata.php index eee7339a..440862a8 100644 --- a/src/lib/Server/Input/Parser/Criterion/UserMetadata.php +++ b/src/lib/Server/Input/Parser/Criterion/UserMetadata.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\UserMetadata as UserMetadataCriterion; diff --git a/src/lib/Server/Input/Parser/Criterion/Visibility.php b/src/lib/Server/Input/Parser/Criterion/Visibility.php index 109115ea..1031114e 100644 --- a/src/lib/Server/Input/Parser/Criterion/Visibility.php +++ b/src/lib/Server/Input/Parser/Criterion/Visibility.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\Visibility as VisibilityCriterion; diff --git a/src/lib/Server/Input/Parser/FacetBuilder/ContentTypeParser.php b/src/lib/Server/Input/Parser/FacetBuilder/ContentTypeParser.php index 522af508..765aa5b7 100644 --- a/src/lib/Server/Input/Parser/FacetBuilder/ContentTypeParser.php +++ b/src/lib/Server/Input/Parser/FacetBuilder/ContentTypeParser.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\FacetBuilder; use Ibexa\Contracts\Core\Repository\Values\Content\Query\FacetBuilder\ContentTypeFacetBuilder; diff --git a/src/lib/Server/Input/Parser/FacetBuilder/CriterionParser.php b/src/lib/Server/Input/Parser/FacetBuilder/CriterionParser.php index 4bd8452c..0f741253 100644 --- a/src/lib/Server/Input/Parser/FacetBuilder/CriterionParser.php +++ b/src/lib/Server/Input/Parser/FacetBuilder/CriterionParser.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\FacetBuilder; use Ibexa\Contracts\Core\Repository\Values\Content\Query\FacetBuilder\CriterionFacetBuilder; diff --git a/src/lib/Server/Input/Parser/FacetBuilder/DateRangeParser.php b/src/lib/Server/Input/Parser/FacetBuilder/DateRangeParser.php index e4de82c8..2d02c0ce 100644 --- a/src/lib/Server/Input/Parser/FacetBuilder/DateRangeParser.php +++ b/src/lib/Server/Input/Parser/FacetBuilder/DateRangeParser.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\FacetBuilder; use Ibexa\Contracts\Core\Repository\Values\Content\Query\FacetBuilder\DateRangeFacetBuilder; diff --git a/src/lib/Server/Input/Parser/FacetBuilder/FieldParser.php b/src/lib/Server/Input/Parser/FacetBuilder/FieldParser.php index 0f2740b8..800db883 100644 --- a/src/lib/Server/Input/Parser/FacetBuilder/FieldParser.php +++ b/src/lib/Server/Input/Parser/FacetBuilder/FieldParser.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\FacetBuilder; use Ibexa\Contracts\Core\Repository\Values\Content\Query\FacetBuilder\FieldFacetBuilder; diff --git a/src/lib/Server/Input/Parser/FacetBuilder/FieldRangeParser.php b/src/lib/Server/Input/Parser/FacetBuilder/FieldRangeParser.php index 6922f7c1..b8774a03 100644 --- a/src/lib/Server/Input/Parser/FacetBuilder/FieldRangeParser.php +++ b/src/lib/Server/Input/Parser/FacetBuilder/FieldRangeParser.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\FacetBuilder; use Ibexa\Contracts\Rest\Exceptions; diff --git a/src/lib/Server/Input/Parser/FacetBuilder/LocationParser.php b/src/lib/Server/Input/Parser/FacetBuilder/LocationParser.php index 93fb0393..6b1304a4 100644 --- a/src/lib/Server/Input/Parser/FacetBuilder/LocationParser.php +++ b/src/lib/Server/Input/Parser/FacetBuilder/LocationParser.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\FacetBuilder; use Ibexa\Contracts\Core\Repository\Values\Content\Query\FacetBuilder\LocationFacetBuilder; diff --git a/src/lib/Server/Input/Parser/FacetBuilder/SectionParser.php b/src/lib/Server/Input/Parser/FacetBuilder/SectionParser.php index 8a860eab..8257818e 100644 --- a/src/lib/Server/Input/Parser/FacetBuilder/SectionParser.php +++ b/src/lib/Server/Input/Parser/FacetBuilder/SectionParser.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\FacetBuilder; use Ibexa\Contracts\Core\Repository\Values\Content\Query\FacetBuilder\SectionFacetBuilder; diff --git a/src/lib/Server/Input/Parser/FacetBuilder/TermParser.php b/src/lib/Server/Input/Parser/FacetBuilder/TermParser.php index 09036a76..6d1a4b7d 100644 --- a/src/lib/Server/Input/Parser/FacetBuilder/TermParser.php +++ b/src/lib/Server/Input/Parser/FacetBuilder/TermParser.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\FacetBuilder; use Ibexa\Contracts\Core\Repository\Values\Content\Query\FacetBuilder\TermFacetBuilder; diff --git a/src/lib/Server/Input/Parser/FacetBuilder/UserParser.php b/src/lib/Server/Input/Parser/FacetBuilder/UserParser.php index ed8aa9b2..4900e5bc 100644 --- a/src/lib/Server/Input/Parser/FacetBuilder/UserParser.php +++ b/src/lib/Server/Input/Parser/FacetBuilder/UserParser.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\FacetBuilder; use Ibexa\Contracts\Core\Repository\Values\Content\Query\FacetBuilder\UserFacetBuilder; diff --git a/src/lib/Server/Input/Parser/FieldDefinitionCreate.php b/src/lib/Server/Input/Parser/FieldDefinitionCreate.php index 06f7eff2..8e9d9433 100644 --- a/src/lib/Server/Input/Parser/FieldDefinitionCreate.php +++ b/src/lib/Server/Input/Parser/FieldDefinitionCreate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Exception; diff --git a/src/lib/Server/Input/Parser/FieldDefinitionUpdate.php b/src/lib/Server/Input/Parser/FieldDefinitionUpdate.php index 3a4395bd..80d76cef 100644 --- a/src/lib/Server/Input/Parser/FieldDefinitionUpdate.php +++ b/src/lib/Server/Input/Parser/FieldDefinitionUpdate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\ContentTypeService; diff --git a/src/lib/Server/Input/Parser/Limitation/PathStringRouteBasedLimitationParser.php b/src/lib/Server/Input/Parser/Limitation/PathStringRouteBasedLimitationParser.php index 5473fcf8..522e8710 100644 --- a/src/lib/Server/Input/Parser/Limitation/PathStringRouteBasedLimitationParser.php +++ b/src/lib/Server/Input/Parser/Limitation/PathStringRouteBasedLimitationParser.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Limitation; use Ibexa\Contracts\Rest\Exceptions; diff --git a/src/lib/Server/Input/Parser/Limitation/RouteBasedLimitationParser.php b/src/lib/Server/Input/Parser/Limitation/RouteBasedLimitationParser.php index e1112c0e..6825ba58 100644 --- a/src/lib/Server/Input/Parser/Limitation/RouteBasedLimitationParser.php +++ b/src/lib/Server/Input/Parser/Limitation/RouteBasedLimitationParser.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\Limitation; use Ibexa\Contracts\Rest\Exceptions; diff --git a/src/lib/Server/Input/Parser/LocationCreate.php b/src/lib/Server/Input/Parser/LocationCreate.php index 6957449e..213d0f95 100644 --- a/src/lib/Server/Input/Parser/LocationCreate.php +++ b/src/lib/Server/Input/Parser/LocationCreate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\LocationService; diff --git a/src/lib/Server/Input/Parser/LocationQuery.php b/src/lib/Server/Input/Parser/LocationQuery.php index 82fd80d0..5f9bee66 100644 --- a/src/lib/Server/Input/Parser/LocationQuery.php +++ b/src/lib/Server/Input/Parser/LocationQuery.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\Content\LocationQuery as LocationQueryValueObject; diff --git a/src/lib/Server/Input/Parser/LocationUpdate.php b/src/lib/Server/Input/Parser/LocationUpdate.php index 5bfbc954..de5f5c49 100644 --- a/src/lib/Server/Input/Parser/LocationUpdate.php +++ b/src/lib/Server/Input/Parser/LocationUpdate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\LocationService; diff --git a/src/lib/Server/Input/Parser/ObjectStateCreate.php b/src/lib/Server/Input/Parser/ObjectStateCreate.php index 6ed95925..fd091c9c 100644 --- a/src/lib/Server/Input/Parser/ObjectStateCreate.php +++ b/src/lib/Server/Input/Parser/ObjectStateCreate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\ObjectStateService; diff --git a/src/lib/Server/Input/Parser/ObjectStateGroupCreate.php b/src/lib/Server/Input/Parser/ObjectStateGroupCreate.php index ca20e7ec..cf8b427a 100644 --- a/src/lib/Server/Input/Parser/ObjectStateGroupCreate.php +++ b/src/lib/Server/Input/Parser/ObjectStateGroupCreate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\ObjectStateService; diff --git a/src/lib/Server/Input/Parser/ObjectStateGroupUpdate.php b/src/lib/Server/Input/Parser/ObjectStateGroupUpdate.php index f787d320..96631b9c 100644 --- a/src/lib/Server/Input/Parser/ObjectStateGroupUpdate.php +++ b/src/lib/Server/Input/Parser/ObjectStateGroupUpdate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\ObjectStateService; diff --git a/src/lib/Server/Input/Parser/ObjectStateUpdate.php b/src/lib/Server/Input/Parser/ObjectStateUpdate.php index a99f2458..2e627129 100644 --- a/src/lib/Server/Input/Parser/ObjectStateUpdate.php +++ b/src/lib/Server/Input/Parser/ObjectStateUpdate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\ObjectStateService; diff --git a/src/lib/Server/Input/Parser/PolicyCreate.php b/src/lib/Server/Input/Parser/PolicyCreate.php index 336d1d4d..cb75ae9f 100644 --- a/src/lib/Server/Input/Parser/PolicyCreate.php +++ b/src/lib/Server/Input/Parser/PolicyCreate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\RoleService; diff --git a/src/lib/Server/Input/Parser/PolicyUpdate.php b/src/lib/Server/Input/Parser/PolicyUpdate.php index 35d05674..4950c18f 100644 --- a/src/lib/Server/Input/Parser/PolicyUpdate.php +++ b/src/lib/Server/Input/Parser/PolicyUpdate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\RoleService; diff --git a/src/lib/Server/Input/Parser/Query.php b/src/lib/Server/Input/Parser/Query.php index 4479408d..f4ac1aa5 100644 --- a/src/lib/Server/Input/Parser/Query.php +++ b/src/lib/Server/Input/Parser/Query.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion as CriterionValue; diff --git a/src/lib/Server/Input/Parser/RelationCreate.php b/src/lib/Server/Input/Parser/RelationCreate.php index b595475e..61efffa8 100644 --- a/src/lib/Server/Input/Parser/RelationCreate.php +++ b/src/lib/Server/Input/Parser/RelationCreate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Rest\Exceptions; diff --git a/src/lib/Server/Input/Parser/RoleAssignInput.php b/src/lib/Server/Input/Parser/RoleAssignInput.php index 9a11d63a..6b06ecec 100644 --- a/src/lib/Server/Input/Parser/RoleAssignInput.php +++ b/src/lib/Server/Input/Parser/RoleAssignInput.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Rest\Exceptions; diff --git a/src/lib/Server/Input/Parser/RoleInput.php b/src/lib/Server/Input/Parser/RoleInput.php index fa97219c..0873aba6 100644 --- a/src/lib/Server/Input/Parser/RoleInput.php +++ b/src/lib/Server/Input/Parser/RoleInput.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\RoleService; diff --git a/src/lib/Server/Input/Parser/SectionInput.php b/src/lib/Server/Input/Parser/SectionInput.php index 1ee1a2af..a747719a 100644 --- a/src/lib/Server/Input/Parser/SectionInput.php +++ b/src/lib/Server/Input/Parser/SectionInput.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\SectionService; diff --git a/src/lib/Server/Input/Parser/SessionInput.php b/src/lib/Server/Input/Parser/SessionInput.php index 40926fb9..e2b60bb8 100644 --- a/src/lib/Server/Input/Parser/SessionInput.php +++ b/src/lib/Server/Input/Parser/SessionInput.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Rest\Exceptions; diff --git a/src/lib/Server/Input/Parser/SortClause/DataKeyValueObjectClass.php b/src/lib/Server/Input/Parser/SortClause/DataKeyValueObjectClass.php index 40a707dc..963cb2b9 100644 --- a/src/lib/Server/Input/Parser/SortClause/DataKeyValueObjectClass.php +++ b/src/lib/Server/Input/Parser/SortClause/DataKeyValueObjectClass.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\SortClause; use Ibexa\Contracts\Core\Repository\Values\Content\Query; diff --git a/src/lib/Server/Input/Parser/SortClause/Field.php b/src/lib/Server/Input/Parser/SortClause/Field.php index 3075a42b..150aecb8 100644 --- a/src/lib/Server/Input/Parser/SortClause/Field.php +++ b/src/lib/Server/Input/Parser/SortClause/Field.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser\SortClause; use Ibexa\Contracts\Core\Repository\Values\Content\Query; diff --git a/src/lib/Server/Input/Parser/URLAliasCreate.php b/src/lib/Server/Input/Parser/URLAliasCreate.php index 294c9db0..4924e902 100644 --- a/src/lib/Server/Input/Parser/URLAliasCreate.php +++ b/src/lib/Server/Input/Parser/URLAliasCreate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Rest\Exceptions; diff --git a/src/lib/Server/Input/Parser/URLWildcardCreate.php b/src/lib/Server/Input/Parser/URLWildcardCreate.php index 436d8d79..3880e217 100644 --- a/src/lib/Server/Input/Parser/URLWildcardCreate.php +++ b/src/lib/Server/Input/Parser/URLWildcardCreate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Rest\Exceptions; diff --git a/src/lib/Server/Input/Parser/UserCreate.php b/src/lib/Server/Input/Parser/UserCreate.php index 50674c76..e045ee09 100644 --- a/src/lib/Server/Input/Parser/UserCreate.php +++ b/src/lib/Server/Input/Parser/UserCreate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\ContentTypeService; diff --git a/src/lib/Server/Input/Parser/UserGroupCreate.php b/src/lib/Server/Input/Parser/UserGroupCreate.php index c294c938..4482d01d 100644 --- a/src/lib/Server/Input/Parser/UserGroupCreate.php +++ b/src/lib/Server/Input/Parser/UserGroupCreate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\ContentTypeService; diff --git a/src/lib/Server/Input/Parser/UserGroupUpdate.php b/src/lib/Server/Input/Parser/UserGroupUpdate.php index e10929ba..2538764d 100644 --- a/src/lib/Server/Input/Parser/UserGroupUpdate.php +++ b/src/lib/Server/Input/Parser/UserGroupUpdate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\ContentService; diff --git a/src/lib/Server/Input/Parser/UserUpdate.php b/src/lib/Server/Input/Parser/UserUpdate.php index 9b0112b6..e5113f06 100644 --- a/src/lib/Server/Input/Parser/UserUpdate.php +++ b/src/lib/Server/Input/Parser/UserUpdate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\ContentService; diff --git a/src/lib/Server/Input/Parser/VersionUpdate.php b/src/lib/Server/Input/Parser/VersionUpdate.php index 6a230489..43ae50a4 100644 --- a/src/lib/Server/Input/Parser/VersionUpdate.php +++ b/src/lib/Server/Input/Parser/VersionUpdate.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\ContentService; diff --git a/src/lib/Server/Input/Parser/ViewInput.php b/src/lib/Server/Input/Parser/ViewInput.php index 656a22b9..15b3646c 100644 --- a/src/lib/Server/Input/Parser/ViewInput.php +++ b/src/lib/Server/Input/Parser/ViewInput.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Rest\Exceptions; diff --git a/src/lib/Server/Input/Parser/ViewInputOneDotOne.php b/src/lib/Server/Input/Parser/ViewInputOneDotOne.php index 6fdad2c2..2a8dfc9b 100644 --- a/src/lib/Server/Input/Parser/ViewInputOneDotOne.php +++ b/src/lib/Server/Input/Parser/ViewInputOneDotOne.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Input\Parser; use Ibexa\Contracts\Rest\Exceptions; diff --git a/src/lib/Server/Output/ValueObjectVisitor/BadRequestException.php b/src/lib/Server/Output/ValueObjectVisitor/BadRequestException.php index 19d21692..09c401df 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/BadRequestException.php +++ b/src/lib/Server/Output/ValueObjectVisitor/BadRequestException.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; /** diff --git a/src/lib/Server/Output/ValueObjectVisitor/BadStateException.php b/src/lib/Server/Output/ValueObjectVisitor/BadStateException.php index 3a268161..7a2a968e 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/BadStateException.php +++ b/src/lib/Server/Output/ValueObjectVisitor/BadStateException.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; /** diff --git a/src/lib/Server/Output/ValueObjectVisitor/CachedValue.php b/src/lib/Server/Output/ValueObjectVisitor/CachedValue.php index e4332ec9..1bb425f4 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/CachedValue.php +++ b/src/lib/Server/Output/ValueObjectVisitor/CachedValue.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\SiteAccess\ConfigResolverInterface; diff --git a/src/lib/Server/Output/ValueObjectVisitor/Conflict.php b/src/lib/Server/Output/ValueObjectVisitor/Conflict.php index 35ba5766..f728ac44 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/Conflict.php +++ b/src/lib/Server/Output/ValueObjectVisitor/Conflict.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/ContentFieldValidationException.php b/src/lib/Server/Output/ValueObjectVisitor/ContentFieldValidationException.php index 22a99dbe..cb337bfb 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/ContentFieldValidationException.php +++ b/src/lib/Server/Output/ValueObjectVisitor/ContentFieldValidationException.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Translation; diff --git a/src/lib/Server/Output/ValueObjectVisitor/ContentList.php b/src/lib/Server/Output/ValueObjectVisitor/ContentList.php index be3b861d..df9688c4 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/ContentList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/ContentList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/ContentTypeGroup.php b/src/lib/Server/Output/ValueObjectVisitor/ContentTypeGroup.php index 97f93929..19f1f7c3 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/ContentTypeGroup.php +++ b/src/lib/Server/Output/ValueObjectVisitor/ContentTypeGroup.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\ContentType\ContentTypeGroup as ContentTypeGroupValue; diff --git a/src/lib/Server/Output/ValueObjectVisitor/ContentTypeGroupList.php b/src/lib/Server/Output/ValueObjectVisitor/ContentTypeGroupList.php index 88f79391..d05eda95 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/ContentTypeGroupList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/ContentTypeGroupList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/ContentTypeGroupRefList.php b/src/lib/Server/Output/ValueObjectVisitor/ContentTypeGroupRefList.php index c15d1305..eb346573 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/ContentTypeGroupRefList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/ContentTypeGroupRefList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/ContentTypeInfoList.php b/src/lib/Server/Output/ValueObjectVisitor/ContentTypeInfoList.php index 86b7e394..55210cfe 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/ContentTypeInfoList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/ContentTypeInfoList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/ContentTypeList.php b/src/lib/Server/Output/ValueObjectVisitor/ContentTypeList.php index 4d5a5a69..73f0d84e 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/ContentTypeList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/ContentTypeList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/CountryList.php b/src/lib/Server/Output/ValueObjectVisitor/CountryList.php index 25d57b97..4958d26c 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/CountryList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/CountryList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/CreatedContent.php b/src/lib/Server/Output/ValueObjectVisitor/CreatedContent.php index 8b484692..3d6243d8 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/CreatedContent.php +++ b/src/lib/Server/Output/ValueObjectVisitor/CreatedContent.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/CreatedContentType.php b/src/lib/Server/Output/ValueObjectVisitor/CreatedContentType.php index 935a7325..f6faaadf 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/CreatedContentType.php +++ b/src/lib/Server/Output/ValueObjectVisitor/CreatedContentType.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/CreatedContentTypeGroup.php b/src/lib/Server/Output/ValueObjectVisitor/CreatedContentTypeGroup.php index e6d9d4d0..a98e6d8e 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/CreatedContentTypeGroup.php +++ b/src/lib/Server/Output/ValueObjectVisitor/CreatedContentTypeGroup.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/CreatedFieldDefinition.php b/src/lib/Server/Output/ValueObjectVisitor/CreatedFieldDefinition.php index 1f7cc244..10b1cd58 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/CreatedFieldDefinition.php +++ b/src/lib/Server/Output/ValueObjectVisitor/CreatedFieldDefinition.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/CreatedLocation.php b/src/lib/Server/Output/ValueObjectVisitor/CreatedLocation.php index d6efc4de..39eb6c5f 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/CreatedLocation.php +++ b/src/lib/Server/Output/ValueObjectVisitor/CreatedLocation.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/CreatedObjectState.php b/src/lib/Server/Output/ValueObjectVisitor/CreatedObjectState.php index c7eaf381..e2f8b4b1 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/CreatedObjectState.php +++ b/src/lib/Server/Output/ValueObjectVisitor/CreatedObjectState.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/CreatedObjectStateGroup.php b/src/lib/Server/Output/ValueObjectVisitor/CreatedObjectStateGroup.php index c6fc62e8..ef511e90 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/CreatedObjectStateGroup.php +++ b/src/lib/Server/Output/ValueObjectVisitor/CreatedObjectStateGroup.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/CreatedPolicy.php b/src/lib/Server/Output/ValueObjectVisitor/CreatedPolicy.php index 12c59c8f..2f2b1d6e 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/CreatedPolicy.php +++ b/src/lib/Server/Output/ValueObjectVisitor/CreatedPolicy.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/CreatedRelation.php b/src/lib/Server/Output/ValueObjectVisitor/CreatedRelation.php index 2c0d8ff3..9ec1c575 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/CreatedRelation.php +++ b/src/lib/Server/Output/ValueObjectVisitor/CreatedRelation.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/CreatedRole.php b/src/lib/Server/Output/ValueObjectVisitor/CreatedRole.php index 0fe27052..833ec352 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/CreatedRole.php +++ b/src/lib/Server/Output/ValueObjectVisitor/CreatedRole.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/CreatedSection.php b/src/lib/Server/Output/ValueObjectVisitor/CreatedSection.php index 37cbda1b..7609b91b 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/CreatedSection.php +++ b/src/lib/Server/Output/ValueObjectVisitor/CreatedSection.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/CreatedURLAlias.php b/src/lib/Server/Output/ValueObjectVisitor/CreatedURLAlias.php index 6116cb5a..b0857726 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/CreatedURLAlias.php +++ b/src/lib/Server/Output/ValueObjectVisitor/CreatedURLAlias.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/CreatedURLWildcard.php b/src/lib/Server/Output/ValueObjectVisitor/CreatedURLWildcard.php index 15e57296..b3679a3c 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/CreatedURLWildcard.php +++ b/src/lib/Server/Output/ValueObjectVisitor/CreatedURLWildcard.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/CreatedUser.php b/src/lib/Server/Output/ValueObjectVisitor/CreatedUser.php index ebf7984f..47c95252 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/CreatedUser.php +++ b/src/lib/Server/Output/ValueObjectVisitor/CreatedUser.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/CreatedUserGroup.php b/src/lib/Server/Output/ValueObjectVisitor/CreatedUserGroup.php index fe978871..5189ae12 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/CreatedUserGroup.php +++ b/src/lib/Server/Output/ValueObjectVisitor/CreatedUserGroup.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/CreatedVersion.php b/src/lib/Server/Output/ValueObjectVisitor/CreatedVersion.php index a5f8596f..673a25cd 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/CreatedVersion.php +++ b/src/lib/Server/Output/ValueObjectVisitor/CreatedVersion.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/DeletedUserSession.php b/src/lib/Server/Output/ValueObjectVisitor/DeletedUserSession.php index ff65bac9..94ea8b78 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/DeletedUserSession.php +++ b/src/lib/Server/Output/ValueObjectVisitor/DeletedUserSession.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/Exception.php b/src/lib/Server/Output/ValueObjectVisitor/Exception.php index 129abe7b..0d750bbb 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/Exception.php +++ b/src/lib/Server/Output/ValueObjectVisitor/Exception.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/FieldDefinitionList.php b/src/lib/Server/Output/ValueObjectVisitor/FieldDefinitionList.php index c2e670bc..4afb280a 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/FieldDefinitionList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/FieldDefinitionList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/ForbiddenException.php b/src/lib/Server/Output/ValueObjectVisitor/ForbiddenException.php index bba20032..03eee931 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/ForbiddenException.php +++ b/src/lib/Server/Output/ValueObjectVisitor/ForbiddenException.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; /** diff --git a/src/lib/Server/Output/ValueObjectVisitor/HttpException.php b/src/lib/Server/Output/ValueObjectVisitor/HttpException.php index b5f0e809..94e7ce36 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/HttpException.php +++ b/src/lib/Server/Output/ValueObjectVisitor/HttpException.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/ImageVariation.php b/src/lib/Server/Output/ValueObjectVisitor/ImageVariation.php index f521d6ce..69d5dc5a 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/ImageVariation.php +++ b/src/lib/Server/Output/ValueObjectVisitor/ImageVariation.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Variation\Values\ImageVariation as ImageVariationValue; diff --git a/src/lib/Server/Output/ValueObjectVisitor/InvalidArgumentException.php b/src/lib/Server/Output/ValueObjectVisitor/InvalidArgumentException.php index 4cf19821..42c0b747 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/InvalidArgumentException.php +++ b/src/lib/Server/Output/ValueObjectVisitor/InvalidArgumentException.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; /** diff --git a/src/lib/Server/Output/ValueObjectVisitor/Location.php b/src/lib/Server/Output/ValueObjectVisitor/Location.php index b70e6df7..e06c7fd4 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/Location.php +++ b/src/lib/Server/Output/ValueObjectVisitor/Location.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\ContentService; diff --git a/src/lib/Server/Output/ValueObjectVisitor/LocationList.php b/src/lib/Server/Output/ValueObjectVisitor/LocationList.php index 280ea079..e70b247d 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/LocationList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/LocationList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/NoContent.php b/src/lib/Server/Output/ValueObjectVisitor/NoContent.php index d81b064b..0be4faa0 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/NoContent.php +++ b/src/lib/Server/Output/ValueObjectVisitor/NoContent.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/NotFoundException.php b/src/lib/Server/Output/ValueObjectVisitor/NotFoundException.php index 8f2b47bb..614aec5e 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/NotFoundException.php +++ b/src/lib/Server/Output/ValueObjectVisitor/NotFoundException.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; /** diff --git a/src/lib/Server/Output/ValueObjectVisitor/NotImplementedException.php b/src/lib/Server/Output/ValueObjectVisitor/NotImplementedException.php index f5fe491a..69478f8e 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/NotImplementedException.php +++ b/src/lib/Server/Output/ValueObjectVisitor/NotImplementedException.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; /** diff --git a/src/lib/Server/Output/ValueObjectVisitor/OK.php b/src/lib/Server/Output/ValueObjectVisitor/OK.php index 988b0787..9ae81dba 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/OK.php +++ b/src/lib/Server/Output/ValueObjectVisitor/OK.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/ObjectStateGroup.php b/src/lib/Server/Output/ValueObjectVisitor/ObjectStateGroup.php index 7af33dc8..9a007f07 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/ObjectStateGroup.php +++ b/src/lib/Server/Output/ValueObjectVisitor/ObjectStateGroup.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\ObjectState\ObjectStateGroup as ObjectStateGroupValue; diff --git a/src/lib/Server/Output/ValueObjectVisitor/ObjectStateGroupList.php b/src/lib/Server/Output/ValueObjectVisitor/ObjectStateGroupList.php index f07a1f59..d40c13be 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/ObjectStateGroupList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/ObjectStateGroupList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/ObjectStateList.php b/src/lib/Server/Output/ValueObjectVisitor/ObjectStateList.php index 3c04da74..e1baddaf 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/ObjectStateList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/ObjectStateList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/Options.php b/src/lib/Server/Output/ValueObjectVisitor/Options.php index 895579ed..0745c706 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/Options.php +++ b/src/lib/Server/Output/ValueObjectVisitor/Options.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/PermanentRedirect.php b/src/lib/Server/Output/ValueObjectVisitor/PermanentRedirect.php index ff5a568f..2cd1dded 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/PermanentRedirect.php +++ b/src/lib/Server/Output/ValueObjectVisitor/PermanentRedirect.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/Policy.php b/src/lib/Server/Output/ValueObjectVisitor/Policy.php index 9bc6bf2e..5074f93e 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/Policy.php +++ b/src/lib/Server/Output/ValueObjectVisitor/Policy.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\User\Policy as PolicyValue; diff --git a/src/lib/Server/Output/ValueObjectVisitor/PolicyList.php b/src/lib/Server/Output/ValueObjectVisitor/PolicyList.php index 1d5e793e..5d443f65 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/PolicyList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/PolicyList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/PublishedRole.php b/src/lib/Server/Output/ValueObjectVisitor/PublishedRole.php index 27b57b56..e90af9f9 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/PublishedRole.php +++ b/src/lib/Server/Output/ValueObjectVisitor/PublishedRole.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/RelationList.php b/src/lib/Server/Output/ValueObjectVisitor/RelationList.php index 54aa880e..5c8c1e73 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/RelationList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/RelationList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/ResourceCreated.php b/src/lib/Server/Output/ValueObjectVisitor/ResourceCreated.php index d9e806a0..53b69e14 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/ResourceCreated.php +++ b/src/lib/Server/Output/ValueObjectVisitor/ResourceCreated.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/RestContent.php b/src/lib/Server/Output/ValueObjectVisitor/RestContent.php index 283042c1..ba75a3cb 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/RestContent.php +++ b/src/lib/Server/Output/ValueObjectVisitor/RestContent.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; diff --git a/src/lib/Server/Output/ValueObjectVisitor/RestContentType.php b/src/lib/Server/Output/ValueObjectVisitor/RestContentType.php index baed9bf7..1be7e733 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/RestContentType.php +++ b/src/lib/Server/Output/ValueObjectVisitor/RestContentType.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\ContentType\ContentType as APIContentType; diff --git a/src/lib/Server/Output/ValueObjectVisitor/RestContentTypeBase.php b/src/lib/Server/Output/ValueObjectVisitor/RestContentTypeBase.php index c43d7261..2b595bfe 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/RestContentTypeBase.php +++ b/src/lib/Server/Output/ValueObjectVisitor/RestContentTypeBase.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\ValueObjectVisitor; diff --git a/src/lib/Server/Output/ValueObjectVisitor/RestExecutedView.php b/src/lib/Server/Output/ValueObjectVisitor/RestExecutedView.php index 12d86427..c9d0aae1 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/RestExecutedView.php +++ b/src/lib/Server/Output/ValueObjectVisitor/RestExecutedView.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\ContentService; diff --git a/src/lib/Server/Output/ValueObjectVisitor/RestFieldDefinition.php b/src/lib/Server/Output/ValueObjectVisitor/RestFieldDefinition.php index 451f019b..ef44cb02 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/RestFieldDefinition.php +++ b/src/lib/Server/Output/ValueObjectVisitor/RestFieldDefinition.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\ContentType\ContentType as APIContentType; diff --git a/src/lib/Server/Output/ValueObjectVisitor/RestLocation.php b/src/lib/Server/Output/ValueObjectVisitor/RestLocation.php index 91145f40..a1107159 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/RestLocation.php +++ b/src/lib/Server/Output/ValueObjectVisitor/RestLocation.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/RestObjectState.php b/src/lib/Server/Output/ValueObjectVisitor/RestObjectState.php index 6d0f7765..dbbd2087 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/RestObjectState.php +++ b/src/lib/Server/Output/ValueObjectVisitor/RestObjectState.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/RestRelation.php b/src/lib/Server/Output/ValueObjectVisitor/RestRelation.php index 499d63eb..8e2c7544 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/RestRelation.php +++ b/src/lib/Server/Output/ValueObjectVisitor/RestRelation.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content\Relation as RelationValue; diff --git a/src/lib/Server/Output/ValueObjectVisitor/RestTrashItem.php b/src/lib/Server/Output/ValueObjectVisitor/RestTrashItem.php index a7ee5451..c1357612 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/RestTrashItem.php +++ b/src/lib/Server/Output/ValueObjectVisitor/RestTrashItem.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/RestUser.php b/src/lib/Server/Output/ValueObjectVisitor/RestUser.php index 965b576e..510f2f9b 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/RestUser.php +++ b/src/lib/Server/Output/ValueObjectVisitor/RestUser.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/RestUserGroup.php b/src/lib/Server/Output/ValueObjectVisitor/RestUserGroup.php index 44990991..d1992789 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/RestUserGroup.php +++ b/src/lib/Server/Output/ValueObjectVisitor/RestUserGroup.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/RestUserGroupRoleAssignment.php b/src/lib/Server/Output/ValueObjectVisitor/RestUserGroupRoleAssignment.php index 88db5abb..49602fc3 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/RestUserGroupRoleAssignment.php +++ b/src/lib/Server/Output/ValueObjectVisitor/RestUserGroupRoleAssignment.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\RoleLimitation; diff --git a/src/lib/Server/Output/ValueObjectVisitor/RestUserRoleAssignment.php b/src/lib/Server/Output/ValueObjectVisitor/RestUserRoleAssignment.php index f6829dea..73fc9931 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/RestUserRoleAssignment.php +++ b/src/lib/Server/Output/ValueObjectVisitor/RestUserRoleAssignment.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\RoleLimitation; diff --git a/src/lib/Server/Output/ValueObjectVisitor/Role.php b/src/lib/Server/Output/ValueObjectVisitor/Role.php index 2316656b..40a46f5e 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/Role.php +++ b/src/lib/Server/Output/ValueObjectVisitor/Role.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\User\RoleDraft; diff --git a/src/lib/Server/Output/ValueObjectVisitor/RoleAssignmentList.php b/src/lib/Server/Output/ValueObjectVisitor/RoleAssignmentList.php index a531ebce..8699f424 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/RoleAssignmentList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/RoleAssignmentList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/RoleList.php b/src/lib/Server/Output/ValueObjectVisitor/RoleList.php index fbf36493..7e798d2a 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/RoleList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/RoleList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/Root.php b/src/lib/Server/Output/ValueObjectVisitor/Root.php index ca61011c..06f1237c 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/Root.php +++ b/src/lib/Server/Output/ValueObjectVisitor/Root.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/Section.php b/src/lib/Server/Output/ValueObjectVisitor/Section.php index 71f40500..8f2a7a53 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/Section.php +++ b/src/lib/Server/Output/ValueObjectVisitor/Section.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content\Section as SectionValue; diff --git a/src/lib/Server/Output/ValueObjectVisitor/SectionList.php b/src/lib/Server/Output/ValueObjectVisitor/SectionList.php index 540a60ae..acdd8c31 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/SectionList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/SectionList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/SeeOther.php b/src/lib/Server/Output/ValueObjectVisitor/SeeOther.php index 28183926..7ca413d3 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/SeeOther.php +++ b/src/lib/Server/Output/ValueObjectVisitor/SeeOther.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/TemporaryRedirect.php b/src/lib/Server/Output/ValueObjectVisitor/TemporaryRedirect.php index 21e0a485..83db8db3 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/TemporaryRedirect.php +++ b/src/lib/Server/Output/ValueObjectVisitor/TemporaryRedirect.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/Trash.php b/src/lib/Server/Output/ValueObjectVisitor/Trash.php index 90c86a0a..8a1dde86 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/Trash.php +++ b/src/lib/Server/Output/ValueObjectVisitor/Trash.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/URLAlias.php b/src/lib/Server/Output/ValueObjectVisitor/URLAlias.php index a1fcd6ad..394d91eb 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/URLAlias.php +++ b/src/lib/Server/Output/ValueObjectVisitor/URLAlias.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values; diff --git a/src/lib/Server/Output/ValueObjectVisitor/URLAliasList.php b/src/lib/Server/Output/ValueObjectVisitor/URLAliasList.php index 1ddd6854..e9dbc613 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/URLAliasList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/URLAliasList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/URLAliasRefList.php b/src/lib/Server/Output/ValueObjectVisitor/URLAliasRefList.php index e9005428..cf05f595 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/URLAliasRefList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/URLAliasRefList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/URLWildcard.php b/src/lib/Server/Output/ValueObjectVisitor/URLWildcard.php index d7baf6cd..16a6ee8d 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/URLWildcard.php +++ b/src/lib/Server/Output/ValueObjectVisitor/URLWildcard.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content\URLWildcard as URLWildcardValue; diff --git a/src/lib/Server/Output/ValueObjectVisitor/URLWildcardList.php b/src/lib/Server/Output/ValueObjectVisitor/URLWildcardList.php index 672b30ba..73e8c059 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/URLWildcardList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/URLWildcardList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/UnauthorizedException.php b/src/lib/Server/Output/ValueObjectVisitor/UnauthorizedException.php index 3cd3e492..1a6075bf 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/UnauthorizedException.php +++ b/src/lib/Server/Output/ValueObjectVisitor/UnauthorizedException.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; /** diff --git a/src/lib/Server/Output/ValueObjectVisitor/UserGroupList.php b/src/lib/Server/Output/ValueObjectVisitor/UserGroupList.php index 04527e09..74b498d2 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/UserGroupList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/UserGroupList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/UserGroupRefList.php b/src/lib/Server/Output/ValueObjectVisitor/UserGroupRefList.php index d25de615..74242f34 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/UserGroupRefList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/UserGroupRefList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/UserList.php b/src/lib/Server/Output/ValueObjectVisitor/UserList.php index ecd26e99..8799fdc0 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/UserList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/UserList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/UserRefList.php b/src/lib/Server/Output/ValueObjectVisitor/UserRefList.php index 3ef599a6..86cd1701 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/UserRefList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/UserRefList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/UserSession.php b/src/lib/Server/Output/ValueObjectVisitor/UserSession.php index e2e0222e..1d2b81a8 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/UserSession.php +++ b/src/lib/Server/Output/ValueObjectVisitor/UserSession.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/Version.php b/src/lib/Server/Output/ValueObjectVisitor/Version.php index d3a138b5..b6550472 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/Version.php +++ b/src/lib/Server/Output/ValueObjectVisitor/Version.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content\Thumbnail; diff --git a/src/lib/Server/Output/ValueObjectVisitor/VersionInfo.php b/src/lib/Server/Output/ValueObjectVisitor/VersionInfo.php index 9bb8df13..de51bb41 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/VersionInfo.php +++ b/src/lib/Server/Output/ValueObjectVisitor/VersionInfo.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo as VersionInfoValue; diff --git a/src/lib/Server/Output/ValueObjectVisitor/VersionList.php b/src/lib/Server/Output/ValueObjectVisitor/VersionList.php index 8cafc8d5..16ab3e96 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/VersionList.php +++ b/src/lib/Server/Output/ValueObjectVisitor/VersionList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Output/ValueObjectVisitor/VersionTranslationInfo.php b/src/lib/Server/Output/ValueObjectVisitor/VersionTranslationInfo.php index 0100aab8..25c8d548 100644 --- a/src/lib/Server/Output/ValueObjectVisitor/VersionTranslationInfo.php +++ b/src/lib/Server/Output/ValueObjectVisitor/VersionTranslationInfo.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Output\Generator; diff --git a/src/lib/Server/Security/CsrfTokenManager.php b/src/lib/Server/Security/CsrfTokenManager.php index 8fe54e07..f7bdd08c 100644 --- a/src/lib/Server/Security/CsrfTokenManager.php +++ b/src/lib/Server/Security/CsrfTokenManager.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Security; use Symfony\Component\HttpFoundation\RequestStack; diff --git a/src/lib/Server/Security/RestAuthenticator.php b/src/lib/Server/Security/RestAuthenticator.php index 83baed21..58f367d7 100644 --- a/src/lib/Server/Security/RestAuthenticator.php +++ b/src/lib/Server/Security/RestAuthenticator.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Security; use Ibexa\Contracts\Core\SiteAccess\ConfigResolverInterface; @@ -181,6 +182,7 @@ private function isUserConflict(IbexaUser $user, TokenInterface $previousToken = } $wasAnonymous = $previousUser->getAPIUser()->getUserId() == $this->configResolver->getParameter('anonymous_user_id'); + // TODO: isEqualTo is not on the interface return !$wasAnonymous && !$user->isEqualTo($previousUser); } diff --git a/src/lib/Server/Security/RestLogoutHandler.php b/src/lib/Server/Security/RestLogoutHandler.php index 808c1ae3..be2432c8 100644 --- a/src/lib/Server/Security/RestLogoutHandler.php +++ b/src/lib/Server/Security/RestLogoutHandler.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Security; use Ibexa\Contracts\Core\SiteAccess\ConfigResolverInterface; diff --git a/src/lib/Server/Service/RootResourceBuilderInterface.php b/src/lib/Server/Service/RootResourceBuilderInterface.php index 78e3a252..c09ee652 100644 --- a/src/lib/Server/Service/RootResourceBuilderInterface.php +++ b/src/lib/Server/Service/RootResourceBuilderInterface.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Service; interface RootResourceBuilderInterface diff --git a/src/lib/Server/Values/CachedValue.php b/src/lib/Server/Values/CachedValue.php index 83acf95a..2bc3021f 100644 --- a/src/lib/Server/Values/CachedValue.php +++ b/src/lib/Server/Values/CachedValue.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Core\Base\Exceptions\InvalidArgumentException; @@ -29,6 +30,7 @@ class CachedValue extends RestValue /** * @param mixed $value The value that gets cached * @param array $cacheTags Tags to add to the cache (supported: locationId) + * * @throw InvalidArgumentException If invalid cache tags are provided */ public function __construct($value, array $cacheTags = []) diff --git a/src/lib/Server/Values/Conflict.php b/src/lib/Server/Values/Conflict.php index 3a52f556..9b01b0af 100644 --- a/src/lib/Server/Values/Conflict.php +++ b/src/lib/Server/Values/Conflict.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/ContentList.php b/src/lib/Server/Values/ContentList.php index 0ad72688..8c2cf762 100644 --- a/src/lib/Server/Values/ContentList.php +++ b/src/lib/Server/Values/ContentList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/ContentTypeGroupList.php b/src/lib/Server/Values/ContentTypeGroupList.php index eab23c1f..d816a3da 100644 --- a/src/lib/Server/Values/ContentTypeGroupList.php +++ b/src/lib/Server/Values/ContentTypeGroupList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/ContentTypeGroupRefList.php b/src/lib/Server/Values/ContentTypeGroupRefList.php index 1aaef28e..72561174 100644 --- a/src/lib/Server/Values/ContentTypeGroupRefList.php +++ b/src/lib/Server/Values/ContentTypeGroupRefList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ContentType\ContentType; diff --git a/src/lib/Server/Values/ContentTypeInfoList.php b/src/lib/Server/Values/ContentTypeInfoList.php index 3e03ccbf..9aed303e 100644 --- a/src/lib/Server/Values/ContentTypeInfoList.php +++ b/src/lib/Server/Values/ContentTypeInfoList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/ContentTypeList.php b/src/lib/Server/Values/ContentTypeList.php index d13e37e5..143595a3 100644 --- a/src/lib/Server/Values/ContentTypeList.php +++ b/src/lib/Server/Values/ContentTypeList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/CountryList.php b/src/lib/Server/Values/CountryList.php index 759d6ed4..8a184bf7 100644 --- a/src/lib/Server/Values/CountryList.php +++ b/src/lib/Server/Values/CountryList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/CreatedContent.php b/src/lib/Server/Values/CreatedContent.php index d08aee0e..6bc5f2ab 100644 --- a/src/lib/Server/Values/CreatedContent.php +++ b/src/lib/Server/Values/CreatedContent.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ValueObject; diff --git a/src/lib/Server/Values/CreatedContentType.php b/src/lib/Server/Values/CreatedContentType.php index 2372d984..3ce20baf 100644 --- a/src/lib/Server/Values/CreatedContentType.php +++ b/src/lib/Server/Values/CreatedContentType.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ValueObject; diff --git a/src/lib/Server/Values/CreatedContentTypeGroup.php b/src/lib/Server/Values/CreatedContentTypeGroup.php index 2b968dc0..87a67f0f 100644 --- a/src/lib/Server/Values/CreatedContentTypeGroup.php +++ b/src/lib/Server/Values/CreatedContentTypeGroup.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ValueObject; diff --git a/src/lib/Server/Values/CreatedFieldDefinition.php b/src/lib/Server/Values/CreatedFieldDefinition.php index a0c1572a..922a36f3 100644 --- a/src/lib/Server/Values/CreatedFieldDefinition.php +++ b/src/lib/Server/Values/CreatedFieldDefinition.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ValueObject; diff --git a/src/lib/Server/Values/CreatedLocation.php b/src/lib/Server/Values/CreatedLocation.php index dd259119..04815d18 100644 --- a/src/lib/Server/Values/CreatedLocation.php +++ b/src/lib/Server/Values/CreatedLocation.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ValueObject; diff --git a/src/lib/Server/Values/CreatedObjectState.php b/src/lib/Server/Values/CreatedObjectState.php index 87d1db09..e357fda0 100644 --- a/src/lib/Server/Values/CreatedObjectState.php +++ b/src/lib/Server/Values/CreatedObjectState.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ValueObject; diff --git a/src/lib/Server/Values/CreatedObjectStateGroup.php b/src/lib/Server/Values/CreatedObjectStateGroup.php index 803140fe..914d3149 100644 --- a/src/lib/Server/Values/CreatedObjectStateGroup.php +++ b/src/lib/Server/Values/CreatedObjectStateGroup.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ValueObject; diff --git a/src/lib/Server/Values/CreatedPolicy.php b/src/lib/Server/Values/CreatedPolicy.php index 50d885e1..e3fe2ee2 100644 --- a/src/lib/Server/Values/CreatedPolicy.php +++ b/src/lib/Server/Values/CreatedPolicy.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ValueObject; diff --git a/src/lib/Server/Values/CreatedRelation.php b/src/lib/Server/Values/CreatedRelation.php index 3319ad1a..2bf12f6f 100644 --- a/src/lib/Server/Values/CreatedRelation.php +++ b/src/lib/Server/Values/CreatedRelation.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ValueObject; diff --git a/src/lib/Server/Values/CreatedRole.php b/src/lib/Server/Values/CreatedRole.php index dddc9f0f..3a0a61e8 100644 --- a/src/lib/Server/Values/CreatedRole.php +++ b/src/lib/Server/Values/CreatedRole.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ValueObject; diff --git a/src/lib/Server/Values/CreatedSection.php b/src/lib/Server/Values/CreatedSection.php index 1e4b081c..cd3ea275 100644 --- a/src/lib/Server/Values/CreatedSection.php +++ b/src/lib/Server/Values/CreatedSection.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ValueObject; diff --git a/src/lib/Server/Values/CreatedURLAlias.php b/src/lib/Server/Values/CreatedURLAlias.php index 604df5ea..27955172 100644 --- a/src/lib/Server/Values/CreatedURLAlias.php +++ b/src/lib/Server/Values/CreatedURLAlias.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ValueObject; diff --git a/src/lib/Server/Values/CreatedURLWildcard.php b/src/lib/Server/Values/CreatedURLWildcard.php index 7832fa7a..c6929e13 100644 --- a/src/lib/Server/Values/CreatedURLWildcard.php +++ b/src/lib/Server/Values/CreatedURLWildcard.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ValueObject; diff --git a/src/lib/Server/Values/CreatedUser.php b/src/lib/Server/Values/CreatedUser.php index f0359263..4aac859d 100644 --- a/src/lib/Server/Values/CreatedUser.php +++ b/src/lib/Server/Values/CreatedUser.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ValueObject; diff --git a/src/lib/Server/Values/CreatedUserGroup.php b/src/lib/Server/Values/CreatedUserGroup.php index 66536039..f5daf724 100644 --- a/src/lib/Server/Values/CreatedUserGroup.php +++ b/src/lib/Server/Values/CreatedUserGroup.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ValueObject; diff --git a/src/lib/Server/Values/CreatedVersion.php b/src/lib/Server/Values/CreatedVersion.php index ca1fd50f..2780e121 100644 --- a/src/lib/Server/Values/CreatedVersion.php +++ b/src/lib/Server/Values/CreatedVersion.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ValueObject; diff --git a/src/lib/Server/Values/DeletedUserSession.php b/src/lib/Server/Values/DeletedUserSession.php index 5cb34f18..cba0d961 100644 --- a/src/lib/Server/Values/DeletedUserSession.php +++ b/src/lib/Server/Values/DeletedUserSession.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/FieldDefinitionList.php b/src/lib/Server/Values/FieldDefinitionList.php index dd46a224..bd878544 100644 --- a/src/lib/Server/Values/FieldDefinitionList.php +++ b/src/lib/Server/Values/FieldDefinitionList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ContentType\ContentType; diff --git a/src/lib/Server/Values/LocationList.php b/src/lib/Server/Values/LocationList.php index 5dafcccd..52d0c802 100644 --- a/src/lib/Server/Values/LocationList.php +++ b/src/lib/Server/Values/LocationList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/NoContent.php b/src/lib/Server/Values/NoContent.php index d3aa4e19..38a138c2 100644 --- a/src/lib/Server/Values/NoContent.php +++ b/src/lib/Server/Values/NoContent.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/OK.php b/src/lib/Server/Values/OK.php index 51798e4e..a08ba219 100644 --- a/src/lib/Server/Values/OK.php +++ b/src/lib/Server/Values/OK.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; /** diff --git a/src/lib/Server/Values/ObjectStateGroupList.php b/src/lib/Server/Values/ObjectStateGroupList.php index 0d4f54eb..5ee643e0 100644 --- a/src/lib/Server/Values/ObjectStateGroupList.php +++ b/src/lib/Server/Values/ObjectStateGroupList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/ObjectStateList.php b/src/lib/Server/Values/ObjectStateList.php index 93c1816e..113d2305 100644 --- a/src/lib/Server/Values/ObjectStateList.php +++ b/src/lib/Server/Values/ObjectStateList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/Options.php b/src/lib/Server/Values/Options.php index 92aa9025..8a03eab9 100644 --- a/src/lib/Server/Values/Options.php +++ b/src/lib/Server/Values/Options.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ValueObject; diff --git a/src/lib/Server/Values/PermanentRedirect.php b/src/lib/Server/Values/PermanentRedirect.php index 7e0dce3a..cebf8a2a 100644 --- a/src/lib/Server/Values/PermanentRedirect.php +++ b/src/lib/Server/Values/PermanentRedirect.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/PolicyList.php b/src/lib/Server/Values/PolicyList.php index a436993b..0e999407 100644 --- a/src/lib/Server/Values/PolicyList.php +++ b/src/lib/Server/Values/PolicyList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/PublishedRole.php b/src/lib/Server/Values/PublishedRole.php index acf38eed..72e659a6 100644 --- a/src/lib/Server/Values/PublishedRole.php +++ b/src/lib/Server/Values/PublishedRole.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ValueObject; diff --git a/src/lib/Server/Values/RelationList.php b/src/lib/Server/Values/RelationList.php index 4562becb..d3df984d 100644 --- a/src/lib/Server/Values/RelationList.php +++ b/src/lib/Server/Values/RelationList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/ResourceCreated.php b/src/lib/Server/Values/ResourceCreated.php index 685141e4..3cffd1b1 100644 --- a/src/lib/Server/Values/ResourceCreated.php +++ b/src/lib/Server/Values/ResourceCreated.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/RestContent.php b/src/lib/Server/Values/RestContent.php index f258d1a0..80e5c823 100644 --- a/src/lib/Server/Values/RestContent.php +++ b/src/lib/Server/Values/RestContent.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\Content\Content; diff --git a/src/lib/Server/Values/RestContentCreateStruct.php b/src/lib/Server/Values/RestContentCreateStruct.php index 26385908..f698c40f 100644 --- a/src/lib/Server/Values/RestContentCreateStruct.php +++ b/src/lib/Server/Values/RestContentCreateStruct.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\Content\ContentCreateStruct; diff --git a/src/lib/Server/Values/RestContentType.php b/src/lib/Server/Values/RestContentType.php index 5a101de7..d9e6ef03 100644 --- a/src/lib/Server/Values/RestContentType.php +++ b/src/lib/Server/Values/RestContentType.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ContentType\ContentType; diff --git a/src/lib/Server/Values/RestExecutedView.php b/src/lib/Server/Values/RestExecutedView.php index 4c6fbe28..23fbd17d 100644 --- a/src/lib/Server/Values/RestExecutedView.php +++ b/src/lib/Server/Values/RestExecutedView.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ValueObject; diff --git a/src/lib/Server/Values/RestFieldDefinition.php b/src/lib/Server/Values/RestFieldDefinition.php index e98bd802..765085a4 100644 --- a/src/lib/Server/Values/RestFieldDefinition.php +++ b/src/lib/Server/Values/RestFieldDefinition.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ContentType\ContentType; diff --git a/src/lib/Server/Values/RestLocation.php b/src/lib/Server/Values/RestLocation.php index a3955afd..c8ef8622 100644 --- a/src/lib/Server/Values/RestLocation.php +++ b/src/lib/Server/Values/RestLocation.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\Content\Location; diff --git a/src/lib/Server/Values/RestLocationUpdateStruct.php b/src/lib/Server/Values/RestLocationUpdateStruct.php index 1a85127c..b189a029 100644 --- a/src/lib/Server/Values/RestLocationUpdateStruct.php +++ b/src/lib/Server/Values/RestLocationUpdateStruct.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\Content\LocationUpdateStruct; diff --git a/src/lib/Server/Values/RestRelation.php b/src/lib/Server/Values/RestRelation.php index a9879eeb..c0607dd5 100644 --- a/src/lib/Server/Values/RestRelation.php +++ b/src/lib/Server/Values/RestRelation.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\Content\Relation; diff --git a/src/lib/Server/Values/RestRole.php b/src/lib/Server/Values/RestRole.php index 88862b9c..d29b7ec6 100644 --- a/src/lib/Server/Values/RestRole.php +++ b/src/lib/Server/Values/RestRole.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\User\Role; diff --git a/src/lib/Server/Values/RestTrashItem.php b/src/lib/Server/Values/RestTrashItem.php index 338c573d..fa5d46a6 100644 --- a/src/lib/Server/Values/RestTrashItem.php +++ b/src/lib/Server/Values/RestTrashItem.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\Content\TrashItem; diff --git a/src/lib/Server/Values/RestUser.php b/src/lib/Server/Values/RestUser.php index d70b94cb..e4fa92a5 100644 --- a/src/lib/Server/Values/RestUser.php +++ b/src/lib/Server/Values/RestUser.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\Content\Content; diff --git a/src/lib/Server/Values/RestUserGroup.php b/src/lib/Server/Values/RestUserGroup.php index d73d405f..783df5c0 100644 --- a/src/lib/Server/Values/RestUserGroup.php +++ b/src/lib/Server/Values/RestUserGroup.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\Content\Content; diff --git a/src/lib/Server/Values/RestUserGroupRoleAssignment.php b/src/lib/Server/Values/RestUserGroupRoleAssignment.php index 9d9da99b..b8462088 100644 --- a/src/lib/Server/Values/RestUserGroupRoleAssignment.php +++ b/src/lib/Server/Values/RestUserGroupRoleAssignment.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\User\UserGroupRoleAssignment; diff --git a/src/lib/Server/Values/RestUserGroupUpdateStruct.php b/src/lib/Server/Values/RestUserGroupUpdateStruct.php index 44f35cc0..6f5982be 100644 --- a/src/lib/Server/Values/RestUserGroupUpdateStruct.php +++ b/src/lib/Server/Values/RestUserGroupUpdateStruct.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\User\UserGroupUpdateStruct; diff --git a/src/lib/Server/Values/RestUserRoleAssignment.php b/src/lib/Server/Values/RestUserRoleAssignment.php index 0669d3cc..c36e9450 100644 --- a/src/lib/Server/Values/RestUserRoleAssignment.php +++ b/src/lib/Server/Values/RestUserRoleAssignment.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\User\UserRoleAssignment; diff --git a/src/lib/Server/Values/RestUserUpdateStruct.php b/src/lib/Server/Values/RestUserUpdateStruct.php index 743d1380..d6c6e023 100644 --- a/src/lib/Server/Values/RestUserUpdateStruct.php +++ b/src/lib/Server/Values/RestUserUpdateStruct.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\User\UserUpdateStruct; diff --git a/src/lib/Server/Values/RestViewInput.php b/src/lib/Server/Values/RestViewInput.php index 0a4b79c9..6dd36e1b 100644 --- a/src/lib/Server/Values/RestViewInput.php +++ b/src/lib/Server/Values/RestViewInput.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/RoleAssignment.php b/src/lib/Server/Values/RoleAssignment.php index 807e441d..d6bb58a0 100644 --- a/src/lib/Server/Values/RoleAssignment.php +++ b/src/lib/Server/Values/RoleAssignment.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\RoleLimitation; diff --git a/src/lib/Server/Values/RoleAssignmentList.php b/src/lib/Server/Values/RoleAssignmentList.php index 1b453cd2..8374e8e4 100644 --- a/src/lib/Server/Values/RoleAssignmentList.php +++ b/src/lib/Server/Values/RoleAssignmentList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/RoleList.php b/src/lib/Server/Values/RoleList.php index 4426fb77..4a462d54 100644 --- a/src/lib/Server/Values/RoleList.php +++ b/src/lib/Server/Values/RoleList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/SectionList.php b/src/lib/Server/Values/SectionList.php index 15409fad..57aeddfc 100644 --- a/src/lib/Server/Values/SectionList.php +++ b/src/lib/Server/Values/SectionList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/SeeOther.php b/src/lib/Server/Values/SeeOther.php index 60d844f0..6c2bb2b0 100644 --- a/src/lib/Server/Values/SeeOther.php +++ b/src/lib/Server/Values/SeeOther.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/SessionInput.php b/src/lib/Server/Values/SessionInput.php index 9e8f370b..3c44fa82 100644 --- a/src/lib/Server/Values/SessionInput.php +++ b/src/lib/Server/Values/SessionInput.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\ValueObject; diff --git a/src/lib/Server/Values/TemporaryRedirect.php b/src/lib/Server/Values/TemporaryRedirect.php index 71d4ae30..b473d398 100644 --- a/src/lib/Server/Values/TemporaryRedirect.php +++ b/src/lib/Server/Values/TemporaryRedirect.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/Trash.php b/src/lib/Server/Values/Trash.php index 282c89a4..1121fb82 100644 --- a/src/lib/Server/Values/Trash.php +++ b/src/lib/Server/Values/Trash.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/URLAliasList.php b/src/lib/Server/Values/URLAliasList.php index ebda18bd..944e9f7a 100644 --- a/src/lib/Server/Values/URLAliasList.php +++ b/src/lib/Server/Values/URLAliasList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/URLAliasRefList.php b/src/lib/Server/Values/URLAliasRefList.php index 7a98deea..eb852068 100644 --- a/src/lib/Server/Values/URLAliasRefList.php +++ b/src/lib/Server/Values/URLAliasRefList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/URLWildcardList.php b/src/lib/Server/Values/URLWildcardList.php index 09666657..e82b3db6 100644 --- a/src/lib/Server/Values/URLWildcardList.php +++ b/src/lib/Server/Values/URLWildcardList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/UserGroupList.php b/src/lib/Server/Values/UserGroupList.php index 69a04ea1..575b13ac 100644 --- a/src/lib/Server/Values/UserGroupList.php +++ b/src/lib/Server/Values/UserGroupList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/UserGroupRefList.php b/src/lib/Server/Values/UserGroupRefList.php index 051f153f..023157e3 100644 --- a/src/lib/Server/Values/UserGroupRefList.php +++ b/src/lib/Server/Values/UserGroupRefList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/UserList.php b/src/lib/Server/Values/UserList.php index ae03a7e7..c4b8a87e 100644 --- a/src/lib/Server/Values/UserList.php +++ b/src/lib/Server/Values/UserList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/UserRefList.php b/src/lib/Server/Values/UserRefList.php index d6896b89..d2d5cdfb 100644 --- a/src/lib/Server/Values/UserRefList.php +++ b/src/lib/Server/Values/UserRefList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/UserSession.php b/src/lib/Server/Values/UserSession.php index 063fe002..65a4c156 100644 --- a/src/lib/Server/Values/UserSession.php +++ b/src/lib/Server/Values/UserSession.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\User\User; diff --git a/src/lib/Server/Values/Version.php b/src/lib/Server/Values/Version.php index 96ca3e0d..7874d5f6 100644 --- a/src/lib/Server/Values/Version.php +++ b/src/lib/Server/Values/Version.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\Content\Content; diff --git a/src/lib/Server/Values/VersionList.php b/src/lib/Server/Values/VersionList.php index f9e483a4..e889a4fe 100644 --- a/src/lib/Server/Values/VersionList.php +++ b/src/lib/Server/Values/VersionList.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Server/Values/VersionTranslationInfo.php b/src/lib/Server/Values/VersionTranslationInfo.php index 8e4ada43..7099ce1d 100644 --- a/src/lib/Server/Values/VersionTranslationInfo.php +++ b/src/lib/Server/Values/VersionTranslationInfo.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\Values; use Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo; diff --git a/src/lib/Server/View/AcceptHeaderVisitorDispatcher.php b/src/lib/Server/View/AcceptHeaderVisitorDispatcher.php index 39a2caad..542f5f6a 100644 --- a/src/lib/Server/View/AcceptHeaderVisitorDispatcher.php +++ b/src/lib/Server/View/AcceptHeaderVisitorDispatcher.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Server\View; use Ibexa\Contracts\Rest\Output\Visitor as OutputVisitor; diff --git a/src/lib/Value.php b/src/lib/Value.php index 1850c282..895101a3 100644 --- a/src/lib/Value.php +++ b/src/lib/Value.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest; abstract class Value diff --git a/src/lib/Values/ContentObjectStates.php b/src/lib/Values/ContentObjectStates.php index e0cdae35..75f2badf 100644 --- a/src/lib/Values/ContentObjectStates.php +++ b/src/lib/Values/ContentObjectStates.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Values/Resource.php b/src/lib/Values/Resource.php index 586d5b9f..e3837b1c 100644 --- a/src/lib/Values/Resource.php +++ b/src/lib/Values/Resource.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Values; use Ibexa\Rest\Value as RestValue; diff --git a/src/lib/Values/RestContentMetadataUpdateStruct.php b/src/lib/Values/RestContentMetadataUpdateStruct.php index 661c2df7..9c8e27b4 100644 --- a/src/lib/Values/RestContentMetadataUpdateStruct.php +++ b/src/lib/Values/RestContentMetadataUpdateStruct.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Values; use Ibexa\Contracts\Core\Repository\Values\Content\ContentMetadataUpdateStruct; diff --git a/src/lib/Values/RestObjectState.php b/src/lib/Values/RestObjectState.php index 88fd3625..35ddf24b 100644 --- a/src/lib/Values/RestObjectState.php +++ b/src/lib/Values/RestObjectState.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Values; use Ibexa\Contracts\Core\Repository\Values\ObjectState\ObjectState; diff --git a/src/lib/Values/Root.php b/src/lib/Values/Root.php index 3a165d21..6b83c95f 100644 --- a/src/lib/Values/Root.php +++ b/src/lib/Values/Root.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Rest\Values; use Ibexa\Rest\Value as RestValue; diff --git a/tests/bundle/CorsOptions/RestProviderTest.php b/tests/bundle/CorsOptions/RestProviderTest.php index 7747a73c..c0d2d29f 100644 --- a/tests/bundle/CorsOptions/RestProviderTest.php +++ b/tests/bundle/CorsOptions/RestProviderTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\CorsOptions; use Exception; @@ -114,14 +115,14 @@ protected function getRequestMatcherMock() $mock = $this->createMock(RequestMatcherInterface::class); if ($this->matchRequestResult instanceof Exception) { - $mock->expects($this->any()) + $mock->expects(self::any()) ->method('matchRequest') - ->will($this->throwException($this->matchRequestResult)); + ->will(self::throwException($this->matchRequestResult)); } elseif ($this->matchRequestResult === false) { - $mock->expects($this->never()) + $mock->expects(self::never()) ->method('matchRequest'); } else { - $mock->expects($this->any()) + $mock->expects(self::any()) ->method('matchRequest') ->willReturn($this->matchRequestResult); } diff --git a/tests/bundle/DependencyInjection/Compiler/FieldTypeProcessorPassTest.php b/tests/bundle/DependencyInjection/Compiler/FieldTypeProcessorPassTest.php index 634b4b48..6f11ee67 100644 --- a/tests/bundle/DependencyInjection/Compiler/FieldTypeProcessorPassTest.php +++ b/tests/bundle/DependencyInjection/Compiler/FieldTypeProcessorPassTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\DependencyInjection\Compiler; use Ibexa\Bundle\Rest\DependencyInjection\Compiler\FieldTypeProcessorPass; diff --git a/tests/bundle/DependencyInjection/Compiler/InputHandlerPassTest.php b/tests/bundle/DependencyInjection/Compiler/InputHandlerPassTest.php index fe915bd6..e09a59b3 100644 --- a/tests/bundle/DependencyInjection/Compiler/InputHandlerPassTest.php +++ b/tests/bundle/DependencyInjection/Compiler/InputHandlerPassTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\DependencyInjection\Compiler; use Ibexa\Bundle\Rest\DependencyInjection\Compiler\InputHandlerPass; diff --git a/tests/bundle/DependencyInjection/Compiler/InputParserPassTest.php b/tests/bundle/DependencyInjection/Compiler/InputParserPassTest.php index 320323d9..fc1bac9a 100644 --- a/tests/bundle/DependencyInjection/Compiler/InputParserPassTest.php +++ b/tests/bundle/DependencyInjection/Compiler/InputParserPassTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\DependencyInjection\Compiler; use Ibexa\Bundle\Rest\DependencyInjection\Compiler\InputParserPass; diff --git a/tests/bundle/DependencyInjection/Compiler/OutputVisitorPassTest.php b/tests/bundle/DependencyInjection/Compiler/OutputVisitorPassTest.php index eb1db729..bd4e7ed7 100644 --- a/tests/bundle/DependencyInjection/Compiler/OutputVisitorPassTest.php +++ b/tests/bundle/DependencyInjection/Compiler/OutputVisitorPassTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\DependencyInjection\Compiler; use Ibexa\Bundle\Rest\DependencyInjection\Compiler\OutputVisitorPass; diff --git a/tests/bundle/DependencyInjection/Compiler/ValueObjectVisitorPassTest.php b/tests/bundle/DependencyInjection/Compiler/ValueObjectVisitorPassTest.php index df83473d..3d4f0496 100644 --- a/tests/bundle/DependencyInjection/Compiler/ValueObjectVisitorPassTest.php +++ b/tests/bundle/DependencyInjection/Compiler/ValueObjectVisitorPassTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\DependencyInjection\Compiler; use Ibexa\Bundle\Rest\DependencyInjection\Compiler\ValueObjectVisitorPass; diff --git a/tests/bundle/EventListener/CsrfListenerTest.php b/tests/bundle/EventListener/CsrfListenerTest.php index e83f323a..441165a0 100644 --- a/tests/bundle/EventListener/CsrfListenerTest.php +++ b/tests/bundle/EventListener/CsrfListenerTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\EventListener; use Ibexa\Bundle\Rest\EventListener\CsrfListener; @@ -94,6 +95,7 @@ public function testNoSessionStarted() * Tests that method CSRF check don't apply to are indeed ignored. * * @param string $ignoredMethod + * * @dataProvider getIgnoredRequestMethods */ public function testIgnoredRequestMethods($ignoredMethod) @@ -164,7 +166,7 @@ public function testInvalidToken() public function testValidToken() { $this->getEventDispatcherMock() - ->expects($this->once()) + ->expects(self::once()) ->method('dispatch'); $this->getEventListener()->onKernelRequest($this->getEvent()); @@ -176,7 +178,7 @@ public function testValidToken() protected function getCsrfProviderMock() { $provider = $this->createMock(CsrfTokenManagerInterface::class); - $provider->expects($this->any()) + $provider->expects(self::any()) ->method('isTokenValid') ->willReturnCallback( static function (CsrfToken $token) { @@ -200,7 +202,7 @@ protected function getEvent($class = null) parent::getEvent(RequestEvent::class); $this->event - ->expects($this->any()) + ->expects(self::any()) ->method('getRequestType') ->willReturn($this->requestType); } @@ -216,7 +218,7 @@ protected function getSessionMock() if (!isset($this->sessionMock)) { $this->sessionMock = $this->createMock(SessionInterface::class); $this->sessionMock - ->expects($this->atLeastOnce()) + ->expects(self::atLeastOnce()) ->method('isStarted') ->willReturn($this->sessionIsStarted); } @@ -234,21 +236,21 @@ protected function getRequestHeadersMock() if ($this->csrfTokenHeaderValue === null) { $this->requestHeadersMock - ->expects($this->never()) + ->expects(self::never()) ->method('has'); $this->requestHeadersMock - ->expects($this->never()) + ->expects(self::never()) ->method('get'); } else { $this->requestHeadersMock - ->expects($this->atLeastOnce()) + ->expects(self::atLeastOnce()) ->method('has') ->with(CsrfListener::CSRF_TOKEN_HEADER) ->willReturn(true); $this->requestHeadersMock - ->expects($this->atLeastOnce()) + ->expects(self::atLeastOnce()) ->method('get') ->with(CsrfListener::CSRF_TOKEN_HEADER) ->willReturn($this->csrfTokenHeaderValue); @@ -268,22 +270,22 @@ protected function getRequestMock() if ($this->sessionMock === false) { $this->requestMock - ->expects($this->never()) + ->expects(self::never()) ->method('getSession'); } else { $this->requestMock - ->expects($this->atLeastOnce()) + ->expects(self::atLeastOnce()) ->method('getSession') ->willReturn($this->getSessionMock()); } if ($this->route === false) { $this->requestMock - ->expects($this->never()) + ->expects(self::never()) ->method('get'); } else { $this->requestMock - ->expects($this->atLeastOnce()) + ->expects(self::atLeastOnce()) ->method('get') ->with('_route') ->willReturn($this->route); diff --git a/tests/bundle/EventListener/EventListenerTest.php b/tests/bundle/EventListener/EventListenerTest.php index c41cd34f..0fd34d9f 100644 --- a/tests/bundle/EventListener/EventListenerTest.php +++ b/tests/bundle/EventListener/EventListenerTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\EventListener; use PHPUnit\Framework\TestCase; @@ -66,7 +67,7 @@ protected function getEvent($class) ->getMock(); $this->event - ->expects($this->any()) + ->expects(self::any()) ->method('getRequest') ->willReturn($this->getRequestMock()); } @@ -82,7 +83,7 @@ protected function getRequestAttributesMock() if (!isset($this->requestAttributesMock)) { $this->requestAttributesMock = $this->createMock(ParameterBag::class); $this->requestAttributesMock - ->expects($this->once()) + ->expects(self::once()) ->method('get') ->with('is_rest_request') ->willReturn($this->isRestRequest); @@ -108,11 +109,11 @@ protected function getRequestMock() if ($this->requestMethod === false) { $this->requestMock - ->expects($this->never()) + ->expects(self::never()) ->method('getMethod'); } else { $this->requestMock - ->expects($this->atLeastOnce()) + ->expects(self::atLeastOnce()) ->method('getMethod') ->willReturn($this->requestMethod); } diff --git a/tests/bundle/EventListener/RequestListenerTest.php b/tests/bundle/EventListener/RequestListenerTest.php index 2b9ef6ba..4504920e 100644 --- a/tests/bundle/EventListener/RequestListenerTest.php +++ b/tests/bundle/EventListener/RequestListenerTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\EventListener; use Ibexa\Bundle\Rest\EventListener\RequestListener; diff --git a/tests/bundle/EventListener/ResponseListenerTest.php b/tests/bundle/EventListener/ResponseListenerTest.php index 19ccc74c..ad154fef 100644 --- a/tests/bundle/EventListener/ResponseListenerTest.php +++ b/tests/bundle/EventListener/ResponseListenerTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\EventListener; use Exception; @@ -78,7 +79,7 @@ public function testOnKernelExceptionViewIsNotRestRequest() protected function onKernelViewIsNotRestRequest($method, RequestEvent $event) { $this->getVisitorDispatcherMock() - ->expects($this->never()) + ->expects(self::never()) ->method('dispatch'); $this->getEventListener()->$method($event); @@ -97,7 +98,7 @@ public function testOnControllerResultView() protected function onKernelView($method, $event, $value) { $this->getVisitorDispatcherMock() - ->expects($this->once()) + ->expects(self::once()) ->method('dispatch') ->with( $this->getRequestMock(), @@ -108,7 +109,7 @@ protected function onKernelView($method, $event, $value) $this->getEventListener()->$method($event); - $this->assertEquals($this->response, $event->getResponse()); + self::assertEquals($this->response, $event->getResponse()); } /** diff --git a/tests/bundle/Functional/BinaryContentTest.php b/tests/bundle/Functional/BinaryContentTest.php index 1f38b97c..48b60522 100644 --- a/tests/bundle/Functional/BinaryContentTest.php +++ b/tests/bundle/Functional/BinaryContentTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\Functional; use Ibexa\Tests\Bundle\Rest\Functional\TestCase as RESTFunctionalTestCase; diff --git a/tests/bundle/Functional/ContentTest.php b/tests/bundle/Functional/ContentTest.php index ba0cc5e0..aa429daf 100644 --- a/tests/bundle/Functional/ContentTest.php +++ b/tests/bundle/Functional/ContentTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\Functional; use Ibexa\Tests\Bundle\Rest\Functional\TestCase as RESTFunctionalTestCase; @@ -155,6 +156,7 @@ public function testCreateDraftFromVersion(string $restContentHref) /** * @depends testPublishContent * Covers GET /content/objects//currentversion + * * @covers \Ibexa\Rest\Server\Controller\Content::redirectCurrentVersion * * @param string $restContentHref diff --git a/tests/bundle/Functional/ContentTypeTest.php b/tests/bundle/Functional/ContentTypeTest.php index cde77a0d..c541db15 100644 --- a/tests/bundle/Functional/ContentTypeTest.php +++ b/tests/bundle/Functional/ContentTypeTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\Functional; use Ibexa\Tests\Bundle\Rest\Functional\TestCase as RESTFunctionalTestCase; @@ -70,6 +71,7 @@ public function testUpdateContentTypeGroup($contentTypeGroupHref) /** * @depends testCreateContentTypeGroup + * * @returns string The created content type href * Covers POST /content/typegroups//types?publish=true * diff --git a/tests/bundle/Functional/LocationTest.php b/tests/bundle/Functional/LocationTest.php index d55f840e..44beb1eb 100644 --- a/tests/bundle/Functional/LocationTest.php +++ b/tests/bundle/Functional/LocationTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\Functional; use Ibexa\Tests\Bundle\Rest\Functional\TestCase as RESTFunctionalTestCase; diff --git a/tests/bundle/Functional/ObjectStateTest.php b/tests/bundle/Functional/ObjectStateTest.php index 6e751658..10226e27 100644 --- a/tests/bundle/Functional/ObjectStateTest.php +++ b/tests/bundle/Functional/ObjectStateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\Functional; use Ibexa\Tests\Bundle\Rest\Functional\TestCase as RESTFunctionalTestCase; @@ -54,6 +55,7 @@ public function testCreateObjectStateGroup() * Covers POST /content/objectstategroups/{objectStateGroupId}/objectstates. * * @return string Object state href + * * @depends testCreateObjectStateGroup */ public function testCreateObjectState($objectStateGroupHref) diff --git a/tests/bundle/Functional/RelationTest.php b/tests/bundle/Functional/RelationTest.php index f14f5224..d3fa0e73 100644 --- a/tests/bundle/Functional/RelationTest.php +++ b/tests/bundle/Functional/RelationTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\Functional; use Ibexa\Tests\Bundle\Rest\Functional\TestCase as RESTFunctionalTestCase; diff --git a/tests/bundle/Functional/RoleTest.php b/tests/bundle/Functional/RoleTest.php index 3aea1db8..d4f97a17 100644 --- a/tests/bundle/Functional/RoleTest.php +++ b/tests/bundle/Functional/RoleTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\Functional; use Ibexa\Tests\Bundle\Rest\Functional\TestCase as RESTFunctionalTestCase; @@ -436,6 +437,7 @@ public function testAssignRoleToUser($roleHref) * @param array $limitation * * @return string assigned role href + * * @dataProvider provideLimitations */ public function testAssignRoleToUserWithLimitation(array $limitation) diff --git a/tests/bundle/Functional/RootTest.php b/tests/bundle/Functional/RootTest.php index 69a14b54..38e121bd 100644 --- a/tests/bundle/Functional/RootTest.php +++ b/tests/bundle/Functional/RootTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\Functional; use Ibexa\Tests\Bundle\Rest\Functional\TestCase as RESTFunctionalTestCase; diff --git a/tests/bundle/Functional/SectionTest.php b/tests/bundle/Functional/SectionTest.php index 0fca6bb2..c8282ded 100644 --- a/tests/bundle/Functional/SectionTest.php +++ b/tests/bundle/Functional/SectionTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\Functional; use Ibexa\Tests\Bundle\Rest\Functional\TestCase as RESTFunctionalTestCase; @@ -55,6 +56,7 @@ public function testCreateSection() /** * @param $sectionHref + * * @depends testCreateSection * Covers PATCH /content/sections/{sectionId} */ diff --git a/tests/bundle/Functional/SessionTest.php b/tests/bundle/Functional/SessionTest.php index 2b9fbda3..4d8190a0 100644 --- a/tests/bundle/Functional/SessionTest.php +++ b/tests/bundle/Functional/SessionTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\Functional; use DOMDocument; diff --git a/tests/bundle/Functional/SortClauseTest.php b/tests/bundle/Functional/SortClauseTest.php index b928720c..c304b4a2 100644 --- a/tests/bundle/Functional/SortClauseTest.php +++ b/tests/bundle/Functional/SortClauseTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\Functional; use Ibexa\Tests\Bundle\Rest\Functional\TestCase as RESTFunctionalTestCase; diff --git a/tests/bundle/Functional/TestCase.php b/tests/bundle/Functional/TestCase.php index 2c36a61d..3d3aa206 100644 --- a/tests/bundle/Functional/TestCase.php +++ b/tests/bundle/Functional/TestCase.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\Functional; use Nyholm\Psr7\Request as HttpRequest; diff --git a/tests/bundle/Functional/TrashTest.php b/tests/bundle/Functional/TrashTest.php index 703b61bb..3211beab 100644 --- a/tests/bundle/Functional/TrashTest.php +++ b/tests/bundle/Functional/TrashTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\Functional; use Ibexa\Tests\Bundle\Rest\Functional\TestCase as RESTFunctionalTestCase; diff --git a/tests/bundle/Functional/UrlAliasTest.php b/tests/bundle/Functional/UrlAliasTest.php index ab98e127..36f32859 100644 --- a/tests/bundle/Functional/UrlAliasTest.php +++ b/tests/bundle/Functional/UrlAliasTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\Functional; use Ibexa\Tests\Bundle\Rest\Functional\TestCase as RESTFunctionalTestCase; @@ -38,6 +39,7 @@ public function testListGlobalURLAliases() /** * @depends testCreateFolder * Covers POST /content/urlaliases + * * @returns string The created url alias href */ public function testCreateUrlAlias($locationHref) diff --git a/tests/bundle/Functional/UrlWildcardTest.php b/tests/bundle/Functional/UrlWildcardTest.php index 4d4cf6a9..79802ff7 100644 --- a/tests/bundle/Functional/UrlWildcardTest.php +++ b/tests/bundle/Functional/UrlWildcardTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\Functional; use Ibexa\Tests\Bundle\Rest\Functional\TestCase as RESTFunctionalTestCase; @@ -58,6 +59,7 @@ public function testCreateUrlWildcard() /** * @param $urlWildcardHref Covers GET /content/urlwildcards/{urlWildcardId} + * * @depends testCreateUrlWildcard */ public function testLoadUrlWildcard($urlWildcardHref) @@ -71,6 +73,7 @@ public function testLoadUrlWildcard($urlWildcardHref) /** * @param $urlWildcardHref + * * @depends testCreateUrlWildcard */ public function testDeleteURLWildcard($urlWildcardHref) diff --git a/tests/bundle/Functional/UserTest.php b/tests/bundle/Functional/UserTest.php index aaac0ece..72c57b8f 100644 --- a/tests/bundle/Functional/UserTest.php +++ b/tests/bundle/Functional/UserTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\Functional; use Ibexa\Tests\Bundle\Rest\Functional\TestCase as RESTFunctionalTestCase; @@ -71,6 +72,7 @@ public function testCreateUserGroup() /** * @param $userGroupId Covers GET /user/groups/{groupId} + * * @depends testCreateUserGroup */ public function testLoadUserGroup($groupId) @@ -165,6 +167,7 @@ public function testCreateUser($userGroupHref) /** * @param $userId Covers GET /user/users/{userId} + * * @depends testCreateUser */ public function testLoadUser($userHref) diff --git a/tests/bundle/Functional/ViewTest.php b/tests/bundle/Functional/ViewTest.php index 0477dcac..0caa13da 100644 --- a/tests/bundle/Functional/ViewTest.php +++ b/tests/bundle/Functional/ViewTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\Functional; class ViewTest extends TestCase diff --git a/tests/bundle/RequestParser/RouterTest.php b/tests/bundle/RequestParser/RouterTest.php index 367c7734..d177e2bc 100644 --- a/tests/bundle/RequestParser/RouterTest.php +++ b/tests/bundle/RequestParser/RouterTest.php @@ -116,7 +116,7 @@ public function testGenerate(): void $expectedResult = self::$routePrefix . '/generate/' . $arguments['arg1']; $this->getRouterMock() - ->expects($this->once()) + ->expects(self::once()) ->method('generate') ->with($routeName, $arguments) ->willReturn($expectedResult) diff --git a/tests/bundle/Routing/OptionsLoader/MapperTest.php b/tests/bundle/Routing/OptionsLoader/MapperTest.php index 1e158acf..f4e41f96 100644 --- a/tests/bundle/Routing/OptionsLoader/MapperTest.php +++ b/tests/bundle/Routing/OptionsLoader/MapperTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\Routing\OptionsLoader; use Ibexa\Bundle\Rest\Routing\OptionsLoader\Mapper; diff --git a/tests/bundle/Routing/OptionsLoader/RouteCollectionMapperTest.php b/tests/bundle/Routing/OptionsLoader/RouteCollectionMapperTest.php index cacb1c28..71f306db 100644 --- a/tests/bundle/Routing/OptionsLoader/RouteCollectionMapperTest.php +++ b/tests/bundle/Routing/OptionsLoader/RouteCollectionMapperTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\Routing\OptionsLoader; use Ibexa\Bundle\Rest\Routing\OptionsLoader\Mapper; diff --git a/tests/bundle/Routing/OptionsLoaderTest.php b/tests/bundle/Routing/OptionsLoaderTest.php index e64949c1..01f7b3df 100644 --- a/tests/bundle/Routing/OptionsLoaderTest.php +++ b/tests/bundle/Routing/OptionsLoaderTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Bundle\Rest\Routing; use Ibexa\Bundle\Rest\Routing\OptionsLoader; @@ -18,6 +19,7 @@ class OptionsLoaderTest extends TestCase /** * @param string $type * @param bool $expected + * * @dataProvider getResourceType */ public function testSupportsResourceType($type, $expected) @@ -40,7 +42,7 @@ public function testLoad() { $optionsRouteCollection = new RouteCollection(); - $this->getRouteCollectionMapperMock()->expects($this->once()) + $this->getRouteCollectionMapperMock()->expects(self::once()) ->method('mapCollection') ->with(new RouteCollection()) ->willReturn($optionsRouteCollection); @@ -63,9 +65,9 @@ protected function getOptionsLoader() ->setMethods(['import']) ->getMock(); - $mock->expects($this->any()) + $mock->expects(self::any()) ->method('import') - ->with($this->anything(), $this->anything()) + ->with(self::anything(), self::anything()) ->willReturn(new RouteCollection()); return $mock; diff --git a/tests/lib/AssertXmlTagTrait.php b/tests/lib/AssertXmlTagTrait.php index fc9d26e2..84fb7da8 100644 --- a/tests/lib/AssertXmlTagTrait.php +++ b/tests/lib/AssertXmlTagTrait.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest; use DOMDocument; diff --git a/tests/lib/FieldTypeProcessor/AuthorProcessorTest.php b/tests/lib/FieldTypeProcessor/AuthorProcessorTest.php index 3a5016a7..7b6f67dc 100644 --- a/tests/lib/FieldTypeProcessor/AuthorProcessorTest.php +++ b/tests/lib/FieldTypeProcessor/AuthorProcessorTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\FieldTypeProcessor; use Ibexa\Rest\FieldTypeProcessor\AuthorProcessor; @@ -31,13 +32,14 @@ static function ($constantName) { /** * @covers \Ibexa\Rest\FieldTypeProcessor\AuthorProcessor::preProcessFieldSettingsHash + * * @dataProvider fieldSettingsHashes */ public function testPreProcessFieldSettingsHash($inputSettings, $outputSettings) { $processor = $this->getProcessor(); - $this->assertEquals( + self::assertEquals( $outputSettings, $processor->preProcessFieldSettingsHash($inputSettings) ); @@ -45,13 +47,14 @@ public function testPreProcessFieldSettingsHash($inputSettings, $outputSettings) /** * @covers \Ibexa\Rest\FieldTypeProcessor\AuthorProcessor::postProcessFieldSettingsHash + * * @dataProvider fieldSettingsHashes */ public function testPostProcessFieldSettingsHash($outputSettings, $inputSettings) { $processor = $this->getProcessor(); - $this->assertEquals( + self::assertEquals( $outputSettings, $processor->postProcessFieldSettingsHash($inputSettings) ); diff --git a/tests/lib/FieldTypeProcessor/BinaryInputProcessorTest.php b/tests/lib/FieldTypeProcessor/BinaryInputProcessorTest.php index 6c634aeb..ab68f2f0 100644 --- a/tests/lib/FieldTypeProcessor/BinaryInputProcessorTest.php +++ b/tests/lib/FieldTypeProcessor/BinaryInputProcessorTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\FieldTypeProcessor; use PHPUnit\Framework\TestCase; @@ -59,7 +60,7 @@ public function testPreProcessValueHashMissingKey() $outputHash = $processor->preProcessValueHash($inputHash); - $this->assertEquals($inputHash, $outputHash); + self::assertEquals($inputHash, $outputHash); } /** @@ -75,12 +76,12 @@ public function testPreProcessValueHash() $outputHash = $processor->preProcessValueHash($inputHash); - $this->assertFalse(isset($outputHash['data']), 'Data found in input hash'); - $this->assertTrue(isset($outputHash['inputUri']), 'No path found in output hash'); + self::assertFalse(isset($outputHash['data']), 'Data found in input hash'); + self::assertTrue(isset($outputHash['inputUri']), 'No path found in output hash'); - $this->assertFileExists($outputHash['inputUri'], "The output path {$outputHash['inputUri']} does not exist"); + self::assertFileExists($outputHash['inputUri'], "The output path {$outputHash['inputUri']} does not exist"); - $this->assertEquals($fileContent, file_get_contents($outputHash['inputUri'])); + self::assertEquals($fileContent, file_get_contents($outputHash['inputUri'])); } /** diff --git a/tests/lib/FieldTypeProcessor/BinaryProcessorTest.php b/tests/lib/FieldTypeProcessor/BinaryProcessorTest.php index 3a90ac4a..8f9c4d04 100644 --- a/tests/lib/FieldTypeProcessor/BinaryProcessorTest.php +++ b/tests/lib/FieldTypeProcessor/BinaryProcessorTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\FieldTypeProcessor; use Ibexa\Rest\FieldTypeProcessor\BinaryProcessor; @@ -27,7 +28,7 @@ public function testPostProcessValueHash() $outputHash = $processor->postProcessValueHash($inputHash); $expectedUri = 'http://static.example.com' . $uri; - $this->assertEquals( + self::assertEquals( [ 'url' => $expectedUri, 'uri' => $expectedUri, diff --git a/tests/lib/FieldTypeProcessor/DateAndTimeProcessorTest.php b/tests/lib/FieldTypeProcessor/DateAndTimeProcessorTest.php index 06279576..da2ea831 100644 --- a/tests/lib/FieldTypeProcessor/DateAndTimeProcessorTest.php +++ b/tests/lib/FieldTypeProcessor/DateAndTimeProcessorTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\FieldTypeProcessor; use Ibexa\Rest\FieldTypeProcessor\DateAndTimeProcessor; @@ -32,13 +33,14 @@ static function ($constantName) { /** * @covers \Ibexa\Rest\FieldTypeProcessor\DateAndTimeProcessor::preProcessFieldSettingsHash + * * @dataProvider fieldSettingsHashes */ public function testPreProcessFieldSettingsHash($inputSettings, $outputSettings) { $processor = $this->getProcessor(); - $this->assertEquals( + self::assertEquals( $outputSettings, $processor->preProcessFieldSettingsHash($inputSettings) ); @@ -46,13 +48,14 @@ public function testPreProcessFieldSettingsHash($inputSettings, $outputSettings) /** * @covers \Ibexa\Rest\FieldTypeProcessor\DateAndTimeProcessor::postProcessFieldSettingsHash + * * @dataProvider fieldSettingsHashes */ public function testPostProcessFieldSettingsHash($outputSettings, $inputSettings) { $processor = $this->getProcessor(); - $this->assertEquals( + self::assertEquals( $outputSettings, $processor->postProcessFieldSettingsHash($inputSettings) ); diff --git a/tests/lib/FieldTypeProcessor/DateProcessorTest.php b/tests/lib/FieldTypeProcessor/DateProcessorTest.php index a410a2c6..da809a6b 100644 --- a/tests/lib/FieldTypeProcessor/DateProcessorTest.php +++ b/tests/lib/FieldTypeProcessor/DateProcessorTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\FieldTypeProcessor; use Ibexa\Rest\FieldTypeProcessor\DateProcessor; @@ -31,13 +32,14 @@ static function ($constantName) { /** * @covers \Ibexa\Rest\FieldTypeProcessor\DateProcessor::preProcessFieldSettingsHash + * * @dataProvider fieldSettingsHashes */ public function testPreProcessFieldSettingsHash($inputSettings, $outputSettings) { $processor = $this->getProcessor(); - $this->assertEquals( + self::assertEquals( $outputSettings, $processor->preProcessFieldSettingsHash($inputSettings) ); @@ -45,13 +47,14 @@ public function testPreProcessFieldSettingsHash($inputSettings, $outputSettings) /** * @covers \Ibexa\Rest\FieldTypeProcessor\DateProcessor::postProcessFieldSettingsHash + * * @dataProvider fieldSettingsHashes */ public function testPostProcessFieldSettingsHash($outputSettings, $inputSettings) { $processor = $this->getProcessor(); - $this->assertEquals( + self::assertEquals( $outputSettings, $processor->postProcessFieldSettingsHash($inputSettings) ); diff --git a/tests/lib/FieldTypeProcessor/ImageProcessorTest.php b/tests/lib/FieldTypeProcessor/ImageProcessorTest.php index aa618bb0..57aa3a9a 100644 --- a/tests/lib/FieldTypeProcessor/ImageProcessorTest.php +++ b/tests/lib/FieldTypeProcessor/ImageProcessorTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\FieldTypeProcessor; use Ibexa\Rest\FieldTypeProcessor\ImageProcessor; @@ -30,7 +31,7 @@ public function testPostProcessValueHash() foreach ($this->getVariations() as $iteration => $variationIdentifier) { $expectedVariations[$variationIdentifier]['href'] = "/content/binary/images/{$inputHash['imageId']}/variations/{$variationIdentifier}"; $routerMock - ->expects($this->at($iteration)) + ->expects(self::at($iteration)) ->method('generate') ->with( 'ibexa.rest.binary_content.get_image_variation', @@ -43,7 +44,7 @@ public function testPostProcessValueHash() $outputHash = $processor->postProcessValueHash($inputHash); - $this->assertEquals( + self::assertEquals( [ 'path' => '/var/some_site/223-1-eng-US/Cool-File.jpg', 'imageId' => '223-12345', diff --git a/tests/lib/FieldTypeProcessor/MediaProcessorTest.php b/tests/lib/FieldTypeProcessor/MediaProcessorTest.php index 35d4f857..a540b165 100644 --- a/tests/lib/FieldTypeProcessor/MediaProcessorTest.php +++ b/tests/lib/FieldTypeProcessor/MediaProcessorTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\FieldTypeProcessor; use Ibexa\Rest\FieldTypeProcessor\MediaProcessor; @@ -35,13 +36,14 @@ static function ($constantName) { /** * @covers \Ibexa\Rest\FieldTypeProcessor\MediaProcessor::preProcessFieldSettingsHash + * * @dataProvider fieldSettingsHashes */ public function testPreProcessFieldSettingsHash($inputSettings, $outputSettings) { $processor = $this->getProcessor(); - $this->assertEquals( + self::assertEquals( $outputSettings, $processor->preProcessFieldSettingsHash($inputSettings) ); @@ -49,13 +51,14 @@ public function testPreProcessFieldSettingsHash($inputSettings, $outputSettings) /** * @covers \Ibexa\Rest\FieldTypeProcessor\MediaProcessor::postProcessFieldSettingsHash + * * @dataProvider fieldSettingsHashes */ public function testPostProcessFieldSettingsHash($outputSettings, $inputSettings) { $processor = $this->getProcessor(); - $this->assertEquals( + self::assertEquals( $outputSettings, $processor->postProcessFieldSettingsHash($inputSettings) ); diff --git a/tests/lib/FieldTypeProcessor/RelationListProcessorTest.php b/tests/lib/FieldTypeProcessor/RelationListProcessorTest.php index ac3443a3..face5d52 100644 --- a/tests/lib/FieldTypeProcessor/RelationListProcessorTest.php +++ b/tests/lib/FieldTypeProcessor/RelationListProcessorTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\FieldTypeProcessor; use Ibexa\Contracts\Core\Repository\LocationService; @@ -34,13 +35,14 @@ static function ($constantName) { /** * @covers \Ibexa\Rest\FieldTypeProcessor\RelationListProcessor::preProcessFieldSettingsHash + * * @dataProvider fieldSettingsHashes */ public function testPreProcessFieldSettingsHash($inputSettings, $outputSettings) { $processor = $this->getProcessor(); - $this->assertEquals( + self::assertEquals( $outputSettings, $processor->preProcessFieldSettingsHash($inputSettings) ); @@ -48,13 +50,14 @@ public function testPreProcessFieldSettingsHash($inputSettings, $outputSettings) /** * @covers \Ibexa\Rest\FieldTypeProcessor\RelationListProcessor::postProcessFieldSettingsHash + * * @dataProvider fieldSettingsHashes */ public function testPostProcessFieldSettingsHash($outputSettings, $inputSettings) { $processor = $this->getProcessor(); - $this->assertEquals( + self::assertEquals( $outputSettings, $processor->postProcessFieldSettingsHash($inputSettings) ); @@ -82,16 +85,16 @@ public function testpostProcessFieldSettingsHashLocation() $hash = $processor->postProcessFieldSettingsHash(['selectionDefaultLocation' => 42]); - $this->assertEquals([ + self::assertEquals([ 'selectionDefaultLocation' => 42, 'selectionDefaultLocationHref' => '/api/ibexa/v2/content/locations/1/25/42', ], $hash); //empty cases $hash = $processor->postProcessFieldSettingsHash(['selectionDefaultLocation' => '']); - $this->assertEquals(['selectionDefaultLocation' => ''], $hash); + self::assertEquals(['selectionDefaultLocation' => ''], $hash); $hash = $processor->postProcessFieldSettingsHash(['selectionDefaultLocation' => null]); - $this->assertEquals(['selectionDefaultLocation' => null], $hash); + self::assertEquals(['selectionDefaultLocation' => null], $hash); } public function testPostProcessValueHash() @@ -102,7 +105,7 @@ public function testPostProcessValueHash() $processor->setRouter($routerMock); $routerMock - ->expects($this->exactly(2)) + ->expects(self::exactly(2)) ->method('generate') ->withConsecutive( ['ibexa.rest.load_content', ['contentId' => 42]], @@ -113,9 +116,9 @@ public function testPostProcessValueHash() ); $hash = $processor->postProcessValueHash(['destinationContentIds' => [42, 300]]); - $this->assertArrayHasKey('destinationContentHrefs', $hash); - $this->assertEquals('/api/ibexa/v2/content/objects/42', $hash['destinationContentHrefs'][0]); - $this->assertEquals('/api/ibexa/v2/content/objects/300', $hash['destinationContentHrefs'][1]); + self::assertArrayHasKey('destinationContentHrefs', $hash); + self::assertEquals('/api/ibexa/v2/content/objects/42', $hash['destinationContentHrefs'][0]); + self::assertEquals('/api/ibexa/v2/content/objects/300', $hash['destinationContentHrefs'][1]); } /** diff --git a/tests/lib/FieldTypeProcessor/RelationProcessorTest.php b/tests/lib/FieldTypeProcessor/RelationProcessorTest.php index b06a2483..d190e2b7 100644 --- a/tests/lib/FieldTypeProcessor/RelationProcessorTest.php +++ b/tests/lib/FieldTypeProcessor/RelationProcessorTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\FieldTypeProcessor; use Ibexa\Contracts\Core\Repository\LocationService; @@ -35,13 +36,14 @@ static function ($constantName) { /** * @covers \Ibexa\Rest\FieldTypeProcessor\RelationProcessor::preProcessFieldSettingsHash + * * @dataProvider fieldSettingsHashes */ public function testPreProcessFieldSettingsHash($inputSettings, $outputSettings) { $processor = $this->getProcessor(); - $this->assertEquals( + self::assertEquals( $outputSettings, $processor->preProcessFieldSettingsHash($inputSettings) ); @@ -49,13 +51,14 @@ public function testPreProcessFieldSettingsHash($inputSettings, $outputSettings) /** * @covers \Ibexa\Rest\FieldTypeProcessor\RelationProcessor::postProcessFieldSettingsHash + * * @dataProvider fieldSettingsHashes */ public function testPostProcessFieldSettingsHash($outputSettings, $inputSettings) { $processor = $this->getProcessor(); - $this->assertEquals( + self::assertEquals( $outputSettings, $processor->postProcessFieldSettingsHash($inputSettings) ); @@ -83,16 +86,16 @@ public function testpostProcessFieldSettingsHashLocation() $hash = $processor->postProcessFieldSettingsHash(['selectionRoot' => 42]); - $this->assertEquals([ + self::assertEquals([ 'selectionRoot' => 42, 'selectionRootHref' => '/api/ibexa/v2/content/locations/1/25/42', ], $hash); //empty cases $hash = $processor->postProcessFieldSettingsHash(['selectionRoot' => '']); - $this->assertEquals(['selectionRoot' => ''], $hash); + self::assertEquals(['selectionRoot' => ''], $hash); $hash = $processor->postProcessFieldSettingsHash(['selectionRoot' => null]); - $this->assertEquals(['selectionRoot' => null], $hash); + self::assertEquals(['selectionRoot' => null], $hash); } public function testPostProcessFieldValueHash() @@ -103,14 +106,14 @@ public function testPostProcessFieldValueHash() $processor->setRouter($routerMock); $routerMock - ->expects($this->once()) + ->expects(self::once()) ->method('generate') ->with('ibexa.rest.load_content', ['contentId' => 42]) ->willReturn('/api/ibexa/v2/content/objects/42'); $hash = $processor->postProcessValueHash(['destinationContentId' => 42]); - $this->assertArrayHasKey('destinationContentHref', $hash); - $this->assertEquals('/api/ibexa/v2/content/objects/42', $hash['destinationContentHref']); + self::assertArrayHasKey('destinationContentHref', $hash); + self::assertEquals('/api/ibexa/v2/content/objects/42', $hash['destinationContentHref']); } public function testPostProcessFieldValueHashNullValue() @@ -121,11 +124,11 @@ public function testPostProcessFieldValueHashNullValue() $processor->setRouter($routerMock); $routerMock - ->expects($this->never()) + ->expects(self::never()) ->method('generate'); $hash = $processor->postProcessValueHash(['destinationContentId' => null]); - $this->assertArrayNotHasKey('destinationContentHref', $hash); + self::assertArrayNotHasKey('destinationContentHref', $hash); } public function testPostProcessFieldValueHashNotAccessibleLocation(): void diff --git a/tests/lib/FieldTypeProcessor/TimeProcessorTest.php b/tests/lib/FieldTypeProcessor/TimeProcessorTest.php index f2dae158..8a29e4a3 100644 --- a/tests/lib/FieldTypeProcessor/TimeProcessorTest.php +++ b/tests/lib/FieldTypeProcessor/TimeProcessorTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\FieldTypeProcessor; use Ibexa\Rest\FieldTypeProcessor\TimeProcessor; @@ -31,13 +32,14 @@ static function ($constantName) { /** * @covers \Ibexa\Rest\FieldTypeProcessor\TimeProcessor::preProcessFieldSettingsHash + * * @dataProvider fieldSettingsHashes */ public function testPreProcessFieldSettingsHash($inputSettings, $outputSettings) { $processor = $this->getProcessor(); - $this->assertEquals( + self::assertEquals( $outputSettings, $processor->preProcessFieldSettingsHash($inputSettings) ); @@ -45,13 +47,14 @@ public function testPreProcessFieldSettingsHash($inputSettings, $outputSettings) /** * @covers \Ibexa\Rest\FieldTypeProcessor\TimeProcessor::postProcessFieldSettingsHash + * * @dataProvider fieldSettingsHashes */ public function testPostProcessFieldSettingsHash($outputSettings, $inputSettings) { $processor = $this->getProcessor(); - $this->assertEquals( + self::assertEquals( $outputSettings, $processor->postProcessFieldSettingsHash($inputSettings) ); diff --git a/tests/lib/FieldTypeProcessorRegistryTest.php b/tests/lib/FieldTypeProcessorRegistryTest.php index 3ea13662..cfb94448 100644 --- a/tests/lib/FieldTypeProcessorRegistryTest.php +++ b/tests/lib/FieldTypeProcessorRegistryTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest; use Ibexa\Contracts\Rest\FieldTypeProcessor; @@ -21,7 +22,7 @@ public function testRegisterProcessor() $registry->registerProcessor('my-type', $processor); - $this->assertTrue($registry->hasProcessor('my-type')); + self::assertTrue($registry->hasProcessor('my-type')); } public function testRegisterMultipleProcessors() @@ -34,15 +35,15 @@ public function testRegisterMultipleProcessors() $registry->registerProcessor('my-type', $processorA); $registry->registerProcessor('your-type', $processorB); - $this->assertTrue($registry->hasProcessor('my-type')); - $this->assertTrue($registry->hasProcessor('your-type')); + self::assertTrue($registry->hasProcessor('my-type')); + self::assertTrue($registry->hasProcessor('your-type')); } public function testHasProcessorFailure() { $registry = new FieldTypeProcessorRegistry(); - $this->assertFalse($registry->hasProcessor('my-type')); + self::assertFalse($registry->hasProcessor('my-type')); } public function testGetProcessor() @@ -53,7 +54,7 @@ public function testGetProcessor() $registry->registerProcessor('my-type', $processor); - $this->assertSame( + self::assertSame( $processor, $registry->getProcessor('my-type') ); @@ -78,7 +79,7 @@ public function testRegisterProcessorsOverwrite() $registry->registerProcessor('my-type', $processorA); $registry->registerProcessor('my-type', $processorB); - $this->assertSame( + self::assertSame( $processorB, $registry->getProcessor('my-type') ); diff --git a/tests/lib/Input/DispatcherTest.php b/tests/lib/Input/DispatcherTest.php index 35829187..e041cbc9 100644 --- a/tests/lib/Input/DispatcherTest.php +++ b/tests/lib/Input/DispatcherTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Input; use Ibexa\Contracts\Rest\Exceptions\Parser; @@ -78,21 +79,21 @@ public function testParse() $parsingDispatcher = $this->getParsingDispatcherMock(); $parsingDispatcher - ->expects($this->at(0)) + ->expects(self::at(0)) ->method('parse') ->with([42], 'text/html') ->willReturn(23); $handler = $this->createMock(Handler::class); $handler - ->expects($this->at(0)) + ->expects(self::at(0)) ->method('convert') ->with('Hello world!') ->willReturn([[42]]); $dispatcher = new Dispatcher($parsingDispatcher, ['format' => $handler]); - $this->assertSame( + self::assertSame( 23, $dispatcher->parse($message) ); @@ -114,14 +115,14 @@ public function testParseSpecialUrlHeader() $parsingDispatcher = $this->getParsingDispatcherMock(); $parsingDispatcher - ->expects($this->at(0)) + ->expects(self::at(0)) ->method('parse') ->with(['someKey' => 'someValue', '__url' => '/foo/bar'], 'text/html') ->willReturn(23); $handler = $this->createMock(Handler::class); $handler - ->expects($this->at(0)) + ->expects(self::at(0)) ->method('convert') ->with('Hello world!') ->willReturn( @@ -134,7 +135,7 @@ public function testParseSpecialUrlHeader() $dispatcher = new Dispatcher($parsingDispatcher, ['format' => $handler]); - $this->assertSame( + self::assertSame( 23, $dispatcher->parse($message) ); @@ -152,13 +153,13 @@ public function testParseMediaTypeCharset() $parsingDispatcher = $this->getParsingDispatcherMock(); $parsingDispatcher - ->expects($this->any()) + ->expects(self::any()) ->method('parse') - ->with($this->anything(), 'text/html; version=1.1'); + ->with(self::anything(), 'text/html; version=1.1'); $handler = $this->createMock(Handler::class); $handler - ->expects($this->any()) + ->expects(self::any()) ->method('convert') ->willReturn([]); diff --git a/tests/lib/Input/FieldTypeParserTest.php b/tests/lib/Input/FieldTypeParserTest.php index d689cf05..8a64160b 100644 --- a/tests/lib/Input/FieldTypeParserTest.php +++ b/tests/lib/Input/FieldTypeParserTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Input; use Ibexa\Contracts\Core\Repository\ContentService; @@ -52,7 +53,7 @@ public function testParseFieldValue() { $fieldTypeParser = $this->getFieldTypeParser(); - $this->contentServiceMock->expects($this->once()) + $this->contentServiceMock->expects(self::once()) ->method('loadContentInfo') ->with('23') ->willReturn( @@ -60,7 +61,7 @@ public function testParseFieldValue() ); $contentTypeMock = $this->contentTypeMock; - $this->contentTypeServiceMock->expects($this->once()) + $this->contentTypeServiceMock->expects(self::once()) ->method('loadContentType') ->with('42') ->willReturnCallback( @@ -70,9 +71,9 @@ static function () use ($contentTypeMock) { } ); - $contentTypeMock->expects($this->once()) + $contentTypeMock->expects(self::once()) ->method('getFieldDefinition') - ->with($this->equalTo('my-field-definition')) + ->with(self::equalTo('my-field-definition')) ->willReturn( new FieldDefinition( [ @@ -81,15 +82,15 @@ static function () use ($contentTypeMock) { ) ); - $this->fieldTypeProcessorRegistryMock->expects($this->once()) + $this->fieldTypeProcessorRegistryMock->expects(self::once()) ->method('hasProcessor') - ->with($this->equalTo('some-fancy-field-type')) + ->with(self::equalTo('some-fancy-field-type')) ->willReturn(false); $fieldTypeMock = $this->fieldTypeMock; - $this->fieldTypeServiceMock->expects($this->once()) + $this->fieldTypeServiceMock->expects(self::once()) ->method('getFieldType') - ->with($this->equalTo('some-fancy-field-type')) + ->with(self::equalTo('some-fancy-field-type')) ->willReturnCallback( // Avoid PHPUnit cloning static function () use ($fieldTypeMock) { @@ -97,12 +98,12 @@ static function () use ($fieldTypeMock) { } ); - $fieldTypeMock->expects($this->once()) + $fieldTypeMock->expects(self::once()) ->method('fromHash') - ->with($this->equalTo([1, 2, 3])) + ->with(self::equalTo([1, 2, 3])) ->willReturn(['foo', 'bar']); - $this->assertEquals( + self::assertEquals( ['foo', 'bar'], $fieldTypeParser->parseFieldValue( '23', @@ -116,15 +117,15 @@ public function testParseValue() { $fieldTypeParser = $this->getFieldTypeParser(); - $this->fieldTypeProcessorRegistryMock->expects($this->once()) + $this->fieldTypeProcessorRegistryMock->expects(self::once()) ->method('hasProcessor') - ->with($this->equalTo('some-fancy-field-type')) + ->with(self::equalTo('some-fancy-field-type')) ->willReturn(false); $fieldTypeMock = $this->fieldTypeMock; - $this->fieldTypeServiceMock->expects($this->once()) + $this->fieldTypeServiceMock->expects(self::once()) ->method('getFieldType') - ->with($this->equalTo('some-fancy-field-type')) + ->with(self::equalTo('some-fancy-field-type')) ->willReturnCallback( // Avoid PHPUnit cloning static function () use ($fieldTypeMock) { @@ -132,12 +133,12 @@ static function () use ($fieldTypeMock) { } ); - $fieldTypeMock->expects($this->once()) + $fieldTypeMock->expects(self::once()) ->method('fromHash') - ->with($this->equalTo([1, 2, 3])) + ->with(self::equalTo([1, 2, 3])) ->willReturn(['foo', 'bar']); - $this->assertEquals( + self::assertEquals( ['foo', 'bar'], $fieldTypeParser->parseValue( 'some-fancy-field-type', @@ -150,30 +151,30 @@ public function testParseValueWithPreProcessing() { $fieldTypeParser = $this->getFieldTypeParser(); - $this->fieldTypeProcessorRegistryMock->expects($this->once()) + $this->fieldTypeProcessorRegistryMock->expects(self::once()) ->method('hasProcessor') - ->with($this->equalTo('some-fancy-field-type')) + ->with(self::equalTo('some-fancy-field-type')) ->willReturn(true); $processor = $this->fieldTypeProcessorMock; - $this->fieldTypeProcessorRegistryMock->expects($this->once()) + $this->fieldTypeProcessorRegistryMock->expects(self::once()) ->method('getProcessor') - ->with($this->equalTo('some-fancy-field-type')) + ->with(self::equalTo('some-fancy-field-type')) ->willReturnCallback( static function () use ($processor) { return $processor; } ); - $processor->expects($this->once()) + $processor->expects(self::once()) ->method('preProcessValueHash') ->with([1, 2, 3]) ->willReturn([4, 5, 6]); $fieldTypeMock = $this->fieldTypeMock; - $this->fieldTypeServiceMock->expects($this->once()) + $this->fieldTypeServiceMock->expects(self::once()) ->method('getFieldType') - ->with($this->equalTo('some-fancy-field-type')) + ->with(self::equalTo('some-fancy-field-type')) ->willReturnCallback( // Avoid PHPUnit cloning static function () use ($fieldTypeMock) { @@ -181,12 +182,12 @@ static function () use ($fieldTypeMock) { } ); - $fieldTypeMock->expects($this->once()) + $fieldTypeMock->expects(self::once()) ->method('fromHash') - ->with($this->equalTo([4, 5, 6])) + ->with(self::equalTo([4, 5, 6])) ->willReturn(['foo', 'bar']); - $this->assertEquals( + self::assertEquals( ['foo', 'bar'], $fieldTypeParser->parseValue( 'some-fancy-field-type', @@ -200,9 +201,9 @@ public function testParseFieldSettings() $fieldTypeParser = $this->getFieldTypeParser(); $fieldTypeMock = $this->fieldTypeMock; - $this->fieldTypeServiceMock->expects($this->once()) + $this->fieldTypeServiceMock->expects(self::once()) ->method('getFieldType') - ->with($this->equalTo('some-fancy-field-type')) + ->with(self::equalTo('some-fancy-field-type')) ->willReturnCallback( // Avoid PHPUnit cloning static function () use ($fieldTypeMock) { @@ -210,12 +211,12 @@ static function () use ($fieldTypeMock) { } ); - $fieldTypeMock->expects($this->once()) + $fieldTypeMock->expects(self::once()) ->method('fieldSettingsFromHash') - ->with($this->equalTo([1, 2, 3])) + ->with(self::equalTo([1, 2, 3])) ->willReturn(['foo', 'bar']); - $this->assertEquals( + self::assertEquals( ['foo', 'bar'], $fieldTypeParser->parseFieldSettings( 'some-fancy-field-type', @@ -228,30 +229,30 @@ public function testParseFieldSettingsWithPreProcessing() { $fieldTypeParser = $this->getFieldTypeParser(); - $this->fieldTypeProcessorRegistryMock->expects($this->once()) + $this->fieldTypeProcessorRegistryMock->expects(self::once()) ->method('hasProcessor') - ->with($this->equalTo('some-fancy-field-type')) + ->with(self::equalTo('some-fancy-field-type')) ->willReturn(true); $processor = $this->fieldTypeProcessorMock; - $this->fieldTypeProcessorRegistryMock->expects($this->once()) + $this->fieldTypeProcessorRegistryMock->expects(self::once()) ->method('getProcessor') - ->with($this->equalTo('some-fancy-field-type')) + ->with(self::equalTo('some-fancy-field-type')) ->willReturnCallback( static function () use ($processor) { return $processor; } ); - $processor->expects($this->once()) + $processor->expects(self::once()) ->method('preProcessFieldSettingsHash') ->with([1, 2, 3]) ->willReturn([4, 5, 6]); $fieldTypeMock = $this->fieldTypeMock; - $this->fieldTypeServiceMock->expects($this->once()) + $this->fieldTypeServiceMock->expects(self::once()) ->method('getFieldType') - ->with($this->equalTo('some-fancy-field-type')) + ->with(self::equalTo('some-fancy-field-type')) ->willReturnCallback( // Avoid PHPUnit cloning static function () use ($fieldTypeMock) { @@ -259,12 +260,12 @@ static function () use ($fieldTypeMock) { } ); - $fieldTypeMock->expects($this->once()) + $fieldTypeMock->expects(self::once()) ->method('fieldSettingsFromHash') - ->with($this->equalTo([4, 5, 6])) + ->with(self::equalTo([4, 5, 6])) ->willReturn(['foo', 'bar']); - $this->assertEquals( + self::assertEquals( ['foo', 'bar'], $fieldTypeParser->parseFieldSettings( 'some-fancy-field-type', @@ -278,9 +279,9 @@ public function testParseValidatorConfiguration() $fieldTypeParser = $this->getFieldTypeParser(); $fieldTypeMock = $this->fieldTypeMock; - $this->fieldTypeServiceMock->expects($this->once()) + $this->fieldTypeServiceMock->expects(self::once()) ->method('getFieldType') - ->with($this->equalTo('some-fancy-field-type')) + ->with(self::equalTo('some-fancy-field-type')) ->willReturnCallback( // Avoid PHPUnit cloning static function () use ($fieldTypeMock) { @@ -288,12 +289,12 @@ static function () use ($fieldTypeMock) { } ); - $fieldTypeMock->expects($this->once()) + $fieldTypeMock->expects(self::once()) ->method('validatorConfigurationFromHash') - ->with($this->equalTo([1, 2, 3])) + ->with(self::equalTo([1, 2, 3])) ->willReturn(['foo', 'bar']); - $this->assertEquals( + self::assertEquals( ['foo', 'bar'], $fieldTypeParser->parseValidatorConfiguration( 'some-fancy-field-type', @@ -306,30 +307,30 @@ public function testParseValidatorConfigurationWithPreProcessing() { $fieldTypeParser = $this->getFieldTypeParser(); - $this->fieldTypeProcessorRegistryMock->expects($this->once()) + $this->fieldTypeProcessorRegistryMock->expects(self::once()) ->method('hasProcessor') - ->with($this->equalTo('some-fancy-field-type')) + ->with(self::equalTo('some-fancy-field-type')) ->willReturn(true); $processor = $this->fieldTypeProcessorMock; - $this->fieldTypeProcessorRegistryMock->expects($this->once()) + $this->fieldTypeProcessorRegistryMock->expects(self::once()) ->method('getProcessor') - ->with($this->equalTo('some-fancy-field-type')) + ->with(self::equalTo('some-fancy-field-type')) ->willReturnCallback( static function () use ($processor) { return $processor; } ); - $processor->expects($this->once()) + $processor->expects(self::once()) ->method('preProcessValidatorConfigurationHash') ->with([1, 2, 3]) ->willReturn([4, 5, 6]); $fieldTypeMock = $this->fieldTypeMock; - $this->fieldTypeServiceMock->expects($this->once()) + $this->fieldTypeServiceMock->expects(self::once()) ->method('getFieldType') - ->with($this->equalTo('some-fancy-field-type')) + ->with(self::equalTo('some-fancy-field-type')) ->willReturnCallback( // Avoid PHPUnit cloning static function () use ($fieldTypeMock) { @@ -337,12 +338,12 @@ static function () use ($fieldTypeMock) { } ); - $fieldTypeMock->expects($this->once()) + $fieldTypeMock->expects(self::once()) ->method('validatorConfigurationFromHash') - ->with($this->equalTo([4, 5, 6])) + ->with(self::equalTo([4, 5, 6])) ->willReturn(['foo', 'bar']); - $this->assertEquals( + self::assertEquals( ['foo', 'bar'], $fieldTypeParser->parseValidatorConfiguration( 'some-fancy-field-type', diff --git a/tests/lib/Input/Handler/JsonTest.php b/tests/lib/Input/Handler/JsonTest.php index 6ca12abb..0f3b6128 100644 --- a/tests/lib/Input/Handler/JsonTest.php +++ b/tests/lib/Input/Handler/JsonTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Input\Handler; use Ibexa\Contracts\Rest\Exceptions\Parser; @@ -30,7 +31,7 @@ public function testConvertJson() { $handler = $this->getHandler(); - $this->assertSame( + self::assertSame( [ 'text' => 'Hello world!', ], @@ -42,7 +43,7 @@ public function testConvertFieldValue() { $handler = $this->getHandler(); - $this->assertSame( + self::assertSame( [ 'Field' => [ 'fieldValue' => [ diff --git a/tests/lib/Input/Handler/XmlTest.php b/tests/lib/Input/Handler/XmlTest.php index 1ccd3301..a363fca8 100644 --- a/tests/lib/Input/Handler/XmlTest.php +++ b/tests/lib/Input/Handler/XmlTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Input\Handler; use Ibexa\Contracts\Rest\Exceptions\Parser; @@ -21,7 +22,7 @@ public function testConvertInvalidXml() $handler = new Xml(); - $this->assertSame( + self::assertSame( [ 'text' => 'Hello world!', ], @@ -49,7 +50,7 @@ public function testConvertXml($xml, $expectation) { $handler = new Xml(); - $this->assertSame( + self::assertSame( $expectation, $handler->convert($xml) ); diff --git a/tests/lib/Input/ParserToolsTest.php b/tests/lib/Input/ParserToolsTest.php index f1bc51c3..0085a037 100644 --- a/tests/lib/Input/ParserToolsTest.php +++ b/tests/lib/Input/ParserToolsTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Input; use Ibexa\Contracts\Rest\Input\ParsingDispatcher; @@ -17,7 +18,7 @@ public function testIsEmbeddedObjectReturnsTrue() { $parserTools = $this->getParserTools(); - $this->assertTrue( + self::assertTrue( $parserTools->isEmbeddedObject( [ '_href' => '/foo/bar', @@ -32,7 +33,7 @@ public function testIsEmbeddedObjectReturnsFalse() { $parserTools = $this->getParserTools(); - $this->assertFalse( + self::assertFalse( $parserTools->isEmbeddedObject( [ '_href' => '/foo/bar', @@ -47,11 +48,11 @@ public function testParseObjectElementEmbedded() $parserTools = $this->getParserTools(); $dispatcherMock = $this->createMock(ParsingDispatcher::class); - $dispatcherMock->expects($this->once()) + $dispatcherMock->expects(self::once()) ->method('parse') ->with( - $this->isType('array'), - $this->equalTo('application/my-type') + self::isType('array'), + self::equalTo('application/my-type') ); $parsingInput = [ @@ -60,7 +61,7 @@ public function testParseObjectElementEmbedded() 'someContent' => [], ]; - $this->assertEquals( + self::assertEquals( '/foo/bar', $parserTools->parseObjectElement($parsingInput, $dispatcherMock) ); @@ -71,7 +72,7 @@ public function testParseObjectElementNotEmbedded() $parserTools = $this->getParserTools(); $dispatcherMock = $this->createMock(ParsingDispatcher::class); - $dispatcherMock->expects($this->never()) + $dispatcherMock->expects(self::never()) ->method('parse'); $parsingInput = [ @@ -80,7 +81,7 @@ public function testParseObjectElementNotEmbedded() '#someTextContent' => 'foo', ]; - $this->assertEquals( + self::assertEquals( '/foo/bar', $parserTools->parseObjectElement($parsingInput, $dispatcherMock) ); @@ -90,10 +91,10 @@ public function testNormalParseBooleanValue() { $tools = $this->getParserTools(); - $this->assertTrue($tools->parseBooleanValue('true')); - $this->assertTrue($tools->parseBooleanValue(true)); - $this->assertFalse($tools->parseBooleanValue('false')); - $this->assertFalse($tools->parseBooleanValue(false)); + self::assertTrue($tools->parseBooleanValue('true')); + self::assertTrue($tools->parseBooleanValue(true)); + self::assertFalse($tools->parseBooleanValue('false')); + self::assertFalse($tools->parseBooleanValue(false)); } public function testUnexpectedValueParseBooleanValue() diff --git a/tests/lib/Input/ParsingDispatcherTest.php b/tests/lib/Input/ParsingDispatcherTest.php index feee2425..ab9a38c6 100644 --- a/tests/lib/Input/ParsingDispatcherTest.php +++ b/tests/lib/Input/ParsingDispatcherTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Input; use Ibexa\Contracts\Rest\Input\Parser; @@ -31,12 +32,12 @@ public function testParse() $dispatcher = new ParsingDispatcher($this->createMock(EventDispatcherInterface::class), ['text/html' => $parser]); $parser - ->expects($this->at(0)) + ->expects(self::at(0)) ->method('parse') ->with([42], $dispatcher) ->willReturn(23); - $this->assertSame( + self::assertSame( 23, $dispatcher->parse([42], 'text/html') ); @@ -51,12 +52,12 @@ public function testParseCharset() $dispatcher = new ParsingDispatcher($this->createMock(EventDispatcherInterface::class), ['text/html' => $parser]); $parser - ->expects($this->at(0)) + ->expects(self::at(0)) ->method('parse') ->with([42], $dispatcher) ->willReturn(23); - $this->assertSame( + self::assertSame( 23, $dispatcher->parse([42], 'text/html; charset=UTF-8; version=1.0') ); @@ -74,8 +75,8 @@ public function testParseVersion() ] ); - $parserVersionOne->expects($this->never())->method('parse'); - $parserVersionTwo->expects($this->once())->method('parse'); + $parserVersionOne->expects(self::never())->method('parse'); + $parserVersionTwo->expects(self::once())->method('parse'); $dispatcher->parse([42], 'text/html; version=2'); } @@ -86,12 +87,12 @@ public function testParseStripFormat() $dispatcher = new ParsingDispatcher($this->createMock(EventDispatcherInterface::class), ['text/html' => $parser]); $parser - ->expects($this->at(0)) + ->expects(self::at(0)) ->method('parse') ->with([42], $dispatcher) ->willReturn(23); - $this->assertSame( + self::assertSame( 23, $dispatcher->parse([42], 'text/html+json') ); diff --git a/tests/lib/MessageTest.php b/tests/lib/MessageTest.php index ec5a5bc7..123d61d5 100644 --- a/tests/lib/MessageTest.php +++ b/tests/lib/MessageTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest; use Ibexa\Rest\Message; @@ -21,7 +22,7 @@ public function testCreateMessageDefaultHeaders() { $message = new Message(); - $this->assertSame([], $message->headers); + self::assertSame([], $message->headers); } /** @@ -31,7 +32,7 @@ public function testCreateMessageDefaultBody() { $message = new Message(); - $this->assertSame('', $message->body); + self::assertSame('', $message->body); } /** @@ -45,7 +46,7 @@ public function testCreateMessageConstructorHeaders() ] ); - $this->assertSame($headers, $message->headers); + self::assertSame($headers, $message->headers); } /** @@ -58,7 +59,7 @@ public function testCreateMessageConstructorBody() 'Hello world!' ); - $this->assertSame('Hello world!', $message->body); + self::assertSame('Hello world!', $message->body); } } diff --git a/tests/lib/Output/FieldTypeSerializerTest.php b/tests/lib/Output/FieldTypeSerializerTest.php index 3e7f9ce3..8224b5e0 100644 --- a/tests/lib/Output/FieldTypeSerializerTest.php +++ b/tests/lib/Output/FieldTypeSerializerTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Output; use Ibexa\Contracts\Core\Repository\FieldType as APIFieldType; @@ -112,18 +113,18 @@ public function testSerializeFieldValueWithProcessor(): void $processorMock = $this->getFieldTypeProcessorMock(); $this->getFieldTypeProcessorRegistryMock() - ->expects($this->once()) + ->expects(self::once()) ->method('hasProcessor') ->with('myFancyFieldType') ->willReturn(true); $this->getFieldTypeProcessorRegistryMock() - ->expects($this->once()) + ->expects(self::once()) ->method('getProcessor') ->with('myFancyFieldType') ->willReturn($processorMock); - $processorMock->expects($this->once()) + $processorMock->expects(self::once()) ->method('postProcessValueHash') - ->with($this->equalTo([23, 42])) + ->with(self::equalTo([23, 42])) ->willReturn(['post-processed']); $fieldTypeMock = $this->getFieldTypeMock(); @@ -133,12 +134,12 @@ public function testSerializeFieldValueWithProcessor(): void $fieldTypeMock ); - $fieldTypeMock->expects($this->once()) + $fieldTypeMock->expects(self::once()) ->method('getFieldTypeIdentifier') ->willReturn('myFancyFieldType'); - $fieldTypeMock->expects($this->once()) + $fieldTypeMock->expects(self::once()) ->method('toHash') - ->with($this->equalTo('my-field-value')) + ->with(self::equalTo('my-field-value')) ->willReturn([23, 42]); $serializer->serializeFieldValue( @@ -161,9 +162,9 @@ public function testSerializeFieldDefaultValue(): void $fieldTypeMock ); - $fieldTypeMock->expects($this->once()) + $fieldTypeMock->expects(self::once()) ->method('toHash') - ->with($this->equalTo('my-field-value')) + ->with(self::equalTo('my-field-value')) ->willReturn([23, 42]); $serializer->serializeFieldDefaultValue( @@ -186,9 +187,9 @@ public function testSerializeFieldSettings(): void $fieldTypeMock ); - $fieldTypeMock->expects($this->once()) + $fieldTypeMock->expects(self::once()) ->method('fieldSettingsToHash') - ->with($this->equalTo('my-field-settings')) + ->with(self::equalTo('my-field-settings')) ->willReturn(['foo' => 'bar']); $serializer->serializeFieldSettings( @@ -208,12 +209,12 @@ public function testSerializeFieldSettingsWithPostProcessing(): void $processorMock = $this->getFieldTypeProcessorMock(); $this->getFieldTypeProcessorRegistryMock() - ->expects($this->once()) + ->expects(self::once()) ->method('hasProcessor') ->with('myFancyFieldType') ->willReturn(true); $this->getFieldTypeProcessorRegistryMock() - ->expects($this->once()) + ->expects(self::once()) ->method('getProcessor') ->with('myFancyFieldType') ->willReturnCallback( @@ -221,9 +222,9 @@ static function () use ($processorMock) { return $processorMock; } ); - $processorMock->expects($this->once()) + $processorMock->expects(self::once()) ->method('postProcessFieldSettingsHash') - ->with($this->equalTo(['foo' => 'bar'])) + ->with(self::equalTo(['foo' => 'bar'])) ->willReturn(['post-processed']); $this->mockFieldTypeServiceGetFieldType( @@ -231,9 +232,9 @@ static function () use ($processorMock) { $fieldTypeMock ); - $fieldTypeMock->expects($this->once()) + $fieldTypeMock->expects(self::once()) ->method('fieldSettingsToHash') - ->with($this->equalTo('my-field-settings')) + ->with(self::equalTo('my-field-settings')) ->willReturn(['foo' => 'bar']); $serializer->serializeFieldSettings( @@ -256,9 +257,9 @@ public function testSerializeValidatorConfiguration(): void $fieldTypeMock ); - $fieldTypeMock->expects($this->once()) + $fieldTypeMock->expects(self::once()) ->method('validatorConfigurationToHash') - ->with($this->equalTo('validator-config')) + ->with(self::equalTo('validator-config')) ->willReturn(['bar' => 'foo']); $serializer->serializeValidatorConfiguration( @@ -278,12 +279,12 @@ public function testSerializeValidatorConfigurationWithPostProcessing(): void $processorMock = $this->getFieldTypeProcessorMock(); $this->getFieldTypeProcessorRegistryMock() - ->expects($this->once()) + ->expects(self::once()) ->method('hasProcessor') ->with('myFancyFieldType') ->willReturn(true); $this->getFieldTypeProcessorRegistryMock() - ->expects($this->once()) + ->expects(self::once()) ->method('getProcessor') ->with('myFancyFieldType') ->willReturnCallback( @@ -291,9 +292,9 @@ static function () use ($processorMock) { return $processorMock; } ); - $processorMock->expects($this->once()) + $processorMock->expects(self::once()) ->method('postProcessValidatorConfigurationHash') - ->with($this->equalTo(['bar' => 'foo'])) + ->with(self::equalTo(['bar' => 'foo'])) ->willReturn(['post-processed']); $fieldTypeMock = $this->getFieldTypeMock(); @@ -302,9 +303,9 @@ static function () use ($processorMock) { $fieldTypeMock ); - $fieldTypeMock->expects($this->once()) + $fieldTypeMock->expects(self::once()) ->method('validatorConfigurationToHash') - ->with($this->equalTo('validator-config')) + ->with(self::equalTo('validator-config')) ->willReturn(['bar' => 'foo']); $serializer->serializeValidatorConfiguration( diff --git a/tests/lib/Output/Generator/FieldTypeHashGeneratorBaseTest.php b/tests/lib/Output/Generator/FieldTypeHashGeneratorBaseTest.php index 79c03596..f8ac763a 100644 --- a/tests/lib/Output/Generator/FieldTypeHashGeneratorBaseTest.php +++ b/tests/lib/Output/Generator/FieldTypeHashGeneratorBaseTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Output\Generator; use PHPUnit\Framework\TestCase; @@ -290,7 +291,7 @@ private function assertSerializationSame($functionName) // file_put_contents( $fixtureFile, $actualResult ); // $this->markTestIncomplete( "Wrote fixture to '{$fixtureFile}'." ); - $this->assertSame( + self::assertSame( file_get_contents($this->getFixtureFile($functionName)), $actualResult ); diff --git a/tests/lib/Output/Generator/Json/FieldTypeHashGeneratorTest.php b/tests/lib/Output/Generator/Json/FieldTypeHashGeneratorTest.php index 1b1333a9..980958e3 100644 --- a/tests/lib/Output/Generator/Json/FieldTypeHashGeneratorTest.php +++ b/tests/lib/Output/Generator/Json/FieldTypeHashGeneratorTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Output\Generator\Json; use Ibexa\Rest\Output\Generator\Json; diff --git a/tests/lib/Output/Generator/JsonTest.php b/tests/lib/Output/Generator/JsonTest.php index f3af8715..e91a2911 100644 --- a/tests/lib/Output/Generator/JsonTest.php +++ b/tests/lib/Output/Generator/JsonTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Output\Generator; use Ibexa\Contracts\Rest\Output\Exceptions\OutputGeneratorException; @@ -26,7 +27,7 @@ public function testGeneratorDocument() $generator->startDocument('test'); - $this->assertSame( + self::assertSame( '{}', $generator->endDocument('test') ); @@ -41,7 +42,7 @@ public function testGeneratorElement() $generator->startObjectElement('element'); $generator->endObjectElement('element'); - $this->assertSame( + self::assertSame( '{"element":{"_media-type":"application\/vnd.ibexa.api.element+json"}}', $generator->endDocument('test') ); @@ -56,7 +57,7 @@ public function testGeneratorElementMediaTypeOverwrite() $generator->startObjectElement('element', 'User'); $generator->endObjectElement('element'); - $this->assertSame( + self::assertSame( '{"element":{"_media-type":"application\/vnd.ibexa.api.User+json"}}', $generator->endDocument('test') ); @@ -75,7 +76,7 @@ public function testGeneratorStackedElement() $generator->endObjectElement('element'); - $this->assertSame( + self::assertSame( '{"element":{"_media-type":"application\/vnd.ibexa.api.element+json","stacked":{"_media-type":"application\/vnd.ibexa.api.stacked+json"}}}', $generator->endDocument('test') ); @@ -93,7 +94,7 @@ public function testGeneratorAttribute() $generator->endObjectElement('element'); - $this->assertSame( + self::assertSame( '{"element":{"_media-type":"application\/vnd.ibexa.api.element+json","_attribute":"value"}}', $generator->endDocument('test') ); @@ -112,7 +113,7 @@ public function testGeneratorStartEndAttribute() $generator->endObjectElement('element'); - $this->assertSame( + self::assertSame( '{"element":{"_media-type":"application\/vnd.ibexa.api.element+json","_attribute":"value"}}', $generator->endDocument('test') ); @@ -131,7 +132,7 @@ public function testGeneratorMultipleAttributes() $generator->endObjectElement('element'); - $this->assertSame( + self::assertSame( '{"element":{"_media-type":"application\/vnd.ibexa.api.element+json","_attribute1":"value","_attribute2":"value"}}', $generator->endDocument('test') ); @@ -149,7 +150,7 @@ public function testGeneratorValueElement() $generator->endObjectElement('element'); - $this->assertSame( + self::assertSame( '{"element":{"_media-type":"application\/vnd.ibexa.api.element+json","value":"42"}}', $generator->endDocument('test') ); @@ -168,7 +169,7 @@ public function testGeneratorStartEndValueElement() $generator->endObjectElement('element'); - $this->assertSame( + self::assertSame( '{"element":{"_media-type":"application\/vnd.ibexa.api.element+json","value":"42"}}', $generator->endDocument('test') ); @@ -194,7 +195,7 @@ public function testGeneratorElementList() $generator->endObjectElement('elementList'); - $this->assertSame( + self::assertSame( '{"elementList":{"_media-type":"application\/vnd.ibexa.api.elementList+json","elements":[{"_media-type":"application\/vnd.ibexa.api.element+json"},{"_media-type":"application\/vnd.ibexa.api.element+json"}]}}', $generator->endDocument('test') ); @@ -213,7 +214,7 @@ public function testGeneratorHashElement() $generator->endHashElement('elements'); - $this->assertSame( + self::assertSame( '{"elements":{"element":{"_attribute":"attribute value 1","#text":"element value 1"}}}', $generator->endDocument('test') ); @@ -235,7 +236,7 @@ public function testGeneratorValueList() $generator->endList('simpleValue'); $generator->endObjectElement('element'); - $this->assertSame( + self::assertSame( '{"element":{"_media-type":"application\/vnd.ibexa.api.element+json","simpleValue":["value1","value2"]}}', $generator->endDocument('test') ); @@ -253,7 +254,7 @@ public function testGetMediaType() { $generator = $this->getGenerator(); - $this->assertEquals( + self::assertEquals( 'application/vnd.ibexa.api.Section+json', $generator->getMediaType('Section') ); @@ -293,9 +294,9 @@ public function testSerializeBool() { $generator = $this->getGenerator(); - $this->assertTrue($generator->serializeBool(true) === true); - $this->assertTrue($generator->serializeBool(false) === false); - $this->assertTrue($generator->serializeBool('notbooleanbuttrue') === true); + self::assertTrue($generator->serializeBool(true) === true); + self::assertTrue($generator->serializeBool(false) === false); + self::assertTrue($generator->serializeBool('notbooleanbuttrue') === true); } protected function getGenerator() diff --git a/tests/lib/Output/Generator/Xml/FieldTypeHashGeneratorTest.php b/tests/lib/Output/Generator/Xml/FieldTypeHashGeneratorTest.php index 3254a075..dc9b0b0c 100644 --- a/tests/lib/Output/Generator/Xml/FieldTypeHashGeneratorTest.php +++ b/tests/lib/Output/Generator/Xml/FieldTypeHashGeneratorTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Output\Generator\Xml; use Ibexa\Rest\Output\Generator\Xml; diff --git a/tests/lib/Output/Generator/XmlTest.php b/tests/lib/Output/Generator/XmlTest.php index c55b6da6..50cb5c0d 100644 --- a/tests/lib/Output/Generator/XmlTest.php +++ b/tests/lib/Output/Generator/XmlTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Output\Generator; use Ibexa\Rest\Output\Generator\Xml; @@ -23,7 +24,7 @@ public function testGeneratorDocument() $generator->startDocument('test'); - $this->assertSame( + self::assertSame( file_get_contents(__DIR__ . '/_fixtures/' . __FUNCTION__ . '.xml'), $generator->endDocument('test') ); @@ -38,7 +39,7 @@ public function testGeneratorElement() $generator->startObjectElement('element'); $generator->endObjectElement('element'); - $this->assertSame( + self::assertSame( file_get_contents(__DIR__ . '/_fixtures/' . __FUNCTION__ . '.xml'), $generator->endDocument('test') ); @@ -53,7 +54,7 @@ public function testGeneratorElementMediaTypeOverwrite() $generator->startObjectElement('element', 'User'); $generator->endObjectElement('element'); - $this->assertSame( + self::assertSame( file_get_contents(__DIR__ . '/_fixtures/' . __FUNCTION__ . '.xml'), $generator->endDocument('test') ); @@ -72,7 +73,7 @@ public function testGeneratorStackedElement() $generator->endObjectElement('element'); - $this->assertSame( + self::assertSame( file_get_contents(__DIR__ . '/_fixtures/' . __FUNCTION__ . '.xml'), $generator->endDocument('test') ); @@ -90,7 +91,7 @@ public function testGeneratorAttribute() $generator->endObjectElement('element'); - $this->assertSame( + self::assertSame( file_get_contents(__DIR__ . '/_fixtures/' . __FUNCTION__ . '.xml'), $generator->endDocument('test') ); @@ -109,7 +110,7 @@ public function testGeneratorStartEndAttribute() $generator->endObjectElement('element'); - $this->assertSame( + self::assertSame( file_get_contents(__DIR__ . '/_fixtures/' . __FUNCTION__ . '.xml'), $generator->endDocument('test') ); @@ -128,7 +129,7 @@ public function testGeneratorMultipleAttributes() $generator->endObjectElement('element'); - $this->assertSame( + self::assertSame( file_get_contents(__DIR__ . '/_fixtures/' . __FUNCTION__ . '.xml'), $generator->endDocument('test') ); @@ -146,7 +147,7 @@ public function testGeneratorValueElement() $generator->endObjectElement('element'); - $this->assertSame( + self::assertSame( file_get_contents(__DIR__ . '/_fixtures/' . __FUNCTION__ . '.xml'), $generator->endDocument('test') ); @@ -165,7 +166,7 @@ public function testGeneratorStartEndValueElement() $generator->endObjectElement('element'); - $this->assertSame( + self::assertSame( file_get_contents(__DIR__ . '/_fixtures/' . __FUNCTION__ . '.xml'), $generator->endDocument('test') ); @@ -191,7 +192,7 @@ public function testGeneratorElementList() $generator->endObjectElement('elementList'); - $this->assertSame( + self::assertSame( file_get_contents(__DIR__ . '/_fixtures/' . __FUNCTION__ . '.xml'), $generator->endDocument('test') ); @@ -213,7 +214,7 @@ public function testGeneratorHashElement() $generator->endHashElement('elements'); - $this->assertSame( + self::assertSame( file_get_contents(__DIR__ . '/_fixtures/' . __FUNCTION__ . '.xml'), $generator->endDocument('test') ); @@ -235,7 +236,7 @@ public function testGeneratorValueList() $generator->endList('simpleValue'); $generator->endObjectElement('element'); - $this->assertSame( + self::assertSame( file_get_contents(__DIR__ . '/_fixtures/' . __FUNCTION__ . '.xml'), $generator->endDocument('test') ); @@ -253,7 +254,7 @@ public function testGetMediaType() { $generator = $this->getGenerator(); - $this->assertEquals( + self::assertEquals( 'application/vnd.ibexa.api.Section+xml', $generator->getMediaType('Section') ); @@ -263,9 +264,9 @@ public function testSerializeBool() { $generator = $this->getGenerator(); - $this->assertTrue($generator->serializeBool(true) === 'true'); - $this->assertTrue($generator->serializeBool(false) === 'false'); - $this->assertTrue($generator->serializeBool('notbooleanbuttrue') === 'true'); + self::assertTrue($generator->serializeBool(true) === 'true'); + self::assertTrue($generator->serializeBool(false) === 'false'); + self::assertTrue($generator->serializeBool('notbooleanbuttrue') === 'true'); } protected function getGenerator() diff --git a/tests/lib/Output/GeneratorTest.php b/tests/lib/Output/GeneratorTest.php index 0b0747ab..f63ac24f 100644 --- a/tests/lib/Output/GeneratorTest.php +++ b/tests/lib/Output/GeneratorTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Output; use Ibexa\Contracts\Rest\Output\Exceptions\OutputGeneratorException; @@ -42,7 +43,7 @@ public function testValidDocumentStartAfterReset() $generator->reset(); $generator->startDocument('test'); - $this->assertNotNull($generator->endDocument('test')); + self::assertNotNull($generator->endDocument('test')); } public function testInvalidDocumentNameEnd() @@ -173,7 +174,7 @@ public function testEmptyDocument() $generator->startDocument('test'); - $this->assertTrue($generator->isEmpty()); + self::assertTrue($generator->isEmpty()); } public function testNonEmptyDocument() @@ -183,7 +184,7 @@ public function testNonEmptyDocument() $generator->startDocument('test'); $generator->startObjectElement('element'); - $this->assertFalse($generator->isEmpty()); + self::assertFalse($generator->isEmpty()); } abstract protected function assertSnapshot(string $snapshotName, string $generatedContent): void; diff --git a/tests/lib/Output/ValueObject.php b/tests/lib/Output/ValueObject.php index 5c34b3de..c47eb9dd 100644 --- a/tests/lib/Output/ValueObject.php +++ b/tests/lib/Output/ValueObject.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Output; use stdClass; diff --git a/tests/lib/Output/ValueObjectVisitorBaseTest.php b/tests/lib/Output/ValueObjectVisitorBaseTest.php index ce13fd96..64433add 100644 --- a/tests/lib/Output/ValueObjectVisitorBaseTest.php +++ b/tests/lib/Output/ValueObjectVisitorBaseTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Output; use Ibexa\Contracts\Rest\Output\Visitor; @@ -65,7 +66,7 @@ protected function getVisitorMock() $this->visitorMock = $this->createMock(Visitor::class); $this->visitorMock - ->expects($this->any()) + ->expects(self::any()) ->method('getResponse') ->willReturn($this->getResponseMock()); } @@ -123,7 +124,7 @@ protected function assertXPath(\DOMNode $domNode, $xpathExpression) $xpath = new \DOMXPath($ownerDocument); - $this->assertTrue( + self::assertTrue( $xpath->evaluate("boolean({$xpathExpression})", $domNode), "XPath expression '{$xpathExpression}' resulted in an empty node set." ); @@ -182,11 +183,11 @@ protected function resetRouterMock() protected function addRouteExpectation($routeName, $arguments, $returnValue) { $this->getRouterMock() - ->expects($this->at($this->routerCallIndex++)) + ->expects(self::at($this->routerCallIndex++)) ->method('generate') ->with( - $this->equalTo($routeName), - $this->equalTo($arguments) + self::equalTo($routeName), + self::equalTo($arguments) ) ->willReturn($returnValue); } @@ -213,11 +214,11 @@ protected function getTemplatedRouterMock() protected function addTemplatedRouteExpectation($routeName, $arguments, $returnValue) { $this->getTemplatedRouterMock() - ->expects($this->at($this->templatedRouterCallIndex++)) + ->expects(self::at($this->templatedRouterCallIndex++)) ->method('generate') ->with( - $this->equalTo($routeName), - $this->equalTo($arguments) + self::equalTo($routeName), + self::equalTo($arguments) ) ->willReturn($returnValue); } diff --git a/tests/lib/Output/ValueObjectVisitorDispatcherTest.php b/tests/lib/Output/ValueObjectVisitorDispatcherTest.php index a9400afc..7f075aad 100644 --- a/tests/lib/Output/ValueObjectVisitorDispatcherTest.php +++ b/tests/lib/Output/ValueObjectVisitorDispatcherTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Output; use Error; @@ -37,7 +38,7 @@ public function testVisitValueObject() $visitor = $this->getValueObjectVisitorMock(); $visitor - ->expects($this->at(0)) + ->expects(self::at(0)) ->method('visit') ->with($this->getOutputVisitorMock(), $this->getOutputGeneratorMock(), $data); @@ -69,7 +70,7 @@ public function testVisitValueObjectParentMatch() $valueObjectVisitor = $this->getValueObjectVisitorMock(); $valueObjectVisitor - ->expects($this->at(0)) + ->expects(self::at(0)) ->method('visit') ->with($this->getOutputVisitorMock(), $this->getOutputGeneratorMock(), $data); @@ -91,11 +92,11 @@ public function testVisitValueObjectSecondRuleParentMatch() $dispatcher->addVisitor('stdClass', $valueObjectVisitor2); $valueObjectVisitor1 - ->expects($this->never()) + ->expects(self::never()) ->method('visit'); $valueObjectVisitor2 - ->expects($this->at(0)) + ->expects(self::at(0)) ->method('visit') ->with($this->getOutputVisitorMock(), $this->getOutputGeneratorMock(), $data); diff --git a/tests/lib/Output/VisitorTest.php b/tests/lib/Output/VisitorTest.php index afb6441f..8dc9499b 100644 --- a/tests/lib/Output/VisitorTest.php +++ b/tests/lib/Output/VisitorTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Output; use Ibexa\Contracts\Rest\Output\Generator; @@ -24,17 +25,17 @@ public function testVisitDocument() $generator = $this->getGeneratorMock(); $generator - ->expects($this->at(1)) + ->expects(self::at(1)) ->method('startDocument') ->with($data); $generator - ->expects($this->at(2)) + ->expects(self::at(2)) ->method('isEmpty') ->willReturn(false); $generator - ->expects($this->at(3)) + ->expects(self::at(3)) ->method('endDocument') ->with($data) ->willReturn('Hello world!'); @@ -44,7 +45,7 @@ public function testVisitDocument() ->setConstructorArgs([$generator, $this->getValueObjectDispatcherMock()]) ->getMock(); - $this->assertEquals( + self::assertEquals( new Response('Hello world!', 200, []), $visitor->visit($data) ); @@ -56,17 +57,17 @@ public function testVisitEmptyDocument() $generator = $this->getGeneratorMock(); $generator - ->expects($this->at(1)) + ->expects(self::at(1)) ->method('startDocument') ->with($data); $generator - ->expects($this->at(2)) + ->expects(self::at(2)) ->method('isEmpty') ->willReturn(true); $generator - ->expects($this->never()) + ->expects(self::never()) ->method('endDocument'); $visitor = $this->getMockBuilder(Visitor::class) @@ -74,7 +75,7 @@ public function testVisitEmptyDocument() ->setConstructorArgs([$generator, $this->getValueObjectDispatcherMock()]) ->getMock(); - $this->assertEquals( + self::assertEquals( new Response(null, 200, []), $visitor->visit($data) ); @@ -89,7 +90,7 @@ public function testVisitValueObject() $valueObjectDispatcherMock = $this->getValueObjectDispatcherMock(); $valueObjectDispatcherMock - ->expects($this->once()) + ->expects(self::once()) ->method('visit') ->with($data); @@ -104,7 +105,7 @@ public function testSetHeaders() $visitor = $this->getVisitorMock(); $visitor->setHeader('Content-Type', 'text/xml'); - $this->assertEquals( + self::assertEquals( new Response( null, 200, @@ -129,7 +130,7 @@ public function testSetFilteredHeaders() $visitor->setHeader('Content-Type', 'text/xml'); $visitor->setHeader('Accept-Patch', false); - $this->assertEquals( + self::assertEquals( new Response( null, 200, @@ -149,7 +150,7 @@ public function testSetHeadersNoOverwrite() $visitor->setHeader('Content-Type', 'text/xml'); $visitor->setHeader('Content-Type', 'text/html'); - $this->assertEquals( + self::assertEquals( new Response( null, 200, @@ -172,7 +173,7 @@ public function testSetHeaderResetAfterVisit() $visitor->visit($data); $result = $visitor->visit($data); - $this->assertEquals( + self::assertEquals( new Response( null, 200, @@ -189,7 +190,7 @@ public function testSetStatusCode() $visitor = $this->getVisitorMock(); $visitor->setStatus(201); - $this->assertEquals( + self::assertEquals( new Response( null, 201 @@ -207,7 +208,7 @@ public function testSetStatusCodeNoOverride() $visitor->setStatus(201); $visitor->setStatus(404); - $this->assertEquals( + self::assertEquals( new Response( null, 201 diff --git a/tests/lib/Server/BaseTest.php b/tests/lib/Server/BaseTest.php index 1704b68f..74907a46 100644 --- a/tests/lib/Server/BaseTest.php +++ b/tests/lib/Server/BaseTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server; use PHPUnit\Framework\TestCase; diff --git a/tests/lib/Server/Input/Parser/BaseTest.php b/tests/lib/Server/Input/Parser/BaseTest.php index cb6e7b07..8e8169f4 100644 --- a/tests/lib/Server/Input/Parser/BaseTest.php +++ b/tests/lib/Server/Input/Parser/BaseTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Rest\Input\ParsingDispatcher; @@ -85,7 +86,7 @@ protected function getRequestParserMock() $this->requestParserMock = $this->createMock(RequestParser::class); $this->requestParserMock - ->expects($this->any()) + ->expects(self::any()) ->method('parseHref') ->willReturnCallback($callback); } diff --git a/tests/lib/Server/Input/Parser/ContentCreateTest.php b/tests/lib/Server/Input/Parser/ContentCreateTest.php index bbd3ce3a..5ae6bd23 100644 --- a/tests/lib/Server/Input/Parser/ContentCreateTest.php +++ b/tests/lib/Server/Input/Parser/ContentCreateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\FieldTypeService; @@ -57,67 +58,67 @@ public function testParse() $contentCreate = $this->getParser(); $result = $contentCreate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( '\\Ibexa\\Rest\\Server\\Values\\RestContentCreateStruct', $result, 'ContentCreate not created correctly.' ); - $this->assertInstanceOf( + self::assertInstanceOf( '\\Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\ContentCreateStruct', $result->contentCreateStruct, 'contentCreateStruct not created correctly.' ); - $this->assertInstanceOf( + self::assertInstanceOf( '\\Ibexa\\Contracts\\Core\\Repository\\Values\\ContentType\\ContentType', $result->contentCreateStruct->contentType, 'contentType not created correctly.' ); - $this->assertEquals( + self::assertEquals( 13, $result->contentCreateStruct->contentType->id, 'contentType not created correctly' ); - $this->assertEquals( + self::assertEquals( 'eng-US', $result->contentCreateStruct->mainLanguageCode, 'mainLanguageCode not created correctly' ); - $this->assertInstanceOf( + self::assertInstanceOf( '\\Ibexa\\Contracts\\Core\\Repository\\Values\\Content\\LocationCreateStruct', $result->locationCreateStruct, 'locationCreateStruct not created correctly.' ); - $this->assertEquals( + self::assertEquals( 4, $result->contentCreateStruct->sectionId, 'sectionId not created correctly' ); - $this->assertTrue( + self::assertTrue( $result->contentCreateStruct->alwaysAvailable, 'alwaysAvailable not created correctly' ); - $this->assertEquals( + self::assertEquals( 'remoteId12345678', $result->contentCreateStruct->remoteId, 'remoteId not created correctly' ); - $this->assertEquals( + self::assertEquals( 14, $result->contentCreateStruct->ownerId, 'ownerId not created correctly' ); foreach ($result->contentCreateStruct->fields as $field) { - $this->assertEquals( + self::assertEquals( 'foo', $field->value, 'field value not created correctly' @@ -525,7 +526,7 @@ private function getFieldTypeParserMock() ) ->getMock(); - $fieldTypeParserMock->expects($this->any()) + $fieldTypeParserMock->expects(self::any()) ->method('parseValue') ->with('ezstring', []) ->willReturn('foo'); @@ -542,7 +543,7 @@ private function getLocationCreateParserMock() { $locationCreateParserMock = $this->createMock(LocationCreate::class); - $locationCreateParserMock->expects($this->any()) + $locationCreateParserMock->expects(self::any()) ->method('parse') ->with([], $this->getParsingDispatcherMock()) ->willReturn(new LocationCreateStruct()); @@ -560,11 +561,11 @@ protected function getContentServiceMock() $contentServiceMock = $this->createMock(ContentService::class); $contentType = $this->getContentType(); - $contentServiceMock->expects($this->any()) + $contentServiceMock->expects(self::any()) ->method('newContentCreateStruct') ->with( - $this->equalTo($contentType), - $this->equalTo('eng-US') + self::equalTo($contentType), + self::equalTo('eng-US') ) ->willReturn( new ContentCreateStruct( @@ -587,9 +588,9 @@ protected function getContentTypeServiceMock() { $contentTypeServiceMock = $this->createMock(ContentTypeService::class); - $contentTypeServiceMock->expects($this->any()) + $contentTypeServiceMock->expects(self::any()) ->method('loadContentType') - ->with($this->equalTo(13)) + ->with(self::equalTo(13)) ->willReturn($this->getContentType()); return $contentTypeServiceMock; diff --git a/tests/lib/Server/Input/Parser/ContentObjectStatesTest.php b/tests/lib/Server/Input/Parser/ContentObjectStatesTest.php index 0ae43bc9..24ac9aad 100644 --- a/tests/lib/Server/Input/Parser/ContentObjectStatesTest.php +++ b/tests/lib/Server/Input/Parser/ContentObjectStatesTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Rest\Input\Parser; @@ -26,32 +27,32 @@ public function testParse() $objectState = $this->getParser(); $result = $objectState->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertIsArray($result, 'ContentObjectStates not parsed correctly'); + self::assertIsArray($result, 'ContentObjectStates not parsed correctly'); - $this->assertNotEmpty( + self::assertNotEmpty( $result, 'ContentObjectStates has no ObjectState elements' ); - $this->assertInstanceOf( + self::assertInstanceOf( '\\Ibexa\\Rest\\Values\\RestObjectState', $result[0], 'ObjectState not created correctly.' ); - $this->assertInstanceOf( + self::assertInstanceOf( '\\Ibexa\\Contracts\\Core\\Repository\\Values\\ObjectState\\ObjectState', $result[0]->objectState, 'Inner ObjectState not created correctly.' ); - $this->assertEquals( + self::assertEquals( 21, $result[0]->objectState->id, 'Inner ObjectState id property not created correctly.' ); - $this->assertEquals( + self::assertEquals( 42, $result[0]->groupId, 'groupId property not created correctly.' diff --git a/tests/lib/Server/Input/Parser/ContentTypeCreateTest.php b/tests/lib/Server/Input/Parser/ContentTypeCreateTest.php index a1b062fb..ff85183f 100644 --- a/tests/lib/Server/Input/Parser/ContentTypeCreateTest.php +++ b/tests/lib/Server/Input/Parser/ContentTypeCreateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\Content\Location; @@ -26,90 +27,90 @@ public function testParse() $contentTypeCreate = $this->getParser(); $result = $contentTypeCreate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( ContentTypeCreateStruct::class, $result, 'ContentTypeCreateStruct not created correctly.' ); - $this->assertEquals( + self::assertEquals( 'new_content_type', $result->identifier, 'identifier not created correctly' ); - $this->assertEquals( + self::assertEquals( 'eng-US', $result->mainLanguageCode, 'mainLanguageCode not created correctly' ); - $this->assertEquals( + self::assertEquals( 'remote123456', $result->remoteId, 'remoteId not created correctly' ); - $this->assertEquals( + self::assertEquals( '', $result->urlAliasSchema, 'urlAliasSchema not created correctly' ); - $this->assertEquals( + self::assertEquals( '<title>', $result->nameSchema, 'nameSchema not created correctly' ); - $this->assertTrue( + self::assertTrue( $result->isContainer, 'isContainer not created correctly' ); - $this->assertEquals( + self::assertEquals( Location::SORT_FIELD_PATH, $result->defaultSortField, 'defaultSortField not created correctly' ); - $this->assertEquals( + self::assertEquals( Location::SORT_ORDER_ASC, $result->defaultSortOrder, 'defaultSortOrder not created correctly' ); - $this->assertTrue( + self::assertTrue( $result->defaultAlwaysAvailable, 'defaultAlwaysAvailable not created correctly' ); - $this->assertEquals( + self::assertEquals( ['eng-US' => 'New content type'], $result->names, 'names not created correctly' ); - $this->assertEquals( + self::assertEquals( ['eng-US' => 'New content type description'], $result->descriptions, 'descriptions not created correctly' ); - $this->assertEquals( + self::assertEquals( new \DateTime('2012-12-31T12:30:00'), $result->creationDate, 'creationDate not created correctly' ); - $this->assertEquals( + self::assertEquals( 14, $result->creatorId, 'creatorId not created correctly' ); foreach ($result->fieldDefinitions as $fieldDefinition) { - $this->assertInstanceOf( + self::assertInstanceOf( FieldDefinitionCreateStruct::class, $fieldDefinition, 'ContentTypeCreateStruct field definition not created correctly.' @@ -254,7 +255,7 @@ private function getFieldDefinitionCreateParserMock() { $fieldDefinitionCreateParserMock = $this->createMock(FieldDefinitionCreate::class); - $fieldDefinitionCreateParserMock->expects($this->any()) + $fieldDefinitionCreateParserMock->expects(self::any()) ->method('parse') ->with([], $this->getParsingDispatcherMock()) ->willReturn(new FieldDefinitionCreateStruct()); @@ -271,9 +272,9 @@ protected function getContentTypeServiceMock() { $contentTypeServiceMock = $this->createMock(ContentTypeService::class); - $contentTypeServiceMock->expects($this->any()) + $contentTypeServiceMock->expects(self::any()) ->method('newContentTypeCreateStruct') - ->with($this->equalTo('new_content_type')) + ->with(self::equalTo('new_content_type')) ->willReturn( new ContentTypeCreateStruct( [ diff --git a/tests/lib/Server/Input/Parser/ContentTypeGroupInputTest.php b/tests/lib/Server/Input/Parser/ContentTypeGroupInputTest.php index 1f2bac97..48c5c55a 100644 --- a/tests/lib/Server/Input/Parser/ContentTypeGroupInputTest.php +++ b/tests/lib/Server/Input/Parser/ContentTypeGroupInputTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\ContentType\ContentTypeGroupCreateStruct; @@ -29,25 +30,25 @@ public function testParse() $contentTypeGroupInput = $this->getParser(); $result = $contentTypeGroupInput->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( ContentTypeGroupCreateStruct::class, $result, 'ContentTypeGroupCreateStruct not created correctly.' ); - $this->assertEquals( + self::assertEquals( 'Identifier Bar', $result->identifier, 'ContentTypeGroupCreateStruct identifier property not created correctly.' ); - $this->assertEquals( + self::assertEquals( 14, $result->creatorId, 'ContentTypeGroupCreateStruct creatorId property not created correctly.' ); - $this->assertEquals( + self::assertEquals( new \DateTime('2012-12-31T12:00:00'), $result->creationDate, 'ContentTypeGroupCreateStruct creationDate property not created correctly.' @@ -93,9 +94,9 @@ protected function getContentTypeServiceMock() { $contentTypeServiceMock = $this->createMock(ContentTypeService::class); - $contentTypeServiceMock->expects($this->any()) + $contentTypeServiceMock->expects(self::any()) ->method('newContentTypeGroupCreateStruct') - ->with($this->equalTo('Identifier Bar')) + ->with(self::equalTo('Identifier Bar')) ->willReturn( new ContentTypeGroupCreateStruct(['identifier' => 'Identifier Bar']) ); diff --git a/tests/lib/Server/Input/Parser/ContentTypeUpdateTest.php b/tests/lib/Server/Input/Parser/ContentTypeUpdateTest.php index d744a20c..ddb29a8c 100644 --- a/tests/lib/Server/Input/Parser/ContentTypeUpdateTest.php +++ b/tests/lib/Server/Input/Parser/ContentTypeUpdateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\Content\Location; @@ -24,83 +25,83 @@ public function testParse() $contentTypeUpdate = $this->getParser(); $result = $contentTypeUpdate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( ContentTypeUpdateStruct::class, $result, 'ContentTypeUpdateStruct not created correctly.' ); - $this->assertEquals( + self::assertEquals( 'updated_content_type', $result->identifier, 'identifier not created correctly' ); - $this->assertEquals( + self::assertEquals( 'eng-US', $result->mainLanguageCode, 'mainLanguageCode not created correctly' ); - $this->assertEquals( + self::assertEquals( 'remote123456', $result->remoteId, 'remoteId not created correctly' ); - $this->assertEquals( + self::assertEquals( '<title>', $result->urlAliasSchema, 'urlAliasSchema not created correctly' ); - $this->assertEquals( + self::assertEquals( '<title>', $result->nameSchema, 'nameSchema not created correctly' ); - $this->assertTrue( + self::assertTrue( $result->isContainer, 'isContainer not created correctly' ); - $this->assertEquals( + self::assertEquals( Location::SORT_FIELD_PATH, $result->defaultSortField, 'defaultSortField not created correctly' ); - $this->assertEquals( + self::assertEquals( Location::SORT_ORDER_ASC, $result->defaultSortOrder, 'defaultSortOrder not created correctly' ); - $this->assertTrue( + self::assertTrue( $result->defaultAlwaysAvailable, 'defaultAlwaysAvailable not created correctly' ); - $this->assertEquals( + self::assertEquals( ['eng-US' => 'Updated content type'], $result->names, 'names not created correctly' ); - $this->assertEquals( + self::assertEquals( ['eng-US' => 'Updated content type description'], $result->descriptions, 'descriptions not created correctly' ); - $this->assertEquals( + self::assertEquals( new \DateTime('2012-12-31T12:30:00'), $result->modificationDate, 'creationDate not created correctly' ); - $this->assertEquals( + self::assertEquals( 14, $result->modifierId, 'creatorId not created correctly' @@ -171,7 +172,7 @@ protected function getContentTypeServiceMock() { $contentTypeServiceMock = $this->createMock(ContentTypeService::class); - $contentTypeServiceMock->expects($this->any()) + $contentTypeServiceMock->expects(self::any()) ->method('newContentTypeUpdateStruct') ->willReturn(new ContentTypeUpdateStruct()); diff --git a/tests/lib/Server/Input/Parser/ContentUpdateTest.php b/tests/lib/Server/Input/Parser/ContentUpdateTest.php index 1b4c3047..8ae95e48 100644 --- a/tests/lib/Server/Input/Parser/ContentUpdateTest.php +++ b/tests/lib/Server/Input/Parser/ContentUpdateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use DateTime; @@ -46,7 +47,7 @@ public function testParseValid() */ public function testParserResultOwner(RestContentMetadataUpdateStruct $result) { - $this->assertEquals( + self::assertEquals( '42', $result->ownerId ); diff --git a/tests/lib/Server/Input/Parser/Criterion/DateMetadataTest.php b/tests/lib/Server/Input/Parser/Criterion/DateMetadataTest.php index 9f3cf367..ad78fadc 100644 --- a/tests/lib/Server/Input/Parser/Criterion/DateMetadataTest.php +++ b/tests/lib/Server/Input/Parser/Criterion/DateMetadataTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\DateMetadata as DateMetadataCriterion; @@ -56,6 +57,7 @@ public function testParseProvider(): iterable * Tests the DateMetaData parser. * * @param string[] $data + * * @dataProvider testParseProvider */ public function testParse(array $data, DateMetadataCriterion $expected): void @@ -63,7 +65,7 @@ public function testParse(array $data, DateMetadataCriterion $expected): void $dateMetadata = $this->getParser(); $result = $dateMetadata->parse($data, $this->getParsingDispatcherMock()); - $this->assertEquals( + self::assertEquals( $expected, $result, 'DateMetadata parser not created correctly.' diff --git a/tests/lib/Server/Input/Parser/Criterion/LogicalAndTest.php b/tests/lib/Server/Input/Parser/Criterion/LogicalAndTest.php index e6fd886f..17a40637 100644 --- a/tests/lib/Server/Input/Parser/Criterion/LogicalAndTest.php +++ b/tests/lib/Server/Input/Parser/Criterion/LogicalAndTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content; diff --git a/tests/lib/Server/Input/Parser/Criterion/LogicalOrTest.php b/tests/lib/Server/Input/Parser/Criterion/LogicalOrTest.php index eb081897..193b79a9 100644 --- a/tests/lib/Server/Input/Parser/Criterion/LogicalOrTest.php +++ b/tests/lib/Server/Input/Parser/Criterion/LogicalOrTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content; diff --git a/tests/lib/Server/Input/Parser/Criterion/SiblingTest.php b/tests/lib/Server/Input/Parser/Criterion/SiblingTest.php index 05c7ba70..3f8fe94d 100644 --- a/tests/lib/Server/Input/Parser/Criterion/SiblingTest.php +++ b/tests/lib/Server/Input/Parser/Criterion/SiblingTest.php @@ -49,7 +49,7 @@ public function testParse(): void self::EXAMPLE_PARENT_LOCATION_ID ); - $this->assertEquals($exepected, $actual); + self::assertEquals($exepected, $actual); } public function testParseThrowsParserException(): void diff --git a/tests/lib/Server/Input/Parser/Criterion/UserMetadataTest.php b/tests/lib/Server/Input/Parser/Criterion/UserMetadataTest.php index dc5a73fa..135efcaf 100644 --- a/tests/lib/Server/Input/Parser/Criterion/UserMetadataTest.php +++ b/tests/lib/Server/Input/Parser/Criterion/UserMetadataTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser\Criterion; use Ibexa\Contracts\Core\Repository\Values\Content\Query\Criterion\Operator; @@ -42,7 +43,7 @@ public function testParse($data, $expected) $userMetadata = $this->getParser(); $result = $userMetadata->parse($data, $this->getParsingDispatcherMock()); - $this->assertEquals( + self::assertEquals( $expected, $result, 'UserMetadata parser not created correctly.' diff --git a/tests/lib/Server/Input/Parser/FacetBuilder/FacetBuilderBaseTest.php b/tests/lib/Server/Input/Parser/FacetBuilder/FacetBuilderBaseTest.php index 934d8dc5..db44c47c 100644 --- a/tests/lib/Server/Input/Parser/FacetBuilder/FacetBuilderBaseTest.php +++ b/tests/lib/Server/Input/Parser/FacetBuilder/FacetBuilderBaseTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser\FacetBuilder; use Ibexa\Contracts\Rest\Input\ParsingDispatcher; diff --git a/tests/lib/Server/Input/Parser/FacetBuilder/FacetBuilderParserTest.php b/tests/lib/Server/Input/Parser/FacetBuilder/FacetBuilderParserTest.php index 5b23eee4..482af2d4 100644 --- a/tests/lib/Server/Input/Parser/FacetBuilder/FacetBuilderParserTest.php +++ b/tests/lib/Server/Input/Parser/FacetBuilder/FacetBuilderParserTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser\FacetBuilder; use Ibexa\Contracts\Core\Repository\Values\Content\Query; @@ -50,7 +51,7 @@ public function testGenericFacetBuilder(): void ], ]); - $this->assertEquals($expectedQuery, $result); + self::assertEquals($expectedQuery, $result); } public function testQueryContentTypeFacetBuilder(): void @@ -72,7 +73,7 @@ public function testQueryContentTypeFacetBuilder(): void ], ]); - $this->assertEquals($expectedQuery, $result); + self::assertEquals($expectedQuery, $result); } public function testQueryCriterionFacetBuilder(): void @@ -98,7 +99,7 @@ public function testQueryCriterionFacetBuilder(): void ], ]); - $this->assertEquals($expectedQuery, $result); + self::assertEquals($expectedQuery, $result); } public function testQueryFieldFacetBuilder(): void @@ -132,7 +133,7 @@ public function testQueryFieldFacetBuilder(): void ], ]); - $this->assertEquals($expectedQuery, $result); + self::assertEquals($expectedQuery, $result); } public function testQueryLocationFacetBuilder(): void @@ -158,7 +159,7 @@ public function testQueryLocationFacetBuilder(): void ], ]); - $this->assertEquals($expectedQuery, $result); + self::assertEquals($expectedQuery, $result); } public function testQuerySectionFacetBuilder(): void @@ -180,7 +181,7 @@ public function testQuerySectionFacetBuilder(): void ], ]); - $this->assertEquals($expectedQuery, $result); + self::assertEquals($expectedQuery, $result); } public function testQueryTermFacetBuilder(): void @@ -202,7 +203,7 @@ public function testQueryTermFacetBuilder(): void ], ]); - $this->assertEquals($expectedQuery, $result); + self::assertEquals($expectedQuery, $result); } public function testQueryUserFacetBuilder(): void @@ -228,7 +229,7 @@ public function testQueryUserFacetBuilder(): void ], ]); - $this->assertEquals($expectedQuery, $result); + self::assertEquals($expectedQuery, $result); } public function testQueryNoFacetBuilders(): void @@ -246,7 +247,7 @@ public function testQueryNoFacetBuilders(): void 'facetBuilders' => [], ]); - $this->assertEquals($expectedQuery, $result); + self::assertEquals($expectedQuery, $result); } public function testQueryMultipleFacetBuilders(): void @@ -274,7 +275,7 @@ public function testQueryMultipleFacetBuilders(): void ], ]); - $this->assertEquals($expectedQuery, $result); + self::assertEquals($expectedQuery, $result); } } diff --git a/tests/lib/Server/Input/Parser/FieldDefinitionCreateTest.php b/tests/lib/Server/Input/Parser/FieldDefinitionCreateTest.php index f2c7141b..14002da8 100644 --- a/tests/lib/Server/Input/Parser/FieldDefinitionCreateTest.php +++ b/tests/lib/Server/Input/Parser/FieldDefinitionCreateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\ContentType\FieldDefinitionCreateStruct; @@ -27,81 +28,81 @@ public function testParse() $fieldDefinitionCreate = $this->getParser(); $result = $fieldDefinitionCreate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( FieldDefinitionCreateStruct::class, $result, 'FieldDefinitionCreateStruct not created correctly.' ); - $this->assertEquals( + self::assertEquals( 'title', $result->identifier, 'identifier not created correctly' ); - $this->assertEquals( + self::assertEquals( 'ezstring', $result->fieldTypeIdentifier, 'fieldTypeIdentifier not created correctly' ); - $this->assertEquals( + self::assertEquals( 'content', $result->fieldGroup, 'fieldGroup not created correctly' ); - $this->assertEquals( + self::assertEquals( 1, $result->position, 'position not created correctly' ); - $this->assertTrue( + self::assertTrue( $result->isTranslatable, 'isTranslatable not created correctly' ); - $this->assertTrue( + self::assertTrue( $result->isRequired, 'isRequired not created correctly' ); - $this->assertTrue( + self::assertTrue( $result->isInfoCollector, 'isInfoCollector not created correctly' ); - $this->assertTrue( + self::assertTrue( $result->isSearchable, 'isSearchable not created correctly' ); - $this->assertEquals( + self::assertEquals( 'New title', $result->defaultValue, 'defaultValue not created correctly' ); - $this->assertEquals( + self::assertEquals( ['eng-US' => 'Title'], $result->names, 'names not created correctly' ); - $this->assertEquals( + self::assertEquals( ['eng-US' => 'This is the title'], $result->descriptions, 'descriptions not created correctly' ); - $this->assertEquals( + self::assertEquals( ['textRows' => 24], $result->fieldSettings, 'fieldSettings not created correctly' ); - $this->assertEquals( + self::assertEquals( [ 'StringLengthValidator' => [ 'minStringLength' => 12, @@ -192,15 +193,15 @@ protected function getFieldTypeParserMock() { $fieldTypeParserMock = $this->createMock(FieldTypeParser::class); - $fieldTypeParserMock->expects($this->any()) + $fieldTypeParserMock->expects(self::any()) ->method('parseValue') ->willReturn('New title'); - $fieldTypeParserMock->expects($this->any()) + $fieldTypeParserMock->expects(self::any()) ->method('parseFieldSettings') ->willReturn(['textRows' => 24]); - $fieldTypeParserMock->expects($this->any()) + $fieldTypeParserMock->expects(self::any()) ->method('parseValidatorConfiguration') ->willReturn( [ @@ -223,9 +224,9 @@ protected function getContentTypeServiceMock() { $contentTypeServiceMock = $this->createMock(ContentTypeService::class); - $contentTypeServiceMock->expects($this->any()) + $contentTypeServiceMock->expects(self::any()) ->method('newFieldDefinitionCreateStruct') - ->with($this->equalTo('title'), $this->equalTo('ezstring')) + ->with(self::equalTo('title'), self::equalTo('ezstring')) ->willReturn( new FieldDefinitionCreateStruct( [ diff --git a/tests/lib/Server/Input/Parser/FieldDefinitionUpdateTest.php b/tests/lib/Server/Input/Parser/FieldDefinitionUpdateTest.php index d7472186..41c01e96 100644 --- a/tests/lib/Server/Input/Parser/FieldDefinitionUpdateTest.php +++ b/tests/lib/Server/Input/Parser/FieldDefinitionUpdateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\ContentType\FieldDefinitionUpdateStruct; @@ -31,75 +32,75 @@ public function testParse() $fieldDefinitionUpdate = $this->getParser(); $result = $fieldDefinitionUpdate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( FieldDefinitionUpdateStruct::class, $result, 'FieldDefinitionUpdateStruct not created correctly.' ); - $this->assertEquals( + self::assertEquals( 'title', $result->identifier, 'identifier not created correctly' ); - $this->assertEquals( + self::assertEquals( 'content', $result->fieldGroup, 'fieldGroup not created correctly' ); - $this->assertEquals( + self::assertEquals( 1, $result->position, 'position not created correctly' ); - $this->assertTrue( + self::assertTrue( $result->isTranslatable, 'isTranslatable not created correctly' ); - $this->assertTrue( + self::assertTrue( $result->isRequired, 'isRequired not created correctly' ); - $this->assertTrue( + self::assertTrue( $result->isInfoCollector, 'isInfoCollector not created correctly' ); - $this->assertTrue( + self::assertTrue( $result->isSearchable, 'isSearchable not created correctly' ); - $this->assertEquals( + self::assertEquals( 'New title', $result->defaultValue, 'defaultValue not created correctly' ); - $this->assertEquals( + self::assertEquals( ['eng-US' => 'Title'], $result->names, 'names not created correctly' ); - $this->assertEquals( + self::assertEquals( ['eng-US' => 'This is the title'], $result->descriptions, 'descriptions not created correctly' ); - $this->assertEquals( + self::assertEquals( ['textRows' => 24], $result->fieldSettings, 'fieldSettings not created correctly' ); - $this->assertEquals( + self::assertEquals( [ 'StringLengthValidator' => [ 'minStringLength' => 12, @@ -162,15 +163,15 @@ protected function getFieldTypeParserMock() { $fieldTypeParserMock = $this->createMock(FieldTypeParser::class); - $fieldTypeParserMock->expects($this->any()) + $fieldTypeParserMock->expects(self::any()) ->method('parseValue') ->willReturn('New title'); - $fieldTypeParserMock->expects($this->any()) + $fieldTypeParserMock->expects(self::any()) ->method('parseFieldSettings') ->willReturn(['textRows' => 24]); - $fieldTypeParserMock->expects($this->any()) + $fieldTypeParserMock->expects(self::any()) ->method('parseValidatorConfiguration') ->willReturn( [ @@ -193,15 +194,15 @@ protected function getContentTypeServiceMock() { $contentTypeServiceMock = $this->createMock(ContentTypeService::class); - $contentTypeServiceMock->expects($this->any()) + $contentTypeServiceMock->expects(self::any()) ->method('newFieldDefinitionUpdateStruct') ->willReturn( new FieldDefinitionUpdateStruct() ); - $contentTypeServiceMock->expects($this->any()) + $contentTypeServiceMock->expects(self::any()) ->method('loadContentTypeDraft') - ->with($this->equalTo(42)) + ->with(self::equalTo(42)) ->willReturn( new ContentTypeDraft( [ diff --git a/tests/lib/Server/Input/Parser/Limitation/PathStringRouteBasedLimitationParserTest.php b/tests/lib/Server/Input/Parser/Limitation/PathStringRouteBasedLimitationParserTest.php index 087391ba..638035be 100644 --- a/tests/lib/Server/Input/Parser/Limitation/PathStringRouteBasedLimitationParserTest.php +++ b/tests/lib/Server/Input/Parser/Limitation/PathStringRouteBasedLimitationParserTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser\Limitation; use Ibexa\Rest\Server\Input\Parser\Limitation\PathStringRouteBasedLimitationParser; diff --git a/tests/lib/Server/Input/Parser/Limitation/RouteBasedLimitationParserTest.php b/tests/lib/Server/Input/Parser/Limitation/RouteBasedLimitationParserTest.php index e7639f22..ef4c54e0 100644 --- a/tests/lib/Server/Input/Parser/Limitation/RouteBasedLimitationParserTest.php +++ b/tests/lib/Server/Input/Parser/Limitation/RouteBasedLimitationParserTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser\Limitation; use Ibexa\Rest\Server\Input\Parser\Limitation\RouteBasedLimitationParser; diff --git a/tests/lib/Server/Input/Parser/LocationCreateTest.php b/tests/lib/Server/Input/Parser/LocationCreateTest.php index 9bbfc9ff..2f8b4c42 100644 --- a/tests/lib/Server/Input/Parser/LocationCreateTest.php +++ b/tests/lib/Server/Input/Parser/LocationCreateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\Content\Location; @@ -33,42 +34,42 @@ public function testParse() $locationCreate = $this->getParser(); $result = $locationCreate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( LocationCreateStruct::class, $result, 'LocationCreateStruct not created correctly.' ); - $this->assertEquals( + self::assertEquals( 42, $result->parentLocationId, 'LocationCreateStruct parentLocationId property not created correctly.' ); - $this->assertEquals( + self::assertEquals( 2, $result->priority, 'LocationCreateStruct priority property not created correctly.' ); - $this->assertTrue( + self::assertTrue( $result->hidden, 'LocationCreateStruct hidden property not created correctly.' ); - $this->assertEquals( + self::assertEquals( 'remoteId12345678', $result->remoteId, 'LocationCreateStruct remoteId property not created correctly.' ); - $this->assertEquals( + self::assertEquals( Location::SORT_FIELD_PATH, $result->sortField, 'LocationCreateStruct sortField property not created correctly.' ); - $this->assertEquals( + self::assertEquals( Location::SORT_ORDER_ASC, $result->sortOrder, 'LocationCreateStruct sortOrder property not created correctly.' @@ -178,9 +179,9 @@ protected function getLocationServiceMock() { $locationServiceMock = $this->createMock(LocationService::class); - $locationServiceMock->expects($this->any()) + $locationServiceMock->expects(self::any()) ->method('newLocationCreateStruct') - ->with($this->equalTo(42)) + ->with(self::equalTo(42)) ->willReturn( new LocationCreateStruct(['parentLocationId' => 42]) ); diff --git a/tests/lib/Server/Input/Parser/LocationUpdateTest.php b/tests/lib/Server/Input/Parser/LocationUpdateTest.php index 792d4d5e..a11be397 100644 --- a/tests/lib/Server/Input/Parser/LocationUpdateTest.php +++ b/tests/lib/Server/Input/Parser/LocationUpdateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\Content\Location; @@ -31,42 +32,42 @@ public function testParse() $locationUpdate = $this->getParser(); $result = $locationUpdate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( RestLocationUpdateStruct::class, $result, 'LocationUpdateStruct not created correctly.' ); - $this->assertInstanceOf( + self::assertInstanceOf( LocationUpdateStruct::class, $result->locationUpdateStruct, 'LocationUpdateStruct not created correctly.' ); - $this->assertEquals( + self::assertEquals( 0, $result->locationUpdateStruct->priority, 'LocationUpdateStruct priority property not created correctly.' ); - $this->assertEquals( + self::assertEquals( 'remote-id', $result->locationUpdateStruct->remoteId, 'LocationUpdateStruct remoteId property not created correctly.' ); - $this->assertTrue( + self::assertTrue( $result->hidden, 'hidden property not created correctly.' ); - $this->assertEquals( + self::assertEquals( Location::SORT_FIELD_PATH, $result->locationUpdateStruct->sortField, 'LocationUpdateStruct sortField property not created correctly.' ); - $this->assertEquals( + self::assertEquals( Location::SORT_ORDER_ASC, $result->locationUpdateStruct->sortOrder, 'LocationUpdateStruct sortOrder property not created correctly.' @@ -87,17 +88,17 @@ public function testParseWithMissingSortField() $locationUpdate = $this->getParser(); $result = $locationUpdate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( RestLocationUpdateStruct::class, $result ); - $this->assertInstanceOf( + self::assertInstanceOf( LocationUpdateStruct::class, $result->locationUpdateStruct ); - $this->assertNull( + self::assertNull( $result->locationUpdateStruct->sortField ); } @@ -116,17 +117,17 @@ public function testParseWithMissingSortOrder() $locationUpdate = $this->getParser(); $result = $locationUpdate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( RestLocationUpdateStruct::class, $result ); - $this->assertInstanceOf( + self::assertInstanceOf( LocationUpdateStruct::class, $result->locationUpdateStruct ); - $this->assertNull( + self::assertNull( $result->locationUpdateStruct->sortOrder ); } @@ -153,7 +154,7 @@ protected function getLocationServiceMock() { $locationServiceMock = $this->createMock(LocationService::class); - $locationServiceMock->expects($this->any()) + $locationServiceMock->expects(self::any()) ->method('newLocationUpdateStruct') ->willReturn( new LocationUpdateStruct() diff --git a/tests/lib/Server/Input/Parser/ObjectStateCreateTest.php b/tests/lib/Server/Input/Parser/ObjectStateCreateTest.php index e06a3720..44b76040 100644 --- a/tests/lib/Server/Input/Parser/ObjectStateCreateTest.php +++ b/tests/lib/Server/Input/Parser/ObjectStateCreateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\ObjectState\ObjectStateCreateStruct; @@ -43,37 +44,37 @@ public function testParse() $objectStateCreate = $this->getParser(); $result = $objectStateCreate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( ObjectStateCreateStruct::class, $result, 'ObjectStateCreateStruct not created correctly.' ); - $this->assertEquals( + self::assertEquals( 'test-state', $result->identifier, 'ObjectStateCreateStruct identifier property not created correctly.' ); - $this->assertEquals( + self::assertEquals( 0, $result->priority, 'ObjectStateCreateStruct priority property not created correctly.' ); - $this->assertEquals( + self::assertEquals( 'eng-GB', $result->defaultLanguageCode, 'ObjectStateCreateStruct defaultLanguageCode property not created correctly.' ); - $this->assertEquals( + self::assertEquals( ['eng-GB' => 'Test state'], $result->names, 'ObjectStateCreateStruct names property not created correctly.' ); - $this->assertEquals( + self::assertEquals( ['eng-GB' => 'Test description'], $result->descriptions, 'ObjectStateCreateStruct descriptions property not created correctly.' @@ -249,9 +250,9 @@ protected function getObjectStateServiceMock() { $objectStateServiceMock = $this->createMock(ObjectStateService::class); - $objectStateServiceMock->expects($this->any()) + $objectStateServiceMock->expects(self::any()) ->method('newObjectStateCreateStruct') - ->with($this->equalTo('test-state')) + ->with(self::equalTo('test-state')) ->willReturn( new ObjectStateCreateStruct(['identifier' => 'test-state']) ); diff --git a/tests/lib/Server/Input/Parser/ObjectStateGroupCreateTest.php b/tests/lib/Server/Input/Parser/ObjectStateGroupCreateTest.php index b485e832..1ccd6838 100644 --- a/tests/lib/Server/Input/Parser/ObjectStateGroupCreateTest.php +++ b/tests/lib/Server/Input/Parser/ObjectStateGroupCreateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\ObjectState\ObjectStateGroupCreateStruct; @@ -42,31 +43,31 @@ public function testParse() $objectStateGroupCreate = $this->getParser(); $result = $objectStateGroupCreate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( ObjectStateGroupCreateStruct::class, $result, 'ObjectStateGroupCreateStruct not created correctly.' ); - $this->assertEquals( + self::assertEquals( 'test-group', $result->identifier, 'ObjectStateGroupCreateStruct identifier property not created correctly.' ); - $this->assertEquals( + self::assertEquals( 'eng-GB', $result->defaultLanguageCode, 'ObjectStateGroupCreateStruct defaultLanguageCode property not created correctly.' ); - $this->assertEquals( + self::assertEquals( ['eng-GB' => 'Test group'], $result->names, 'ObjectStateGroupCreateStruct names property not created correctly.' ); - $this->assertEquals( + self::assertEquals( ['eng-GB' => 'Test group description'], $result->descriptions, 'ObjectStateGroupCreateStruct descriptions property not created correctly.' @@ -206,9 +207,9 @@ protected function getObjectStateServiceMock() { $objectStateServiceMock = $this->createMock(ObjectStateService::class); - $objectStateServiceMock->expects($this->any()) + $objectStateServiceMock->expects(self::any()) ->method('newObjectStateGroupCreateStruct') - ->with($this->equalTo('test-group')) + ->with(self::equalTo('test-group')) ->willReturn( new ObjectStateGroupCreateStruct(['identifier' => 'test-group']) ); diff --git a/tests/lib/Server/Input/Parser/ObjectStateGroupUpdateTest.php b/tests/lib/Server/Input/Parser/ObjectStateGroupUpdateTest.php index bf56f8b6..5c85a6df 100644 --- a/tests/lib/Server/Input/Parser/ObjectStateGroupUpdateTest.php +++ b/tests/lib/Server/Input/Parser/ObjectStateGroupUpdateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\ObjectState\ObjectStateGroupUpdateStruct; @@ -42,31 +43,31 @@ public function testParse() $objectStateGroupUpdate = $this->getParser(); $result = $objectStateGroupUpdate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( ObjectStateGroupUpdateStruct::class, $result, 'ObjectStateGroupUpdateStruct not created correctly.' ); - $this->assertEquals( + self::assertEquals( 'test-group', $result->identifier, 'ObjectStateGroupUpdateStruct identifier property not created correctly.' ); - $this->assertEquals( + self::assertEquals( 'eng-GB', $result->defaultLanguageCode, 'ObjectStateGroupUpdateStruct defaultLanguageCode property not created correctly.' ); - $this->assertEquals( + self::assertEquals( ['eng-GB' => 'Test group'], $result->names, 'ObjectStateGroupUpdateStruct names property not created correctly.' ); - $this->assertEquals( + self::assertEquals( ['eng-GB' => 'Test group description'], $result->descriptions, 'ObjectStateGroupUpdateStruct descriptions property not created correctly.' @@ -120,7 +121,7 @@ protected function getObjectStateServiceMock() { $objectStateServiceMock = $this->createMock(ObjectStateService::class); - $objectStateServiceMock->expects($this->any()) + $objectStateServiceMock->expects(self::any()) ->method('newObjectStateGroupUpdateStruct') ->willReturn( new ObjectStateGroupUpdateStruct() diff --git a/tests/lib/Server/Input/Parser/ObjectStateUpdateTest.php b/tests/lib/Server/Input/Parser/ObjectStateUpdateTest.php index b499dc98..5290f551 100644 --- a/tests/lib/Server/Input/Parser/ObjectStateUpdateTest.php +++ b/tests/lib/Server/Input/Parser/ObjectStateUpdateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\ObjectState\ObjectStateUpdateStruct; @@ -42,31 +43,31 @@ public function testParse() $objectStateUpdate = $this->getParser(); $result = $objectStateUpdate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( ObjectStateUpdateStruct::class, $result, 'ObjectStateUpdateStruct not created correctly.' ); - $this->assertEquals( + self::assertEquals( 'test-state', $result->identifier, 'ObjectStateUpdateStruct identifier property not created correctly.' ); - $this->assertEquals( + self::assertEquals( 'eng-GB', $result->defaultLanguageCode, 'ObjectStateUpdateStruct defaultLanguageCode property not created correctly.' ); - $this->assertEquals( + self::assertEquals( ['eng-GB' => 'Test state'], $result->names, 'ObjectStateUpdateStruct names property not created correctly.' ); - $this->assertEquals( + self::assertEquals( ['eng-GB' => 'Test description'], $result->descriptions, 'ObjectStateUpdateStruct descriptions property not created correctly.' @@ -120,7 +121,7 @@ protected function getObjectStateServiceMock() { $objectStateServiceMock = $this->createMock(ObjectStateService::class); - $objectStateServiceMock->expects($this->any()) + $objectStateServiceMock->expects(self::any()) ->method('newObjectStateUpdateStruct') ->willReturn( new ObjectStateUpdateStruct() diff --git a/tests/lib/Server/Input/Parser/PolicyCreateTest.php b/tests/lib/Server/Input/Parser/PolicyCreateTest.php index b628a4de..d7de8795 100644 --- a/tests/lib/Server/Input/Parser/PolicyCreateTest.php +++ b/tests/lib/Server/Input/Parser/PolicyCreateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\User\Limitation; @@ -47,19 +48,19 @@ public function testParse() $policyCreate = $this->getParser(); $result = $policyCreate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( PolicyCreateStruct::class, $result, 'PolicyCreateStruct not created correctly.' ); - $this->assertEquals( + self::assertEquals( 'content', $result->module, 'PolicyCreateStruct module property not created correctly.' ); - $this->assertEquals( + self::assertEquals( 'delete', $result->function, 'PolicyCreateStruct function property not created correctly.' @@ -67,27 +68,27 @@ public function testParse() $parsedLimitations = $result->getLimitations(); - $this->assertIsArray($parsedLimitations, 'PolicyCreateStruct limitations not created correctly'); + self::assertIsArray($parsedLimitations, 'PolicyCreateStruct limitations not created correctly'); - $this->assertCount( + self::assertCount( 1, $parsedLimitations, 'PolicyCreateStruct limitations not created correctly' ); - $this->assertInstanceOf( + self::assertInstanceOf( Limitation::class, $parsedLimitations['Class'], 'Limitation not created correctly.' ); - $this->assertEquals( + self::assertEquals( 'Class', $parsedLimitations['Class']->getIdentifier(), 'Limitation identifier not created correctly.' ); - $this->assertEquals( + self::assertEquals( [1, 2, 3], $parsedLimitations['Class']->limitationValues, 'Limitation values not created correctly.' @@ -244,11 +245,11 @@ protected function getRoleServiceMock() { $roleServiceMock = $this->createMock(RoleService::class); - $roleServiceMock->expects($this->any()) + $roleServiceMock->expects(self::any()) ->method('newPolicyCreateStruct') ->with( - $this->equalTo('content'), - $this->equalTo('delete') + self::equalTo('content'), + self::equalTo('delete') ) ->willReturn( new PolicyCreateStruct( diff --git a/tests/lib/Server/Input/Parser/PolicyUpdateTest.php b/tests/lib/Server/Input/Parser/PolicyUpdateTest.php index 79d7dd03..8b05fe7e 100644 --- a/tests/lib/Server/Input/Parser/PolicyUpdateTest.php +++ b/tests/lib/Server/Input/Parser/PolicyUpdateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\User\Limitation; @@ -45,7 +46,7 @@ public function testParse() $policyUpdate = $this->getParser(); $result = $policyUpdate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( PolicyUpdateStruct::class, $result, 'PolicyUpdateStruct not created correctly.' @@ -53,27 +54,27 @@ public function testParse() $parsedLimitations = $result->getLimitations(); - $this->assertIsArray($parsedLimitations, 'PolicyUpdateStruct limitations not created correctly'); + self::assertIsArray($parsedLimitations, 'PolicyUpdateStruct limitations not created correctly'); - $this->assertCount( + self::assertCount( 1, $parsedLimitations, 'PolicyUpdateStruct limitations not created correctly' ); - $this->assertInstanceOf( + self::assertInstanceOf( Limitation::class, $parsedLimitations['Class'], 'Limitation not created correctly.' ); - $this->assertEquals( + self::assertEquals( 'Class', $parsedLimitations['Class']->getIdentifier(), 'Limitation identifier not created correctly.' ); - $this->assertEquals( + self::assertEquals( [1, 2, 3], $parsedLimitations['Class']->limitationValues, 'Limitation values not created correctly.' @@ -156,7 +157,7 @@ protected function getRoleServiceMock() { $roleServiceMock = $this->createMock(RoleService::class); - $roleServiceMock->expects($this->any()) + $roleServiceMock->expects(self::any()) ->method('newPolicyUpdateStruct') ->willReturn( new PolicyUpdateStruct() diff --git a/tests/lib/Server/Input/Parser/QueryParserTest.php b/tests/lib/Server/Input/Parser/QueryParserTest.php index d010b505..74838f6f 100644 --- a/tests/lib/Server/Input/Parser/QueryParserTest.php +++ b/tests/lib/Server/Input/Parser/QueryParserTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\Content\Query; @@ -25,7 +26,7 @@ public function testParseEmptyQuery() $expectedQuery = new Query(); - $this->assertEquals($expectedQuery, $result); + self::assertEquals($expectedQuery, $result); } public function testDispatchOneFilter() @@ -37,7 +38,7 @@ public function testDispatchOneFilter() $parsingDispatcher = $this->getParsingDispatcherMock(); $parsingDispatcher - ->expects($this->once()) + ->expects(self::once()) ->method('parse') ->with(['ContentTypeIdentifierCriterion' => 'article']) ->willReturn(new Query\Criterion\ContentTypeIdentifier('article')); @@ -49,7 +50,7 @@ public function testDispatchOneFilter() $expectedQuery = new Query(); $expectedQuery->filter = new Query\Criterion\ContentTypeIdentifier('article'); - $this->assertEquals($expectedQuery, $result); + self::assertEquals($expectedQuery, $result); } public function testDispatchMoreThanOneFilter() @@ -61,12 +62,12 @@ public function testDispatchMoreThanOneFilter() $parsingDispatcher = $this->getParsingDispatcherMock(); $parsingDispatcher - ->expects($this->at(0)) + ->expects(self::at(0)) ->method('parse') ->with(['ContentTypeIdentifierCriterion' => 'article']) ->willReturn(new Query\Criterion\ContentTypeIdentifier('article')); $parsingDispatcher - ->expects($this->at(1)) + ->expects(self::at(1)) ->method('parse') ->with(['ParentLocationIdCriterion' => 762]) ->willReturn(new Query\Criterion\ParentLocationId(762)); @@ -81,7 +82,7 @@ public function testDispatchMoreThanOneFilter() new Query\Criterion\ParentLocationId(762), ]); - $this->assertEquals($expectedQuery, $result); + self::assertEquals($expectedQuery, $result); } public function testDispatchOneQueryItem() @@ -93,7 +94,7 @@ public function testDispatchOneQueryItem() $parsingDispatcher = $this->getParsingDispatcherMock(); $parsingDispatcher - ->expects($this->once()) + ->expects(self::once()) ->method('parse') ->with(['ContentTypeIdentifierCriterion' => 'article']) ->willReturn(new Query\Criterion\ContentTypeIdentifier('article')); @@ -105,7 +106,7 @@ public function testDispatchOneQueryItem() $expectedQuery = new Query(); $expectedQuery->query = new Query\Criterion\ContentTypeIdentifier('article'); - $this->assertEquals($expectedQuery, $result); + self::assertEquals($expectedQuery, $result); } public function testDispatchMoreThanOneQueryItem() @@ -117,12 +118,12 @@ public function testDispatchMoreThanOneQueryItem() $parsingDispatcher = $this->getParsingDispatcherMock(); $parsingDispatcher - ->expects($this->at(0)) + ->expects(self::at(0)) ->method('parse') ->with(['ContentTypeIdentifierCriterion' => 'article']) ->willReturn(new Query\Criterion\ContentTypeIdentifier('article')); $parsingDispatcher - ->expects($this->at(1)) + ->expects(self::at(1)) ->method('parse') ->with(['ParentLocationIdCriterion' => 762]) ->willReturn(new Query\Criterion\ParentLocationId(762)); @@ -137,7 +138,7 @@ public function testDispatchMoreThanOneQueryItem() new Query\Criterion\ParentLocationId(762), ]); - $this->assertEquals($expectedQuery, $result); + self::assertEquals($expectedQuery, $result); } /** diff --git a/tests/lib/Server/Input/Parser/RelationCreateTest.php b/tests/lib/Server/Input/Parser/RelationCreateTest.php index fa323d29..327c6709 100644 --- a/tests/lib/Server/Input/Parser/RelationCreateTest.php +++ b/tests/lib/Server/Input/Parser/RelationCreateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Rest\Exceptions\Parser; @@ -25,7 +26,7 @@ public function testParse() $relationCreate = $this->getParser(); $result = $relationCreate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertEquals( + self::assertEquals( 42, $result, 'RelationCreate struct not parsed correctly.' diff --git a/tests/lib/Server/Input/Parser/RoleAssignInputTest.php b/tests/lib/Server/Input/Parser/RoleAssignInputTest.php index b4d13e3d..c6d53cf3 100644 --- a/tests/lib/Server/Input/Parser/RoleAssignInputTest.php +++ b/tests/lib/Server/Input/Parser/RoleAssignInputTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\RoleLimitation; @@ -32,7 +33,7 @@ public function testParse() ]; $this->getParsingDispatcherMock() - ->expects($this->once()) + ->expects(self::once()) ->method('parse') ->with($limitation, 'application/vnd.ibexa.api.internal.limitation.Section') ->willReturn(new SectionLimitation()); @@ -40,19 +41,19 @@ public function testParse() $roleAssignInput = $this->getParser(); $result = $roleAssignInput->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( RoleAssignment::class, $result, 'RoleAssignment not created correctly.' ); - $this->assertEquals( + self::assertEquals( '42', $result->roleId, 'RoleAssignment roleId property not created correctly.' ); - $this->assertInstanceOf( + self::assertInstanceOf( RoleLimitation::class, $result->limitation, 'Limitation not created correctly.' diff --git a/tests/lib/Server/Input/Parser/RoleInputTest.php b/tests/lib/Server/Input/Parser/RoleInputTest.php index 71c4aa82..0f077086 100644 --- a/tests/lib/Server/Input/Parser/RoleInputTest.php +++ b/tests/lib/Server/Input/Parser/RoleInputTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Core\Repository\RoleService; @@ -43,13 +44,13 @@ public function testParse() $roleInput = $this->getParser(); $result = $roleInput->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( RoleCreateStruct::class, $result, 'RoleCreateStruct not created correctly.' ); - $this->assertEquals( + self::assertEquals( 'Identifier Bar', $result->identifier, 'RoleCreateStruct identifier property not created correctly.' @@ -92,9 +93,9 @@ protected function getRoleServiceMock() { $roleServiceMock = $this->createMock(RoleService::class); - $roleServiceMock->expects($this->any()) + $roleServiceMock->expects(self::any()) ->method('newRoleCreateStruct') - ->with($this->equalTo('Identifier Bar')) + ->with(self::equalTo('Identifier Bar')) ->willReturn( new RoleCreateStruct(['identifier' => 'Identifier Bar']) ); diff --git a/tests/lib/Server/Input/Parser/SectionInputTest.php b/tests/lib/Server/Input/Parser/SectionInputTest.php index 7d50ea4a..f1c09c5a 100644 --- a/tests/lib/Server/Input/Parser/SectionInputTest.php +++ b/tests/lib/Server/Input/Parser/SectionInputTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\Content\SectionCreateStruct; @@ -26,7 +27,7 @@ public function testParse() $sectionInput = $this->getParser(); $result = $sectionInput->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertEquals( + self::assertEquals( new SectionCreateStruct($inputArray), $result, 'SectionCreateStruct not created correctly.' @@ -84,7 +85,7 @@ protected function getSectionServiceMock() { $sectionServiceMock = $this->createMock(SectionService::class); - $sectionServiceMock->expects($this->any()) + $sectionServiceMock->expects(self::any()) ->method('newSectionCreateStruct') ->willReturn( new SectionCreateStruct() diff --git a/tests/lib/Server/Input/Parser/SessionInputTest.php b/tests/lib/Server/Input/Parser/SessionInputTest.php index 7cf5ef8f..0faabea7 100644 --- a/tests/lib/Server/Input/Parser/SessionInputTest.php +++ b/tests/lib/Server/Input/Parser/SessionInputTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Rest\Exceptions\Parser; @@ -25,7 +26,7 @@ public function testParse() $sessionInput = $this->getParser(); $result = $sessionInput->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertEquals( + self::assertEquals( new SessionInputValue($inputArray), $result, 'SessionInput not created correctly.' diff --git a/tests/lib/Server/Input/Parser/SortClause/DataKeyValueObjectClassTest.php b/tests/lib/Server/Input/Parser/SortClause/DataKeyValueObjectClassTest.php index 349bf560..5c4ba271 100644 --- a/tests/lib/Server/Input/Parser/SortClause/DataKeyValueObjectClassTest.php +++ b/tests/lib/Server/Input/Parser/SortClause/DataKeyValueObjectClassTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser\SortClause; use Ibexa\Contracts\Core\Repository\Values\Content\Query; @@ -26,7 +27,7 @@ public function testParse() $dataKeyValueObjectClass = $this->getParser(); $result = $dataKeyValueObjectClass->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertEquals( + self::assertEquals( new DatePublished(Query::SORT_ASC), $result, 'DataKeyValueObjectClass parser not created correctly.' diff --git a/tests/lib/Server/Input/Parser/SortClause/FieldTest.php b/tests/lib/Server/Input/Parser/SortClause/FieldTest.php index cae9b4c4..40b7de7a 100644 --- a/tests/lib/Server/Input/Parser/SortClause/FieldTest.php +++ b/tests/lib/Server/Input/Parser/SortClause/FieldTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser\SortClause; use Ibexa\Contracts\Core\Repository\Values\Content\Query; @@ -29,7 +30,7 @@ public function testParse() $fieldParser = $this->getParser(); $result = $fieldParser->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertEquals( + self::assertEquals( new Field('content', 'field', Query::SORT_ASC), $result, 'Field parser not created correctly.' diff --git a/tests/lib/Server/Input/Parser/URLWildcardCreateTest.php b/tests/lib/Server/Input/Parser/URLWildcardCreateTest.php index aac314c0..ca29acfd 100644 --- a/tests/lib/Server/Input/Parser/URLWildcardCreateTest.php +++ b/tests/lib/Server/Input/Parser/URLWildcardCreateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Rest\Exceptions\Parser; @@ -25,7 +26,7 @@ public function testParse() $urlWildcardCreate = $this->getParser(); $result = $urlWildcardCreate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertEquals( + self::assertEquals( [ 'sourceUrl' => '/source/url', 'destinationUrl' => '/destination/url', diff --git a/tests/lib/Server/Input/Parser/UserCreateTest.php b/tests/lib/Server/Input/Parser/UserCreateTest.php index fede1784..411dd2af 100644 --- a/tests/lib/Server/Input/Parser/UserCreateTest.php +++ b/tests/lib/Server/Input/Parser/UserCreateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\ContentService; @@ -51,44 +52,44 @@ public function testParse() $userCreate = $this->getParser(); $result = $userCreate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( UserCreateStruct::class, $result, 'UserCreateStruct not created correctly.' ); - $this->assertInstanceOf( + self::assertInstanceOf( ContentType::class, $result->contentType, 'contentType not created correctly.' ); - $this->assertEquals( + self::assertEquals( 4, $result->contentType->id, 'contentType not created correctly' ); - $this->assertEquals( + self::assertEquals( 'eng-US', $result->mainLanguageCode, 'mainLanguageCode not created correctly' ); - $this->assertEquals( + self::assertEquals( 4, $result->sectionId, 'sectionId not created correctly' ); - $this->assertEquals( + self::assertEquals( 'remoteId12345678', $result->remoteId, 'remoteId not created correctly' ); foreach ($result->fields as $field) { - $this->assertEquals( + self::assertEquals( 'foo', $field->value, 'field value not created correctly' @@ -456,7 +457,7 @@ private function getFieldTypeParserMock() ) ->getMock(); - $fieldTypeParserMock->expects($this->any()) + $fieldTypeParserMock->expects(self::any()) ->method('parseValue') ->with('ezstring', []) ->willReturn('foo'); @@ -474,14 +475,14 @@ protected function getUserServiceMock() $userServiceMock = $this->createMock(UserService::class); $contentType = $this->getContentType(); - $userServiceMock->expects($this->any()) + $userServiceMock->expects(self::any()) ->method('newUserCreateStruct') ->with( - $this->equalTo('login'), - $this->equalTo('admin@link.invalid'), - $this->equalTo('password'), - $this->equalTo('eng-US'), - $this->equalTo($contentType) + self::equalTo('login'), + self::equalTo('admin@link.invalid'), + self::equalTo('password'), + self::equalTo('eng-US'), + self::equalTo($contentType) ) ->willReturn( new UserCreateStruct( @@ -504,9 +505,9 @@ protected function getContentTypeServiceMock() { $contentTypeServiceMock = $this->createMock(ContentTypeService::class); - $contentTypeServiceMock->expects($this->any()) + $contentTypeServiceMock->expects(self::any()) ->method('loadContentType') - ->with($this->equalTo(4)) + ->with(self::equalTo(4)) ->willReturn($this->getContentType()); return $contentTypeServiceMock; diff --git a/tests/lib/Server/Input/Parser/UserGroupCreateTest.php b/tests/lib/Server/Input/Parser/UserGroupCreateTest.php index 88c70ad1..ff5d209c 100644 --- a/tests/lib/Server/Input/Parser/UserGroupCreateTest.php +++ b/tests/lib/Server/Input/Parser/UserGroupCreateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\ContentService; @@ -47,44 +48,44 @@ public function testParse() $userGroupCreate = $this->getParser(); $result = $userGroupCreate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( UserGroupCreateStruct::class, $result, 'UserGroupCreateStruct not created correctly.' ); - $this->assertInstanceOf( + self::assertInstanceOf( \Ibexa\Contracts\Core\Repository\Values\ContentType\ContentType::class, $result->contentType, 'contentType not created correctly.' ); - $this->assertEquals( + self::assertEquals( 3, $result->contentType->id, 'contentType not created correctly' ); - $this->assertEquals( + self::assertEquals( 'eng-US', $result->mainLanguageCode, 'mainLanguageCode not created correctly' ); - $this->assertEquals( + self::assertEquals( 4, $result->sectionId, 'sectionId not created correctly' ); - $this->assertEquals( + self::assertEquals( 'remoteId12345678', $result->remoteId, 'remoteId not created correctly' ); foreach ($result->fields as $field) { - $this->assertEquals( + self::assertEquals( 'foo', $field->value, 'field value not created correctly' @@ -324,7 +325,7 @@ private function getFieldTypeParserMock() ) ->getMock(); - $fieldTypeParserMock->expects($this->any()) + $fieldTypeParserMock->expects(self::any()) ->method('parseValue') ->with('ezstring', []) ->willReturn('foo'); @@ -342,11 +343,11 @@ protected function getUserServiceMock() $userServiceMock = $this->createMock(UserService::class); $contentType = $this->getContentType(); - $userServiceMock->expects($this->any()) + $userServiceMock->expects(self::any()) ->method('newUserGroupCreateStruct') ->with( - $this->equalTo('eng-US'), - $this->equalTo($contentType) + self::equalTo('eng-US'), + self::equalTo($contentType) ) ->willReturn( new UserGroupCreateStruct( @@ -369,9 +370,9 @@ protected function getContentTypeServiceMock() { $contentTypeServiceMock = $this->createMock(ContentTypeService::class); - $contentTypeServiceMock->expects($this->any()) + $contentTypeServiceMock->expects(self::any()) ->method('loadContentType') - ->with($this->equalTo(3)) + ->with(self::equalTo(3)) ->willReturn($this->getContentType()); return $contentTypeServiceMock; diff --git a/tests/lib/Server/Input/Parser/UserGroupUpdateTest.php b/tests/lib/Server/Input/Parser/UserGroupUpdateTest.php index 7e1b0302..f1e14a74 100644 --- a/tests/lib/Server/Input/Parser/UserGroupUpdateTest.php +++ b/tests/lib/Server/Input/Parser/UserGroupUpdateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; @@ -48,44 +49,44 @@ public function testParse() $userGroupUpdate = $this->getParser(); $result = $userGroupUpdate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( RestUserGroupUpdateStruct::class, $result, 'UserGroupUpdate not created correctly.' ); - $this->assertInstanceOf( + self::assertInstanceOf( ContentUpdateStruct::class, $result->userGroupUpdateStruct->contentUpdateStruct, 'UserGroupUpdate not created correctly.' ); - $this->assertInstanceOf( + self::assertInstanceOf( ContentMetadataUpdateStruct::class, $result->userGroupUpdateStruct->contentMetadataUpdateStruct, 'UserGroupUpdate not created correctly.' ); - $this->assertEquals( + self::assertEquals( 1, $result->sectionId, 'sectionId not created correctly' ); - $this->assertEquals( + self::assertEquals( 'eng-US', $result->userGroupUpdateStruct->contentMetadataUpdateStruct->mainLanguageCode, 'mainLanguageCode not created correctly' ); - $this->assertEquals( + self::assertEquals( 'remoteId123456', $result->userGroupUpdateStruct->contentMetadataUpdateStruct->remoteId, 'remoteId not created correctly' ); foreach ($result->userGroupUpdateStruct->contentUpdateStruct->fields as $field) { - $this->assertEquals( + self::assertEquals( 'foo', $field->value, 'field value not created correctly' @@ -228,7 +229,7 @@ private function getFieldTypeParserMock() ) ->getMock(); - $fieldTypeParserMock->expects($this->any()) + $fieldTypeParserMock->expects(self::any()) ->method('parseFieldValue') ->with(4, 'name', []) ->willReturn('foo'); @@ -245,7 +246,7 @@ protected function getUserServiceMock() { $userServiceMock = $this->createMock(UserService::class); - $userServiceMock->expects($this->any()) + $userServiceMock->expects(self::any()) ->method('newUserGroupUpdateStruct') ->willReturn( new UserGroupUpdateStruct() @@ -263,9 +264,9 @@ protected function getLocationServiceMock() { $userServiceMock = $this->createMock(LocationService::class); - $userServiceMock->expects($this->any()) + $userServiceMock->expects(self::any()) ->method('loadLocation') - ->with($this->equalTo(5)) + ->with(self::equalTo(5)) ->willReturn( new Location( [ @@ -290,13 +291,13 @@ protected function getContentServiceMock() { $contentServiceMock = $this->createMock(ContentService::class); - $contentServiceMock->expects($this->any()) + $contentServiceMock->expects(self::any()) ->method('newContentUpdateStruct') ->willReturn( new ContentUpdateStruct() ); - $contentServiceMock->expects($this->any()) + $contentServiceMock->expects(self::any()) ->method('newContentMetadataUpdateStruct') ->willReturn( new ContentMetadataUpdateStruct() diff --git a/tests/lib/Server/Input/Parser/UserUpdateTest.php b/tests/lib/Server/Input/Parser/UserUpdateTest.php index 0b9e2c87..8da3e4fd 100644 --- a/tests/lib/Server/Input/Parser/UserUpdateTest.php +++ b/tests/lib/Server/Input/Parser/UserUpdateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\ContentTypeService; @@ -48,61 +49,61 @@ public function testParse() $userUpdate = $this->getParser(); $result = $userUpdate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( RestUserUpdateStruct::class, $result, 'UserUpdate not created correctly.' ); - $this->assertInstanceOf( + self::assertInstanceOf( ContentUpdateStruct::class, $result->userUpdateStruct->contentUpdateStruct, 'UserUpdate not created correctly.' ); - $this->assertInstanceOf( + self::assertInstanceOf( ContentMetadataUpdateStruct::class, $result->userUpdateStruct->contentMetadataUpdateStruct, 'UserUpdate not created correctly.' ); - $this->assertEquals( + self::assertEquals( 1, $result->sectionId, 'sectionId not created correctly' ); - $this->assertEquals( + self::assertEquals( 'eng-US', $result->userUpdateStruct->contentMetadataUpdateStruct->mainLanguageCode, 'mainLanguageCode not created correctly' ); - $this->assertEquals( + self::assertEquals( 'remoteId123456', $result->userUpdateStruct->contentMetadataUpdateStruct->remoteId, 'remoteId not created correctly' ); - $this->assertEquals( + self::assertEquals( 'admin@link.invalid', $result->userUpdateStruct->email, 'email not created correctly' ); - $this->assertEquals( + self::assertEquals( 'somePassword', $result->userUpdateStruct->password, 'password not created correctly' ); - $this->assertTrue( + self::assertTrue( $result->userUpdateStruct->enabled, 'enabled not created correctly' ); foreach ($result->userUpdateStruct->contentUpdateStruct->fields as $field) { - $this->assertEquals( + self::assertEquals( 'foo', $field->value, 'field value not created correctly' @@ -257,7 +258,7 @@ private function getFieldTypeParserMock() ) ->getMock(); - $fieldTypeParserMock->expects($this->any()) + $fieldTypeParserMock->expects(self::any()) ->method('parseFieldValue') ->with(14, 'first_name', []) ->willReturn('foo'); @@ -274,7 +275,7 @@ protected function getUserServiceMock() { $userServiceMock = $this->createMock(UserService::class); - $userServiceMock->expects($this->any()) + $userServiceMock->expects(self::any()) ->method('newUserUpdateStruct') ->willReturn( new UserUpdateStruct() @@ -292,13 +293,13 @@ protected function getContentServiceMock() { $contentServiceMock = $this->createMock(ContentService::class); - $contentServiceMock->expects($this->any()) + $contentServiceMock->expects(self::any()) ->method('newContentUpdateStruct') ->willReturn( new ContentUpdateStruct() ); - $contentServiceMock->expects($this->any()) + $contentServiceMock->expects(self::any()) ->method('newContentMetadataUpdateStruct') ->willReturn( new ContentMetadataUpdateStruct() diff --git a/tests/lib/Server/Input/Parser/VersionUpdateTest.php b/tests/lib/Server/Input/Parser/VersionUpdateTest.php index d317648d..c65db6c6 100644 --- a/tests/lib/Server/Input/Parser/VersionUpdateTest.php +++ b/tests/lib/Server/Input/Parser/VersionUpdateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\ContentTypeService; @@ -37,20 +38,20 @@ public function testParse() $VersionUpdate = $this->getParser(); $result = $VersionUpdate->parse($inputArray, $this->getParsingDispatcherMock()); - $this->assertInstanceOf( + self::assertInstanceOf( ContentUpdateStruct::class, $result, 'VersionUpdate not created correctly.' ); - $this->assertEquals( + self::assertEquals( 'eng-US', $result->initialLanguageCode, 'initialLanguageCode not created correctly' ); foreach ($result->fields as $field) { - $this->assertEquals( + self::assertEquals( 'foo', $field->value, 'field value not created correctly' @@ -153,7 +154,7 @@ private function getFieldTypeParserMock() ) ->getMock(); - $fieldTypeParserMock->expects($this->any()) + $fieldTypeParserMock->expects(self::any()) ->method('parseFieldValue') ->with(42, 'subject', []) ->willReturn('foo'); @@ -170,7 +171,7 @@ protected function getContentServiceMock() { $contentServiceMock = $this->createMock(ContentService::class); - $contentServiceMock->expects($this->any()) + $contentServiceMock->expects(self::any()) ->method('newContentUpdateStruct') ->willReturn( new ContentUpdateStruct() diff --git a/tests/lib/Server/Input/Parser/ViewInputOneDotOneTest.php b/tests/lib/Server/Input/Parser/ViewInputOneDotOneTest.php index 22ed77c5..c09f7326 100644 --- a/tests/lib/Server/Input/Parser/ViewInputOneDotOneTest.php +++ b/tests/lib/Server/Input/Parser/ViewInputOneDotOneTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\Content\LocationQuery; @@ -27,7 +28,7 @@ public function testParseContentQuery() $parser = $this->getParser(); $parsingDispatcher = $this->getParsingDispatcherMock(); $parsingDispatcher - ->expects($this->once()) + ->expects(self::once()) ->method('parse') ->with($inputArray['ContentQuery'], 'application/vnd.ibexa.api.internal.ContentQuery') ->willReturn(new Query()); @@ -38,7 +39,7 @@ public function testParseContentQuery() $expectedViewInput->identifier = 'Query identifier'; $expectedViewInput->query = new Query(); - $this->assertEquals($expectedViewInput, $result, 'RestViewInput not created correctly.'); + self::assertEquals($expectedViewInput, $result, 'RestViewInput not created correctly.'); } /** @@ -54,7 +55,7 @@ public function testParseLocationQuery() $parser = $this->getParser(); $parsingDispatcher = $this->getParsingDispatcherMock(); $parsingDispatcher - ->expects($this->once()) + ->expects(self::once()) ->method('parse') ->with($inputArray['LocationQuery'], 'application/vnd.ibexa.api.internal.LocationQuery') ->willReturn(new LocationQuery()); @@ -65,7 +66,7 @@ public function testParseLocationQuery() $expectedViewInput->identifier = 'Query identifier'; $expectedViewInput->query = new LocationQuery(); - $this->assertEquals($expectedViewInput, $result, 'RestViewInput not created correctly.'); + self::assertEquals($expectedViewInput, $result, 'RestViewInput not created correctly.'); } public function testThrowsExceptionOnMissingIdentifier() diff --git a/tests/lib/Server/Input/Parser/ViewInputTest.php b/tests/lib/Server/Input/Parser/ViewInputTest.php index 6a99ea8a..da395fb2 100644 --- a/tests/lib/Server/Input/Parser/ViewInputTest.php +++ b/tests/lib/Server/Input/Parser/ViewInputTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Input\Parser; use Ibexa\Contracts\Core\Repository\Values\Content\Query; @@ -25,7 +26,7 @@ public function testParse() $parser = $this->getParser(); $parsingDispatcher = $this->getParsingDispatcherMock(); $parsingDispatcher - ->expects($this->once()) + ->expects(self::once()) ->method('parse') ->with($inputArray['Query'], 'application/vnd.ibexa.api.internal.ContentQuery') ->willReturn(new Query()); @@ -36,7 +37,7 @@ public function testParse() $expectedViewInput->identifier = 'Query identifier'; $expectedViewInput->query = new Query(); - $this->assertEquals($expectedViewInput, $result, 'RestViewInput not created correctly.'); + self::assertEquals($expectedViewInput, $result, 'RestViewInput not created correctly.'); } public function testThrowsExceptionOnMissingIdentifier() diff --git a/tests/lib/Server/Output/ValueObjectVisitor/BadRequestExceptionTest.php b/tests/lib/Server/Output/ValueObjectVisitor/BadRequestExceptionTest.php index 6e4ccad9..8a708748 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/BadRequestExceptionTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/BadRequestExceptionTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Rest\Server\Exceptions; diff --git a/tests/lib/Server/Output/ValueObjectVisitor/BadStateExceptionTest.php b/tests/lib/Server/Output/ValueObjectVisitor/BadStateExceptionTest.php index 95743953..4b1c02a5 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/BadStateExceptionTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/BadStateExceptionTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Exceptions\BadStateException; diff --git a/tests/lib/Server/Output/ValueObjectVisitor/BookmarkListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/BookmarkListTest.php index 8cb57b00..617fd8e6 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/BookmarkListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/BookmarkListTest.php @@ -47,7 +47,7 @@ public function testVisit(): string $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -94,7 +94,7 @@ public function testResultContainsBookmarkElement(string $result): void $document->loadXML($result); $xpath = new DOMXPath($document); - $this->assertEquals(count($this->data->items), $xpath->query($query)->length); + self::assertEquals(count($this->data->items), $xpath->query($query)->length); } /** diff --git a/tests/lib/Server/Output/ValueObjectVisitor/CachedValueTest.php b/tests/lib/Server/Output/ValueObjectVisitor/CachedValueTest.php index 859fe80d..05b9eeb2 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/CachedValueTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/CachedValueTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\SiteAccess\ConfigResolverInterface; @@ -38,10 +39,10 @@ public function setUp(): void public function testVisit() { $responseMock = $this->getResponseMock(); - $responseMock->expects($this->once())->method('setPublic'); - $responseMock->expects($this->at(1))->method('setVary')->with('Accept'); - $responseMock->expects($this->once())->method('setSharedMaxAge')->with($this->defaultOptions['content.default_ttl']); - $responseMock->expects($this->at(3))->method('setVary')->with('X-User-Hash', false); + $responseMock->expects(self::once())->method('setPublic'); + $responseMock->expects(self::at(1))->method('setVary')->with('Accept'); + $responseMock->expects(self::once())->method('setSharedMaxAge')->with($this->defaultOptions['content.default_ttl']); + $responseMock->expects(self::at(3))->method('setVary')->with('X-User-Hash', false); $result = $this->visit(new CachedValue(new stdClass())); @@ -51,10 +52,10 @@ public function testVisit() public function testVisitLocationCache() { $responseMock = $this->getResponseMock(); - $responseMock->expects($this->once())->method('setPublic'); - $responseMock->expects($this->at(1))->method('setVary')->with('Accept'); - $responseMock->expects($this->once())->method('setSharedMaxAge')->with($this->defaultOptions['content.default_ttl']); - $responseMock->expects($this->at(3))->method('setVary')->with('X-User-Hash', false); + $responseMock->expects(self::once())->method('setPublic'); + $responseMock->expects(self::at(1))->method('setVary')->with('Accept'); + $responseMock->expects(self::once())->method('setSharedMaxAge')->with($this->defaultOptions['content.default_ttl']); + $responseMock->expects(self::at(3))->method('setVary')->with('X-User-Hash', false); $result = $this->visit(new CachedValue(new stdClass(), ['locationId' => 'testLocationId'])); @@ -66,10 +67,10 @@ public function testVisitNoUserHash() $this->request->headers->remove('X-User-Hash'); $responseMock = $this->getResponseMock(); - $responseMock->expects($this->once())->method('setPublic'); + $responseMock->expects(self::once())->method('setPublic'); // no Vary header on X-User-Hash - $responseMock->expects($this->once())->method('setVary')->with('Accept'); - $responseMock->expects($this->once())->method('setSharedMaxAge')->with($this->defaultOptions['content.default_ttl']); + $responseMock->expects(self::once())->method('setVary')->with('Accept'); + $responseMock->expects(self::once())->method('setSharedMaxAge')->with($this->defaultOptions['content.default_ttl']); $result = $this->visit(new CachedValue(new stdClass())); @@ -81,9 +82,9 @@ public function testVisitNoRequest() $this->request = null; $responseMock = $this->getResponseMock(); - $responseMock->expects($this->once())->method('setPublic'); - $responseMock->expects($this->once())->method('setVary')->with('Accept'); - $responseMock->expects($this->once())->method('setSharedMaxAge')->with($this->defaultOptions['content.default_ttl']); + $responseMock->expects(self::once())->method('setPublic'); + $responseMock->expects(self::once())->method('setVary')->with('Accept'); + $responseMock->expects(self::once())->method('setSharedMaxAge')->with($this->defaultOptions['content.default_ttl']); $result = $this->visit(new CachedValue(new stdClass())); @@ -95,7 +96,7 @@ public function testVisitViewCacheDisabled() // disable caching globally $this->options = array_merge($this->defaultOptions, ['content.view_cache' => false]); - $this->getResponseMock()->expects($this->never())->method('setPublic'); + $this->getResponseMock()->expects(self::never())->method('setPublic'); $result = $this->visit(new CachedValue(new stdClass())); @@ -108,9 +109,9 @@ public function testVisitCacheTTLCacheDisabled() $this->options = array_merge($this->defaultOptions, ['content.ttl_cache' => false]); $responseMock = $this->getResponseMock(); - $responseMock->expects($this->once())->method('setPublic'); - $responseMock->expects($this->once())->method('setVary')->with('Accept'); - $responseMock->expects($this->never())->method('setSharedMaxAge'); + $responseMock->expects(self::once())->method('setPublic'); + $responseMock->expects(self::once())->method('setVary')->with('Accept'); + $responseMock->expects(self::never())->method('setSharedMaxAge'); $result = $this->visit(new CachedValue(new stdClass())); @@ -119,7 +120,7 @@ public function testVisitCacheTTLCacheDisabled() protected function visit($value) { - $this->getVisitorMock()->expects($this->once())->method('visitValueObject')->with($value->value); + $this->getVisitorMock()->expects(self::once())->method('visitValueObject')->with($value->value); $visitor = $this->getVisitor(); $generator = $this->getGenerator(); @@ -163,7 +164,7 @@ protected function getConfigProviderMock() $mock = $this->createMock(ConfigResolverInterface::class); $mock - ->expects($this->any()) + ->expects(self::any()) ->method('hasParameter') ->willReturnCallback( static function ($parameterName) use ($options) { @@ -171,7 +172,7 @@ static function ($parameterName) use ($options) { } ); $mock - ->expects($this->any()) + ->expects(self::any()) ->method('getParameter') ->willReturnCallback( static function ($parameterName, $defaultValue) use ($options) { diff --git a/tests/lib/Server/Output/ValueObjectVisitor/ConflictTest.php b/tests/lib/Server/Output/ValueObjectVisitor/ConflictTest.php index 8bd66f20..48770a12 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/ConflictTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/ConflictTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Rest\Server\Output\ValueObjectVisitor; @@ -26,9 +27,9 @@ public function testVisit() $noContent = new Values\Conflict(); - $this->getVisitorMock()->expects($this->once()) + $this->getVisitorMock()->expects(self::once()) ->method('setStatus') - ->with($this->equalTo(409)); + ->with(self::equalTo(409)); $visitor->visit( $this->getVisitorMock(), @@ -36,7 +37,7 @@ public function testVisit() $noContent ); - $this->assertTrue($generator->isEmpty()); + self::assertTrue($generator->isEmpty()); } /** diff --git a/tests/lib/Server/Output/ValueObjectVisitor/ContentFieldValidationExceptionTest.php b/tests/lib/Server/Output/ValueObjectVisitor/ContentFieldValidationExceptionTest.php index c590aa16..adfb6789 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/ContentFieldValidationExceptionTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/ContentFieldValidationExceptionTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Core\Base\Exceptions\ContentFieldValidationException as CoreContentFieldValidationException; @@ -37,7 +38,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } diff --git a/tests/lib/Server/Output/ValueObjectVisitor/ContentListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/ContentListTest.php index f188aa01..08da1b9b 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/ContentListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/ContentListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; @@ -42,7 +43,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -107,9 +108,9 @@ public function testContentListVisitsChildren() 2 ); - $this->getVisitorMock()->expects($this->exactly(2)) + $this->getVisitorMock()->expects(self::exactly(2)) ->method('visitValueObject') - ->with($this->isInstanceOf(RestContent::class)); + ->with(self::isInstanceOf(RestContent::class)); $visitor->visit( $this->getVisitorMock(), diff --git a/tests/lib/Server/Output/ValueObjectVisitor/ContentObjectStatesTest.php b/tests/lib/Server/Output/ValueObjectVisitor/ContentObjectStatesTest.php index 74fa39ad..ae7d759d 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/ContentObjectStatesTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/ContentObjectStatesTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Rest\Output\ValueObjectVisitor; @@ -35,7 +36,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } diff --git a/tests/lib/Server/Output/ValueObjectVisitor/ContentTypeGroupListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/ContentTypeGroupListTest.php index a4511257..bcb2c640 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/ContentTypeGroupListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/ContentTypeGroupListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\ContentType\ContentTypeGroup; @@ -38,7 +39,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -102,9 +103,9 @@ public function testContentTypeGroupListVisitsChildren() ] ); - $this->getVisitorMock()->expects($this->exactly(2)) + $this->getVisitorMock()->expects(self::exactly(2)) ->method('visitValueObject') - ->with($this->isInstanceOf(ContentTypeGroup::class)); + ->with(self::isInstanceOf(ContentTypeGroup::class)); $visitor->visit( $this->getVisitorMock(), diff --git a/tests/lib/Server/Output/ValueObjectVisitor/ContentTypeGroupRefListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/ContentTypeGroupRefListTest.php index 7b5b4517..c9fa8a9e 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/ContentTypeGroupRefListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/ContentTypeGroupRefListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Core\Repository\Values\ContentType\ContentType; @@ -93,7 +94,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); $dom = new \DOMDocument(); $dom->loadXml($result); diff --git a/tests/lib/Server/Output/ValueObjectVisitor/ContentTypeGroupTest.php b/tests/lib/Server/Output/ValueObjectVisitor/ContentTypeGroupTest.php index f391e398..a7cd5c1c 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/ContentTypeGroupTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/ContentTypeGroupTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Core\Repository\Values\ContentType; @@ -80,7 +81,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } diff --git a/tests/lib/Server/Output/ValueObjectVisitor/ContentTypeInfoListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/ContentTypeInfoListTest.php index e19f92bb..186fbf6a 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/ContentTypeInfoListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/ContentTypeInfoListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Core\Repository\Values\ContentType; @@ -36,7 +37,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -109,9 +110,9 @@ public function testContentTypeInfoListVisitsChildren() '/content/typegroups/2/types' ); - $this->getVisitorMock()->expects($this->exactly(2)) + $this->getVisitorMock()->expects(self::exactly(2)) ->method('visitValueObject') - ->with($this->isInstanceOf(RestContentType::class)); + ->with(self::isInstanceOf(RestContentType::class)); $visitor->visit( $this->getVisitorMock(), diff --git a/tests/lib/Server/Output/ValueObjectVisitor/ContentTypeListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/ContentTypeListTest.php index 52fa145d..bd514bcf 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/ContentTypeListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/ContentTypeListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Core\Repository\Values\ContentType; @@ -36,7 +37,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -109,9 +110,9 @@ public function testContentTypeListVisitsChildren() '/content/typegroups/2/types' ); - $this->getVisitorMock()->expects($this->exactly(2)) + $this->getVisitorMock()->expects(self::exactly(2)) ->method('visitValueObject') - ->with($this->isInstanceOf(RestContentType::class)); + ->with(self::isInstanceOf(RestContentType::class)); $visitor->visit( $this->getVisitorMock(), diff --git a/tests/lib/Server/Output/ValueObjectVisitor/CountryListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/CountryListTest.php index 917fa6e0..bcbbfe15 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/CountryListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/CountryListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Rest\Server\Output\ValueObjectVisitor; @@ -49,7 +50,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); $dom = new \DOMDocument(); diff --git a/tests/lib/Server/Output/ValueObjectVisitor/DeletedUserSessionTest.php b/tests/lib/Server/Output/ValueObjectVisitor/DeletedUserSessionTest.php index eaec8090..314de540 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/DeletedUserSessionTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/DeletedUserSessionTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Rest\Server\Output\ValueObjectVisitor; @@ -32,9 +33,9 @@ public function testVisit() $deletedSessionValue = new Values\DeletedUserSession($generatedResponse); $outputVisitor = $this->getVisitorMock(); - $outputVisitor->expects($this->once()) + $outputVisitor->expects(self::once()) ->method('setStatus') - ->with($this->equalTo(204)); + ->with(self::equalTo(204)); $visitor->visit( $outputVisitor, @@ -42,10 +43,10 @@ public function testVisit() $deletedSessionValue ); - $this->assertTrue($generator->isEmpty()); - $this->assertSame('bar', $this->getResponseMock()->headers->get('foo')); - $this->assertSame('thing', $this->getResponseMock()->headers->get('some')); - $this->assertSame([$cookie], $this->getResponseMock()->headers->getCookies()); + self::assertTrue($generator->isEmpty()); + self::assertSame('bar', $this->getResponseMock()->headers->get('foo')); + self::assertSame('thing', $this->getResponseMock()->headers->get('some')); + self::assertSame([$cookie], $this->getResponseMock()->headers->getCookies()); } protected function internalGetVisitor() diff --git a/tests/lib/Server/Output/ValueObjectVisitor/ExceptionTest.php b/tests/lib/Server/Output/ValueObjectVisitor/ExceptionTest.php index a7287aaa..194a8a8b 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/ExceptionTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/ExceptionTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use DOMDocument; @@ -33,7 +34,7 @@ public function testVisit() $result = $this->generateDocument($generator, $visitor); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -53,7 +54,7 @@ public function testVisitNonVerbose(): string $result = $this->generateDocument($generator, $visitor); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -135,7 +136,7 @@ public function testNonVerboseErrorDescription(string $result): void $nodeList = $xpath->query('//ErrorMessage/errorDescription'); $errorDescriptionNode = $nodeList->item(0); - $this->assertEquals(self::NON_VERBOSE_ERROR_DESCRIPTION, $errorDescriptionNode->textContent); + self::assertEquals(self::NON_VERBOSE_ERROR_DESCRIPTION, $errorDescriptionNode->textContent); } /** @@ -247,7 +248,7 @@ private function generateDocument( $this ->getVisitorMock() - ->expects($this->once()) + ->expects(self::once()) ->method('visitValueObject') ->with($previousException); diff --git a/tests/lib/Server/Output/ValueObjectVisitor/FieldDefinitionListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/FieldDefinitionListTest.php index 22e169a6..ad26fa8f 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/FieldDefinitionListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/FieldDefinitionListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Core\Repository\Values; @@ -28,9 +29,9 @@ public function testVisitFieldDefinitionList() $fieldDefinitionList = $this->getBasicFieldDefinitionList(); - $this->getVisitorMock()->expects($this->exactly(2)) + $this->getVisitorMock()->expects(self::exactly(2)) ->method('visitValueObject') - ->with($this->isInstanceOf(Server\Values\RestFieldDefinition::class)); + ->with(self::isInstanceOf(Server\Values\RestFieldDefinition::class)); $this->addRouteExpectation( 'ibexa.rest.load_content_type_field_definition_list', @@ -46,7 +47,7 @@ public function testVisitFieldDefinitionList() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); $dom = new \DOMDocument(); $dom->loadXml($result); @@ -92,6 +93,7 @@ public function provideXpathAssertions() * @param \DOMDocument $dom * * @depends testVisitFieldDefinitionList + * * @dataProvider provideXpathAssertions */ public function testGeneratedXml($xpath, \DOMDocument $dom) diff --git a/tests/lib/Server/Output/ValueObjectVisitor/ForbiddenExceptionTest.php b/tests/lib/Server/Output/ValueObjectVisitor/ForbiddenExceptionTest.php index 9b9bddc6..5b2d621c 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/ForbiddenExceptionTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/ForbiddenExceptionTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Rest\Server\Exceptions; diff --git a/tests/lib/Server/Output/ValueObjectVisitor/ImageVariationTest.php b/tests/lib/Server/Output/ValueObjectVisitor/ImageVariationTest.php index 7a5da308..abdabe99 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/ImageVariationTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/ImageVariationTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Variation\Values\ImageVariation; @@ -54,7 +55,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); $dom = new \DOMDocument(); $dom->loadXml($result); @@ -64,6 +65,7 @@ public function testVisit() /** * @param \DOMDocument $dom + * * @depends testVisit */ public function testContentImageVariationContentTagExists(\DOMDocument $dom) @@ -73,6 +75,7 @@ public function testContentImageVariationContentTagExists(\DOMDocument $dom) /** * @param \DOMDocument $dom + * * @depends testVisit */ public function testContentImageVariationTagHrefAttribute(\DOMDocument $dom) @@ -82,6 +85,7 @@ public function testContentImageVariationTagHrefAttribute(\DOMDocument $dom) /** * @param \DOMDocument $dom + * * @depends testVisit */ public function testContentImageVariationTagMediaTypeAttribute(\DOMDocument $dom) @@ -91,6 +95,7 @@ public function testContentImageVariationTagMediaTypeAttribute(\DOMDocument $dom /** * @param \DOMDocument $dom + * * @depends testVisit */ public function testUriTagExists(\DOMDocument $dom) @@ -100,6 +105,7 @@ public function testUriTagExists(\DOMDocument $dom) /** * @param \DOMDocument $dom + * * @depends testVisit */ public function testUriTagValue(\DOMDocument $dom) @@ -109,6 +115,7 @@ public function testUriTagValue(\DOMDocument $dom) /** * @param \DOMDocument $dom + * * @depends testVisit */ public function testContentTypeTagExists(\DOMDocument $dom) @@ -118,6 +125,7 @@ public function testContentTypeTagExists(\DOMDocument $dom) /** * @param \DOMDocument $dom + * * @depends testVisit */ public function testContentTypeTagValue(\DOMDocument $dom) @@ -127,6 +135,7 @@ public function testContentTypeTagValue(\DOMDocument $dom) /** * @param \DOMDocument $dom + * * @depends testVisit */ public function testWidthTagExists(\DOMDocument $dom) @@ -136,6 +145,7 @@ public function testWidthTagExists(\DOMDocument $dom) /** * @param \DOMDocument $dom + * * @depends testVisit */ public function testWidthTagValue(\DOMDocument $dom) @@ -145,6 +155,7 @@ public function testWidthTagValue(\DOMDocument $dom) /** * @param \DOMDocument $dom + * * @depends testVisit */ public function testHeightTagExists(\DOMDocument $dom) @@ -154,6 +165,7 @@ public function testHeightTagExists(\DOMDocument $dom) /** * @param \DOMDocument $dom + * * @depends testVisit */ public function testHeightTagValue(\DOMDocument $dom) @@ -163,6 +175,7 @@ public function testHeightTagValue(\DOMDocument $dom) /** * @param \DOMDocument $dom + * * @depends testVisit */ public function testFileSizeTagExists(\DOMDocument $dom) @@ -172,6 +185,7 @@ public function testFileSizeTagExists(\DOMDocument $dom) /** * @param \DOMDocument $dom + * * @depends testVisit */ public function testFileSizeTagValue(\DOMDocument $dom) diff --git a/tests/lib/Server/Output/ValueObjectVisitor/InvalidArgumentExceptionTest.php b/tests/lib/Server/Output/ValueObjectVisitor/InvalidArgumentExceptionTest.php index 7657dc7f..5d437a6e 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/InvalidArgumentExceptionTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/InvalidArgumentExceptionTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Rest\Exceptions; diff --git a/tests/lib/Server/Output/ValueObjectVisitor/LocationListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/LocationListTest.php index 027b15ac..7daa2ed1 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/LocationListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/LocationListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Rest\Server\Output\ValueObjectVisitor; @@ -35,7 +36,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } diff --git a/tests/lib/Server/Output/ValueObjectVisitor/LocationTest.php b/tests/lib/Server/Output/ValueObjectVisitor/LocationTest.php index df181ccc..5236bddb 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/LocationTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/LocationTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use eZ\Publish\Core\Repository\Values\Content\Location; diff --git a/tests/lib/Server/Output/ValueObjectVisitor/NoContentTest.php b/tests/lib/Server/Output/ValueObjectVisitor/NoContentTest.php index 067ae101..e054212c 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/NoContentTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/NoContentTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Rest\Server\Output\ValueObjectVisitor; @@ -26,9 +27,9 @@ public function testVisit() $noContent = new Values\NoContent(); - $this->getVisitorMock()->expects($this->once()) + $this->getVisitorMock()->expects(self::once()) ->method('setStatus') - ->with($this->equalTo(204)); + ->with(self::equalTo(204)); $visitor->visit( $this->getVisitorMock(), @@ -36,7 +37,7 @@ public function testVisit() $noContent ); - $this->assertTrue($generator->isEmpty()); + self::assertTrue($generator->isEmpty()); } /** diff --git a/tests/lib/Server/Output/ValueObjectVisitor/NotFoundExceptionTest.php b/tests/lib/Server/Output/ValueObjectVisitor/NotFoundExceptionTest.php index f426a7b0..d4b243b5 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/NotFoundExceptionTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/NotFoundExceptionTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Exceptions\NotFoundException; diff --git a/tests/lib/Server/Output/ValueObjectVisitor/NotImplementedExceptionTest.php b/tests/lib/Server/Output/ValueObjectVisitor/NotImplementedExceptionTest.php index 32560f7b..b15ccab0 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/NotImplementedExceptionTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/NotImplementedExceptionTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Exceptions\NotImplementedException; diff --git a/tests/lib/Server/Output/ValueObjectVisitor/ObjectStateGroupListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/ObjectStateGroupListTest.php index 08086c2c..a4335501 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/ObjectStateGroupListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/ObjectStateGroupListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Core\Repository\Values\ObjectState\ObjectStateGroup; @@ -37,7 +38,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -101,9 +102,9 @@ public function testObjectStateGroupListVisitsChildren() ] ); - $this->getVisitorMock()->expects($this->exactly(2)) + $this->getVisitorMock()->expects(self::exactly(2)) ->method('visitValueObject') - ->with($this->isInstanceOf(\Ibexa\Contracts\Core\Repository\Values\ObjectState\ObjectStateGroup::class)); + ->with(self::isInstanceOf(\Ibexa\Contracts\Core\Repository\Values\ObjectState\ObjectStateGroup::class)); $visitor->visit( $this->getVisitorMock(), diff --git a/tests/lib/Server/Output/ValueObjectVisitor/ObjectStateGroupTest.php b/tests/lib/Server/Output/ValueObjectVisitor/ObjectStateGroupTest.php index 01db5f46..97744e72 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/ObjectStateGroupTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/ObjectStateGroupTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Core\Repository\Values\ObjectState; @@ -61,7 +62,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } diff --git a/tests/lib/Server/Output/ValueObjectVisitor/ObjectStateListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/ObjectStateListTest.php index f1909d3a..b042d0b5 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/ObjectStateListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/ObjectStateListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Core\Repository\Values\ObjectState\ObjectState; @@ -43,7 +44,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -108,9 +109,9 @@ public function testObjectStateListVisitsChildren() 42 ); - $this->getVisitorMock()->expects($this->exactly(2)) + $this->getVisitorMock()->expects(self::exactly(2)) ->method('visitValueObject') - ->with($this->isInstanceOf(RestObjectState::class)); + ->with(self::isInstanceOf(RestObjectState::class)); $visitor->visit( $this->getVisitorMock(), diff --git a/tests/lib/Server/Output/ValueObjectVisitor/OptionsTest.php b/tests/lib/Server/Output/ValueObjectVisitor/OptionsTest.php index 7e905a64..5d7a412c 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/OptionsTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/OptionsTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Rest\Server\Output\ValueObjectVisitor; @@ -26,11 +27,11 @@ public function testVisit() $noContent = new Values\Options(['GET', 'POST']); - $this->getVisitorMock()->expects($this->once()) + $this->getVisitorMock()->expects(self::once()) ->method('setStatus') - ->with($this->equalTo(200)); + ->with(self::equalTo(200)); - $this->getVisitorMock()->expects($this->exactly(2)) + $this->getVisitorMock()->expects(self::exactly(2)) ->method('setHeader') ->willReturnMap( ['Allow', 'GET,POST'], diff --git a/tests/lib/Server/Output/ValueObjectVisitor/PermanentRedirectTest.php b/tests/lib/Server/Output/ValueObjectVisitor/PermanentRedirectTest.php index a4e95238..81e62521 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/PermanentRedirectTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/PermanentRedirectTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Rest\Server\Output\ValueObjectVisitor; @@ -26,12 +27,12 @@ public function testVisit() $redirect = new Values\PermanentRedirect('/some/redirect/uri'); - $this->getVisitorMock()->expects($this->once()) + $this->getVisitorMock()->expects(self::once()) ->method('setStatus') - ->with($this->equalTo(301)); - $this->getVisitorMock()->expects($this->once()) + ->with(self::equalTo(301)); + $this->getVisitorMock()->expects(self::once()) ->method('setHeader') - ->with($this->equalTo('Location'), $this->equalTo('/some/redirect/uri')); + ->with(self::equalTo('Location'), self::equalTo('/some/redirect/uri')); $visitor->visit( $this->getVisitorMock(), @@ -39,7 +40,7 @@ public function testVisit() $redirect ); - $this->assertTrue($generator->isEmpty()); + self::assertTrue($generator->isEmpty()); } /** diff --git a/tests/lib/Server/Output/ValueObjectVisitor/PolicyListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/PolicyListTest.php index 59babb5a..6c5ea972 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/PolicyListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/PolicyListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\User\Policy; @@ -36,7 +37,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -101,9 +102,9 @@ public function testPolicyListVisitsChildren() 42 ); - $this->getVisitorMock()->expects($this->exactly(2)) + $this->getVisitorMock()->expects(self::exactly(2)) ->method('visitValueObject') - ->with($this->isInstanceOf(Policy::class)); + ->with(self::isInstanceOf(Policy::class)); $visitor->visit( $this->getVisitorMock(), diff --git a/tests/lib/Server/Output/ValueObjectVisitor/PolicyTest.php b/tests/lib/Server/Output/ValueObjectVisitor/PolicyTest.php index 8a0a0809..d3c0aba0 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/PolicyTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/PolicyTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\User\Limitation\ContentTypeLimitation; @@ -54,7 +55,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } diff --git a/tests/lib/Server/Output/ValueObjectVisitor/RelationListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/RelationListTest.php index d9e4953c..ad13ef34 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/RelationListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/RelationListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Core\Repository\Values\Content; @@ -45,7 +46,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -111,9 +112,9 @@ public function testRelationListVisitsChildren() 1 ); - $this->getVisitorMock()->expects($this->exactly(2)) + $this->getVisitorMock()->expects(self::exactly(2)) ->method('visitValueObject') - ->with($this->isInstanceOf(RestRelation::class)); + ->with(self::isInstanceOf(RestRelation::class)); $visitor->visit( $this->getVisitorMock(), diff --git a/tests/lib/Server/Output/ValueObjectVisitor/ResourceCreatedTest.php b/tests/lib/Server/Output/ValueObjectVisitor/ResourceCreatedTest.php index a9433cf4..c7241123 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/ResourceCreatedTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/ResourceCreatedTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Rest\Server\Output\ValueObjectVisitor; @@ -28,12 +29,12 @@ public function testVisit() '/some/redirect/uri' ); - $this->getVisitorMock()->expects($this->once()) + $this->getVisitorMock()->expects(self::once()) ->method('setStatus') - ->with($this->equalTo(201)); - $this->getVisitorMock()->expects($this->once()) + ->with(self::equalTo(201)); + $this->getVisitorMock()->expects(self::once()) ->method('setHeader') - ->with($this->equalTo('Location'), $this->equalTo('/some/redirect/uri')); + ->with(self::equalTo('Location'), self::equalTo('/some/redirect/uri')); $visitor->visit( $this->getVisitorMock(), @@ -41,7 +42,7 @@ public function testVisit() $resourceCreated ); - $this->assertTrue($generator->isEmpty()); + self::assertTrue($generator->isEmpty()); } /** diff --git a/tests/lib/Server/Output/ValueObjectVisitor/RestContentTest.php b/tests/lib/Server/Output/ValueObjectVisitor/RestContentTest.php index ccf12af7..89020b10 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/RestContentTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/RestContentTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use DOMDocument; @@ -39,7 +40,7 @@ public function testVisitWithoutEmbeddedVersion(): DOMDocument $restContent = $this->getBasicRestContent(); - $this->getVisitorMock()->expects($this->never()) + $this->getVisitorMock()->expects(self::never()) ->method('visitValueObject'); $this->addRouteExpectation( @@ -96,7 +97,7 @@ public function testVisitWithoutEmbeddedVersion(): DOMDocument $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); $dom = new DOMDocument(); $dom->loadXml($result); @@ -240,9 +241,9 @@ public function testVisitWithEmbeddedVersion(): DOMDocument ContentType::class ); - $this->getVisitorMock()->expects($this->once()) + $this->getVisitorMock()->expects(self::once()) ->method('visitValueObject') - ->with($this->isInstanceOf(Version::class)); + ->with(self::isInstanceOf(Version::class)); $this->addRouteExpectation( 'ibexa.rest.load_content', @@ -273,7 +274,7 @@ public function testVisitWithEmbeddedVersion(): DOMDocument $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); $dom = new DOMDocument(); $dom->loadXml($result); diff --git a/tests/lib/Server/Output/ValueObjectVisitor/RestContentTypeTest.php b/tests/lib/Server/Output/ValueObjectVisitor/RestContentTypeTest.php index 5ecf0e77..795fe50e 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/RestContentTypeTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/RestContentTypeTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Core\Repository\Values; @@ -30,9 +31,9 @@ public function testVisitDefinedType() $restContentType = $this->getBasicContentType(); - $this->getVisitorMock()->expects($this->once()) + $this->getVisitorMock()->expects(self::once()) ->method('visitValueObject') - ->with($this->isInstanceOf(FieldDefinitionList::class)); + ->with(self::isInstanceOf(FieldDefinitionList::class)); $this->addRouteExpectation( 'ibexa.rest.load_content_type', @@ -68,7 +69,7 @@ public function testVisitDefinedType() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); $dom = new \DOMDocument(); $dom->loadXml($result); diff --git a/tests/lib/Server/Output/ValueObjectVisitor/RestExecutedViewTest.php b/tests/lib/Server/Output/ValueObjectVisitor/RestExecutedViewTest.php index 620f2de3..464fcc0d 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/RestExecutedViewTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/RestExecutedViewTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\ContentService; @@ -66,7 +67,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); $dom = new \DOMDocument(); $dom->loadXml($result); @@ -97,6 +98,7 @@ public function provideXpathAssertions() * @param \DOMDocument $dom * * @depends testVisit + * * @dataProvider provideXpathAssertions */ public function testGeneratedXml($xpath, \DOMDocument $dom) diff --git a/tests/lib/Server/Output/ValueObjectVisitor/RestFieldDefinitionTest.php b/tests/lib/Server/Output/ValueObjectVisitor/RestFieldDefinitionTest.php index 8bfabd29..a3b8cdd9 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/RestFieldDefinitionTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/RestFieldDefinitionTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Core\Repository\Values; @@ -40,12 +41,12 @@ protected function generateDomDocument(?string $path = null): \DOMDocument $restFieldDefinition = $this->getBasicRestFieldDefinition($path); - $this->fieldTypeSerializerMock->expects($this->once()) + $this->fieldTypeSerializerMock->expects(self::once()) ->method('serializeFieldDefaultValue') ->with( - $this->isInstanceOf('\\Ibexa\\Contracts\\Rest\\Output\\Generator'), - $this->equalTo('my-field-type'), - $this->equalTo( + self::isInstanceOf('\\Ibexa\\Contracts\\Rest\\Output\\Generator'), + self::equalTo('my-field-type'), + self::equalTo( 'my default value text' ) ); @@ -69,7 +70,7 @@ protected function generateDomDocument(?string $path = null): \DOMDocument $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); $dom = new \DOMDocument(); $dom->loadXml($result); @@ -156,6 +157,7 @@ protected function getXpathAssertions(): array /** * @depends testVisitRestFieldDefinition + * * @dataProvider provideXpathAssertions */ public function testGeneratedXml(string $xpath, \DOMDocument $dom): void @@ -165,6 +167,7 @@ public function testGeneratedXml(string $xpath, \DOMDocument $dom): void /** * @depends testVisitRestFieldDefinitionWithPath + * * @dataProvider provideXpathAssertionsPath */ public function testGeneratedXmlPath(string $xpath, \DOMDocument $dom): void diff --git a/tests/lib/Server/Output/ValueObjectVisitor/RestLocationRootNodeTest.php b/tests/lib/Server/Output/ValueObjectVisitor/RestLocationRootNodeTest.php index abefedd3..f449d45b 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/RestLocationRootNodeTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/RestLocationRootNodeTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; @@ -80,9 +81,9 @@ public function testVisit() "/content/objects/{$location->location->contentId}" ); - $this->getVisitorMock()->expects($this->once()) + $this->getVisitorMock()->expects(self::once()) ->method('visitValueObject') - ->with($this->isInstanceOf(RestContent::class)); + ->with(self::isInstanceOf(RestContent::class)); $visitor->visit( $this->getVisitorMock(), @@ -92,7 +93,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } diff --git a/tests/lib/Server/Output/ValueObjectVisitor/RestLocationTest.php b/tests/lib/Server/Output/ValueObjectVisitor/RestLocationTest.php index 12132d59..b7899a66 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/RestLocationTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/RestLocationTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; @@ -87,9 +88,9 @@ public function testVisit() "/content/objects/{$location->location->contentId}" ); - $this->getVisitorMock()->expects($this->once()) + $this->getVisitorMock()->expects(self::once()) ->method('visitValueObject') - ->with($this->isInstanceOf(RestContent::class)); + ->with(self::isInstanceOf(RestContent::class)); $visitor->visit( $this->getVisitorMock(), @@ -99,7 +100,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } diff --git a/tests/lib/Server/Output/ValueObjectVisitor/RestObjectStateTest.php b/tests/lib/Server/Output/ValueObjectVisitor/RestObjectStateTest.php index f9099d36..305a19d8 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/RestObjectStateTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/RestObjectStateTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Core\Repository\Values\ObjectState\ObjectState; @@ -65,7 +66,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } diff --git a/tests/lib/Server/Output/ValueObjectVisitor/RestRelationTest.php b/tests/lib/Server/Output/ValueObjectVisitor/RestRelationTest.php index 1abee626..3da2b22c 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/RestRelationTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/RestRelationTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; @@ -76,7 +77,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } diff --git a/tests/lib/Server/Output/ValueObjectVisitor/RestTrashItemTest.php b/tests/lib/Server/Output/ValueObjectVisitor/RestTrashItemTest.php index cfb3a75f..0e24cd81 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/RestTrashItemTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/RestTrashItemTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; @@ -77,9 +78,9 @@ public function testVisit() "/content/objects/{$trashItem->trashItem->contentInfo->id}" ); - $this->getVisitorMock()->expects($this->once()) + $this->getVisitorMock()->expects(self::once()) ->method('visitValueObject') - ->with($this->isInstanceOf(RestContent::class)); + ->with(self::isInstanceOf(RestContent::class)); $visitor->visit( $this->getVisitorMock(), @@ -89,7 +90,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } diff --git a/tests/lib/Server/Output/ValueObjectVisitor/RestUserGroupRoleAssignmentTest.php b/tests/lib/Server/Output/ValueObjectVisitor/RestUserGroupRoleAssignmentTest.php index fa051c4a..bf7ab05d 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/RestUserGroupRoleAssignmentTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/RestUserGroupRoleAssignmentTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Core\Repository\Values\User; @@ -61,7 +62,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } diff --git a/tests/lib/Server/Output/ValueObjectVisitor/RestUserGroupTest.php b/tests/lib/Server/Output/ValueObjectVisitor/RestUserGroupTest.php index 97ef3032..3e185d92 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/RestUserGroupTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/RestUserGroupTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use DOMDocument; @@ -23,7 +24,7 @@ public function testVisitWithoutEmbeddedVersion(): DOMDocument $restUserGroup = $this->getBasicRestUserGroup(); - $this->getVisitorMock()->expects($this->once()) + $this->getVisitorMock()->expects(self::once()) ->method('visitValueObject'); $userGroupPath = trim($restUserGroup->mainLocation->getPathString(), '/'); @@ -67,7 +68,7 @@ public function testVisitWithoutEmbeddedVersion(): DOMDocument $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); $dom = new DOMDocument(); $dom->loadXml($result); diff --git a/tests/lib/Server/Output/ValueObjectVisitor/RestUserRoleAssignmentTest.php b/tests/lib/Server/Output/ValueObjectVisitor/RestUserRoleAssignmentTest.php index 905118b3..0064e5c0 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/RestUserRoleAssignmentTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/RestUserRoleAssignmentTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Core\Repository\Values\User; @@ -62,7 +63,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } diff --git a/tests/lib/Server/Output/ValueObjectVisitor/RestUserTest.php b/tests/lib/Server/Output/ValueObjectVisitor/RestUserTest.php index c02f8c20..7f2ed68b 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/RestUserTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/RestUserTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use DOMDocument; @@ -23,7 +24,7 @@ public function testVisitWithoutEmbeddedVersion(): DOMDocument $restUser = $this->getBasicRestUser(); - $this->getVisitorMock()->expects($this->once()) + $this->getVisitorMock()->expects(self::once()) ->method('visitValueObject'); $this->addRouteExpectation( @@ -61,7 +62,7 @@ public function testVisitWithoutEmbeddedVersion(): DOMDocument $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); $dom = new DOMDocument(); $dom->loadXml($result); diff --git a/tests/lib/Server/Output/ValueObjectVisitor/RoleAssignmentListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/RoleAssignmentListTest.php index 033fa90b..eefc5bb6 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/RoleAssignmentListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/RoleAssignmentListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Core\Repository\Values\User; @@ -42,7 +43,7 @@ public function testVisitUserRoleAssignmentList() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -107,9 +108,9 @@ public function testRoleAssignmentListVisitsChildren() 42 ); - $this->getVisitorMock()->expects($this->exactly(2)) + $this->getVisitorMock()->expects(self::exactly(2)) ->method('visitValueObject') - ->with($this->isInstanceOf(RestUserRoleAssignment::class)); + ->with(self::isInstanceOf(RestUserRoleAssignment::class)); $visitor->visit( $this->getVisitorMock(), @@ -148,7 +149,7 @@ public function testVisitGroupRoleAssignmentList() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } diff --git a/tests/lib/Server/Output/ValueObjectVisitor/RoleListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/RoleListTest.php index 3b35c502..70fc98fe 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/RoleListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/RoleListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\User\Role; @@ -36,7 +37,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -101,9 +102,9 @@ public function testRoleListVisitsChildren() '/user/roles' ); - $this->getVisitorMock()->expects($this->exactly(2)) + $this->getVisitorMock()->expects(self::exactly(2)) ->method('visitValueObject') - ->with($this->isInstanceOf(Role::class)); + ->with(self::isInstanceOf(Role::class)); $visitor->visit( $this->getVisitorMock(), diff --git a/tests/lib/Server/Output/ValueObjectVisitor/RoleTest.php b/tests/lib/Server/Output/ValueObjectVisitor/RoleTest.php index 1a93b6b3..16608469 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/RoleTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/RoleTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Core\Repository\Values\User; @@ -53,7 +54,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -132,7 +133,7 @@ public function testResultContainsIdentifierValueElement($result) */ public function testResultContainsMainLanguageCodeValueElement($result) { - $this->markTestSkipped('@todo uncomment when support for multilingual names and descriptions is added EZP-24776'); + self::markTestSkipped('@todo uncomment when support for multilingual names and descriptions is added EZP-24776'); $this->assertXMLTag( [ 'tag' => 'mainLanguageCode', @@ -153,7 +154,7 @@ public function testResultContainsMainLanguageCodeValueElement($result) */ public function testResultContainsNamesElement($result) { - $this->markTestSkipped('@todo uncomment when support for multilingual names and descriptions is added EZP-24776'); + self::markTestSkipped('@todo uncomment when support for multilingual names and descriptions is added EZP-24776'); $this->assertXMLTag( [ 'tag' => 'names', @@ -176,7 +177,7 @@ public function testResultContainsNamesElement($result) */ public function testResultContainsDescriptionsElement($result) { - $this->markTestSkipped('@todo uncomment when support for multilingual names and descriptions is added EZP-24776'); + self::markTestSkipped('@todo uncomment when support for multilingual names and descriptions is added EZP-24776'); $this->assertXMLTag( [ 'tag' => 'descriptions', diff --git a/tests/lib/Server/Output/ValueObjectVisitor/RootTest.php b/tests/lib/Server/Output/ValueObjectVisitor/RootTest.php index ae8ddb05..99f995a9 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/RootTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/RootTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\SiteAccess\ConfigResolverInterface; @@ -73,7 +74,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } diff --git a/tests/lib/Server/Output/ValueObjectVisitor/SectionListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/SectionListTest.php index 9c5ae067..6db63170 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/SectionListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/SectionListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content; @@ -35,7 +36,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -100,9 +101,9 @@ public function testSectionListVisitsChildren() '/content/sections' ); - $this->getVisitorMock()->expects($this->exactly(2)) + $this->getVisitorMock()->expects(self::exactly(2)) ->method('visitValueObject') - ->with($this->isInstanceOf(Content\Section::class)); + ->with(self::isInstanceOf(Content\Section::class)); $visitor->visit( $this->getVisitorMock(), diff --git a/tests/lib/Server/Output/ValueObjectVisitor/SectionTest.php b/tests/lib/Server/Output/ValueObjectVisitor/SectionTest.php index cff8b6dd..40a1e047 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/SectionTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/SectionTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content; @@ -46,7 +47,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } diff --git a/tests/lib/Server/Output/ValueObjectVisitor/TemporaryRedirectTest.php b/tests/lib/Server/Output/ValueObjectVisitor/TemporaryRedirectTest.php index 2a1f9733..f4a78201 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/TemporaryRedirectTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/TemporaryRedirectTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Rest\Server\Output\ValueObjectVisitor; @@ -26,12 +27,12 @@ public function testVisit() $redirect = new Values\TemporaryRedirect('/some/redirect/uri'); - $this->getVisitorMock()->expects($this->once()) + $this->getVisitorMock()->expects(self::once()) ->method('setStatus') - ->with($this->equalTo(307)); - $this->getVisitorMock()->expects($this->once()) + ->with(self::equalTo(307)); + $this->getVisitorMock()->expects(self::once()) ->method('setHeader') - ->with($this->equalTo('Location'), $this->equalTo('/some/redirect/uri')); + ->with(self::equalTo('Location'), self::equalTo('/some/redirect/uri')); $visitor->visit( $this->getVisitorMock(), @@ -39,7 +40,7 @@ public function testVisit() $redirect ); - $this->assertTrue($generator->isEmpty()); + self::assertTrue($generator->isEmpty()); } /** diff --git a/tests/lib/Server/Output/ValueObjectVisitor/TrashTest.php b/tests/lib/Server/Output/ValueObjectVisitor/TrashTest.php index ce9882b4..45cb4b53 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/TrashTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/TrashTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Core\Repository\Values\Content; @@ -36,7 +37,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -109,9 +110,9 @@ public function testTrashVisitsChildren() '/content/trash' ); - $this->getVisitorMock()->expects($this->exactly(2)) + $this->getVisitorMock()->expects(self::exactly(2)) ->method('visitValueObject') - ->with($this->isInstanceOf(RestTrashItem::class)); + ->with(self::isInstanceOf(RestTrashItem::class)); $visitor->visit( $this->getVisitorMock(), diff --git a/tests/lib/Server/Output/ValueObjectVisitor/URLAliasListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/URLAliasListTest.php index 186c5153..4007fe92 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/URLAliasListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/URLAliasListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content; @@ -35,7 +36,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -100,9 +101,9 @@ public function testURLAliasListVisitsChildren() '/content/urlaliases' ); - $this->getVisitorMock()->expects($this->exactly(2)) + $this->getVisitorMock()->expects(self::exactly(2)) ->method('visitValueObject') - ->with($this->isInstanceOf(Content\URLAlias::class)); + ->with(self::isInstanceOf(Content\URLAlias::class)); $visitor->visit( $this->getVisitorMock(), diff --git a/tests/lib/Server/Output/ValueObjectVisitor/URLAliasRefListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/URLAliasRefListTest.php index cfe1d00b..b1527d5d 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/URLAliasRefListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/URLAliasRefListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content\URLAlias; @@ -50,7 +51,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); $dom = new \DOMDocument(); $dom->loadXml($result); diff --git a/tests/lib/Server/Output/ValueObjectVisitor/URLAliasTest.php b/tests/lib/Server/Output/ValueObjectVisitor/URLAliasTest.php index 1d67b6c8..765f96e1 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/URLAliasTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/URLAliasTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content; @@ -52,7 +53,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } diff --git a/tests/lib/Server/Output/ValueObjectVisitor/URLWildcardListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/URLWildcardListTest.php index 0b7eb226..7cb4118e 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/URLWildcardListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/URLWildcardListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content; @@ -41,7 +42,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -105,9 +106,9 @@ public function testURLWildcardListVisitsChildren() ] ); - $this->getVisitorMock()->expects($this->exactly(2)) + $this->getVisitorMock()->expects(self::exactly(2)) ->method('visitValueObject') - ->with($this->isInstanceOf(Content\URLWildcard::class)); + ->with(self::isInstanceOf(Content\URLWildcard::class)); $visitor->visit( $this->getVisitorMock(), diff --git a/tests/lib/Server/Output/ValueObjectVisitor/URLWildcardTest.php b/tests/lib/Server/Output/ValueObjectVisitor/URLWildcardTest.php index f276a80b..c0c77dfd 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/URLWildcardTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/URLWildcardTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content; @@ -47,7 +48,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } diff --git a/tests/lib/Server/Output/ValueObjectVisitor/UnauthorizedExceptionTest.php b/tests/lib/Server/Output/ValueObjectVisitor/UnauthorizedExceptionTest.php index d539bf0f..d06704e1 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/UnauthorizedExceptionTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/UnauthorizedExceptionTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Exceptions\UnauthorizedException; diff --git a/tests/lib/Server/Output/ValueObjectVisitor/UserGroupListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/UserGroupListTest.php index 29fb5365..f2ae1b5c 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/UserGroupListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/UserGroupListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; @@ -39,7 +40,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -124,9 +125,9 @@ public function testUserGroupListVisitsChildren() '/some/path' ); - $this->getVisitorMock()->expects($this->exactly(2)) + $this->getVisitorMock()->expects(self::exactly(2)) ->method('visitValueObject') - ->with($this->isInstanceOf(RestUserGroup::class)); + ->with(self::isInstanceOf(RestUserGroup::class)); $visitor->visit( $this->getVisitorMock(), diff --git a/tests/lib/Server/Output/ValueObjectVisitor/UserGroupRefListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/UserGroupRefListTest.php index cc6434d0..ace0b6f0 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/UserGroupRefListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/UserGroupRefListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; @@ -92,7 +93,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); $dom = new \DOMDocument(); $dom->loadXml($result); diff --git a/tests/lib/Server/Output/ValueObjectVisitor/UserListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/UserListTest.php index e04fa1d1..6cd91675 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/UserListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/UserListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; @@ -39,7 +40,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -124,9 +125,9 @@ public function testUserListVisitsChildren() '/some/path' ); - $this->getVisitorMock()->expects($this->exactly(2)) + $this->getVisitorMock()->expects(self::exactly(2)) ->method('visitValueObject') - ->with($this->isInstanceOf(RestUser::class)); + ->with(self::isInstanceOf(RestUser::class)); $visitor->visit( $this->getVisitorMock(), diff --git a/tests/lib/Server/Output/ValueObjectVisitor/UserRefListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/UserRefListTest.php index d71ac91c..21ef1b68 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/UserRefListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/UserRefListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; @@ -60,7 +61,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); $dom = new \DOMDocument(); $dom->loadXml($result); diff --git a/tests/lib/Server/Output/ValueObjectVisitor/UserSessionCreatedTest.php b/tests/lib/Server/Output/ValueObjectVisitor/UserSessionCreatedTest.php index d1317a28..bc5553e0 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/UserSessionCreatedTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/UserSessionCreatedTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Rest\Server\Values; @@ -30,13 +31,13 @@ public function testVisit() true ); - $this->getVisitorMock()->expects($this->any()) + $this->getVisitorMock()->expects(self::any()) ->method('setStatus') - ->with($this->equalTo(201)); + ->with(self::equalTo(201)); - $this->getVisitorMock()->expects($this->at(1)) + $this->getVisitorMock()->expects(self::at(1)) ->method('setHeader') - ->with($this->equalTo('Content-Type'), $this->equalTo('application/vnd.ibexa.api.Session+xml')); + ->with(self::equalTo('Content-Type'), self::equalTo('application/vnd.ibexa.api.Session+xml')); $this->addRouteExpectation( 'ibexa.rest.delete_session', @@ -60,7 +61,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } diff --git a/tests/lib/Server/Output/ValueObjectVisitor/UserSessionTest.php b/tests/lib/Server/Output/ValueObjectVisitor/UserSessionTest.php index 5e689aaa..b63ce70c 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/UserSessionTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/UserSessionTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\User\User; @@ -33,13 +34,13 @@ public function testVisit() false ); - $this->getVisitorMock()->expects($this->at(0)) + $this->getVisitorMock()->expects(self::at(0)) ->method('setStatus') - ->with($this->equalTo(200)); + ->with(self::equalTo(200)); - $this->getVisitorMock()->expects($this->at(1)) + $this->getVisitorMock()->expects(self::at(1)) ->method('setHeader') - ->with($this->equalTo('Content-Type'), $this->equalTo('application/vnd.ibexa.api.Session+xml')); + ->with(self::equalTo('Content-Type'), self::equalTo('application/vnd.ibexa.api.Session+xml')); $this->addRouteExpectation( 'ibexa.rest.delete_session', @@ -63,7 +64,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -176,9 +177,9 @@ public function testResultContainsCsrfTokenValueElement($result) protected function getUserMock() { $user = $this->createMock(User::class); - $user->expects($this->any()) + $user->expects(self::any()) ->method('__get') - ->with($this->equalTo('id')) + ->with(self::equalTo('id')) ->willReturn('user123'); return $user; diff --git a/tests/lib/Server/Output/ValueObjectVisitor/VersionInfoTest.php b/tests/lib/Server/Output/ValueObjectVisitor/VersionInfoTest.php index bcecd2f1..2945a52c 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/VersionInfoTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/VersionInfoTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; @@ -79,7 +80,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } diff --git a/tests/lib/Server/Output/ValueObjectVisitor/VersionListTest.php b/tests/lib/Server/Output/ValueObjectVisitor/VersionListTest.php index 194d890e..30ee298d 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/VersionListTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/VersionListTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; @@ -51,7 +52,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } @@ -134,9 +135,9 @@ public function testVersionListVisitsChildren() '/some/path' ); - $this->getVisitorMock()->expects($this->exactly(2)) + $this->getVisitorMock()->expects(self::exactly(2)) ->method('visitValueObject') - ->with($this->isInstanceOf(\Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo::class)); + ->with(self::isInstanceOf(\Ibexa\Contracts\Core\Repository\Values\Content\VersionInfo::class)); $visitor->visit( $this->getVisitorMock(), diff --git a/tests/lib/Server/Output/ValueObjectVisitor/VersionTest.php b/tests/lib/Server/Output/ValueObjectVisitor/VersionTest.php index 02dc863a..909a824c 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/VersionTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/VersionTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; @@ -91,7 +92,7 @@ public function testVisit() $result = $generator->endDocument(null); - $this->assertNotNull($result); + self::assertNotNull($result); return $result; } diff --git a/tests/lib/Server/Security/CsrfTokenManagerTest.php b/tests/lib/Server/Security/CsrfTokenManagerTest.php index 610472e8..7e5b276b 100644 --- a/tests/lib/Server/Security/CsrfTokenManagerTest.php +++ b/tests/lib/Server/Security/CsrfTokenManagerTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Security; use Ibexa\Rest\Server\Security\CsrfTokenManager; @@ -36,7 +37,7 @@ public function testHasTokenForHttp() $csrfTokenManager = $this->createCsrfTokenManager(false); $this->tokenStorage - ->expects($this->once()) + ->expects(self::once()) ->method('hasToken') ->with(self::CSRF_TOKEN_INTENTION); @@ -48,7 +49,7 @@ public function testHasTokenForHttps() $csrfTokenManager = $this->createCsrfTokenManager(true); $this->tokenStorage - ->expects($this->once()) + ->expects(self::once()) ->method('hasToken') ->with('https-' . self::CSRF_TOKEN_INTENTION); @@ -63,7 +64,7 @@ private function createCsrfTokenManager($https = false) } $this->requestStack - ->expects($this->once()) + ->expects(self::once()) ->method('getMainRequest') ->willReturn($request); diff --git a/tests/lib/Server/Security/RestLogoutHandlerTest.php b/tests/lib/Server/Security/RestLogoutHandlerTest.php index cf0d9370..34e74ea3 100644 --- a/tests/lib/Server/Security/RestLogoutHandlerTest.php +++ b/tests/lib/Server/Security/RestLogoutHandlerTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Security; use Ibexa\Contracts\Core\SiteAccess\ConfigResolverInterface; @@ -38,21 +39,21 @@ public function testLogoutWithoutSiteaccessSessionSettings() { $sessionId = 'eZSESSID'; $this->session - ->expects($this->once()) + ->expects(self::once()) ->method('getName') ->willReturn($sessionId); $request = new Request(); $request->setSession($this->session); $request->attributes->set('is_rest_request', true); $this->configResolver - ->expects($this->once()) + ->expects(self::once()) ->method('getParameter') ->with('session') ->willReturn([]); $response = new Response(); $response->headers = $this->createMock(ResponseHeaderBag::class); $response->headers - ->expects($this->once()) + ->expects(self::once()) ->method('clearCookie') ->with($sessionId); $logoutHandler = new RestLogoutHandler($this->configResolver); @@ -67,7 +68,7 @@ public function testLogoutWithSiteaccessSessionSettings() { $sessionId = 'eZSESSID'; $this->session - ->expects($this->once()) + ->expects(self::once()) ->method('getName') ->willReturn($sessionId); $request = new Request(); @@ -78,14 +79,14 @@ public function testLogoutWithSiteaccessSessionSettings() 'cookie_domain' => 'ibexa.co', ]; $this->configResolver - ->expects($this->once()) + ->expects(self::once()) ->method('getParameter') ->with('session') ->willReturn($sessionSettings); $response = new Response(); $response->headers = $this->createMock(ResponseHeaderBag::class); $response->headers - ->expects($this->once()) + ->expects(self::once()) ->method('clearCookie') ->with($sessionId, $sessionSettings['cookie_path'], $sessionSettings['cookie_domain']); $logoutHandler = new RestLogoutHandler($this->configResolver); @@ -100,7 +101,7 @@ public function testLogoutNotRest() { $session = $this->createMock(SessionInterface::class); $session - ->expects($this->never()) + ->expects(self::never()) ->method('getName'); $request = new Request(); @@ -109,7 +110,7 @@ public function testLogoutNotRest() $response = new Response(); $response->headers = $this->createMock(ResponseHeaderBag::class); $response->headers - ->expects($this->never()) + ->expects(self::never()) ->method('clearCookie'); $logoutHandler = new RestLogoutHandler($this->configResolver); diff --git a/tests/lib/Server/Security/RestSessionBasedAuthenticatorTest.php b/tests/lib/Server/Security/RestSessionBasedAuthenticatorTest.php index 76c67ff0..1adb37bd 100644 --- a/tests/lib/Server/Security/RestSessionBasedAuthenticatorTest.php +++ b/tests/lib/Server/Security/RestSessionBasedAuthenticatorTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\Server\Security; use Ibexa\Contracts\Core\Repository\Values\User\User; @@ -89,16 +90,16 @@ public function testAuthenticateAlreadyHaveSessionToken() $existingToken = $this->getTokenInterfaceMock(); $this->tokenStorage - ->expects($this->once()) + ->expects(self::once()) ->method('getToken') ->willReturn($existingToken); $existingToken - ->expects($this->once()) + ->expects(self::once()) ->method('getUsername') ->willReturn($username); $existingToken - ->expects($this->once()) + ->expects(self::once()) ->method('setAttribute') ->with('isFromSession', true); @@ -106,7 +107,7 @@ public function testAuthenticateAlreadyHaveSessionToken() $request->attributes->set('username', $username); $request->attributes->set('password', $password); - $this->assertSame($existingToken, $this->authenticator->authenticate($request)); + self::assertSame($existingToken, $this->authenticator->authenticate($request)); } public function testAuthenticateNoTokenFound() @@ -117,12 +118,12 @@ public function testAuthenticateNoTokenFound() $existingToken = $this->getTokenInterfaceMock(); $this->tokenStorage - ->expects($this->once()) + ->expects(self::once()) ->method('getToken') ->willReturn($existingToken); $existingToken - ->expects($this->once()) + ->expects(self::once()) ->method('getUsername') ->willReturn(__METHOD__); @@ -132,13 +133,13 @@ public function testAuthenticateNoTokenFound() $usernamePasswordToken = new UsernamePasswordToken($username, $password, self::PROVIDER_KEY); $this->authenticationManager - ->expects($this->once()) + ->expects(self::once()) ->method('authenticate') - ->with($this->equalTo($usernamePasswordToken)) + ->with(self::equalTo($usernamePasswordToken)) ->willReturn(null); $this->logger - ->expects($this->once()) + ->expects(self::once()) ->method('error'); $this->authenticator->authenticate($request); @@ -152,7 +153,7 @@ public function testAuthenticateInvalidUser() $existingToken = $this->getTokenInterfaceMock(); $existingToken - ->expects($this->once()) + ->expects(self::once()) ->method('getUsername') ->willReturn(__METHOD__); @@ -163,38 +164,38 @@ public function testAuthenticateInvalidUser() $usernamePasswordToken = new UsernamePasswordToken($username, $password, self::PROVIDER_KEY); $authenticatedToken = $this->getUsernamePasswordTokenMock(); $this->authenticationManager - ->expects($this->once()) + ->expects(self::once()) ->method('authenticate') - ->with($this->equalTo($usernamePasswordToken)) + ->with(self::equalTo($usernamePasswordToken)) ->willReturn($authenticatedToken); $this->tokenStorage - ->expects($this->once()) + ->expects(self::once()) ->method('setToken') ->with($authenticatedToken); $this->eventDispatcher - ->expects($this->once()) + ->expects(self::once()) ->method('dispatch') ->with( - $this->equalTo(new InteractiveLoginEvent($request, $authenticatedToken)), + self::equalTo(new InteractiveLoginEvent($request, $authenticatedToken)), SecurityEvents::INTERACTIVE_LOGIN ); $this->tokenStorage - ->expects($this->exactly(2)) + ->expects(self::exactly(2)) ->method('getToken') ->will( - $this->onConsecutiveCalls($existingToken, $authenticatedToken) + self::onConsecutiveCalls($existingToken, $authenticatedToken) ); $authenticatedToken - ->expects($this->once()) + ->expects(self::once()) ->method('getUser') ->willReturn('not_an_ibexa_user'); $this->logger - ->expects($this->once()) + ->expects(self::once()) ->method('error'); $this->authenticator->authenticate($request); @@ -209,7 +210,7 @@ private function createUser($userId) { $apiUser = $this->createMock(User::class); $apiUser - ->expects($this->any()) + ->expects(self::any()) ->method('getUserId') ->willReturn($userId); @@ -225,11 +226,11 @@ public function testAuthenticateUserConflict() $existingUser = $this->createUser(123); $existingToken = $this->getUsernamePasswordTokenMock(); $existingToken - ->expects($this->once()) + ->expects(self::once()) ->method('getUsername') ->willReturn(__METHOD__); $existingToken - ->expects($this->once()) + ->expects(self::once()) ->method('getUser') ->willReturn($existingUser); @@ -240,44 +241,44 @@ public function testAuthenticateUserConflict() $usernamePasswordToken = new UsernamePasswordToken($username, $password, self::PROVIDER_KEY); $authenticatedToken = $this->getUsernamePasswordTokenMock(); $this->authenticationManager - ->expects($this->once()) + ->expects(self::once()) ->method('authenticate') - ->with($this->equalTo($usernamePasswordToken)) + ->with(self::equalTo($usernamePasswordToken)) ->willReturn($authenticatedToken); $this->eventDispatcher - ->expects($this->once()) + ->expects(self::once()) ->method('dispatch') ->with( - $this->equalTo(new InteractiveLoginEvent($request, $authenticatedToken)), + self::equalTo(new InteractiveLoginEvent($request, $authenticatedToken)), SecurityEvents::INTERACTIVE_LOGIN ); $this->tokenStorage - ->expects($this->at(0)) + ->expects(self::at(0)) ->method('getToken') ->willReturn($existingToken); $this->tokenStorage - ->expects($this->at(1)) + ->expects(self::at(1)) ->method('setToken') ->with($authenticatedToken); $this->tokenStorage - ->expects($this->at(2)) + ->expects(self::at(2)) ->method('getToken') ->willReturn($authenticatedToken); $this->tokenStorage - ->expects($this->at(3)) + ->expects(self::at(3)) ->method('setToken') ->with($existingToken); $authenticatedUser = $this->createUser(456); $authenticatedToken - ->expects($this->once()) + ->expects(self::once()) ->method('getUser') ->willReturn($authenticatedUser); $this->configResolver - ->expects($this->once()) + ->expects(self::once()) ->method('getParameter') ->with('anonymous_user_id') ->willReturn(10); @@ -294,11 +295,11 @@ public function testAuthenticatePreviouslyAnonymous() $existingUser = $this->createUser($anonymousUserId); $existingToken = $this->getUsernamePasswordTokenMock(); $existingToken - ->expects($this->once()) + ->expects(self::once()) ->method('getUsername') ->willReturn(__METHOD__); $existingToken - ->expects($this->once()) + ->expects(self::once()) ->method('getUser') ->willReturn($existingUser); @@ -309,45 +310,45 @@ public function testAuthenticatePreviouslyAnonymous() $usernamePasswordToken = new UsernamePasswordToken($username, $password, self::PROVIDER_KEY); $authenticatedToken = $this->getUsernamePasswordTokenMock(); $this->authenticationManager - ->expects($this->once()) + ->expects(self::once()) ->method('authenticate') - ->with($this->equalTo($usernamePasswordToken)) + ->with(self::equalTo($usernamePasswordToken)) ->willReturn($authenticatedToken); $this->eventDispatcher - ->expects($this->once()) + ->expects(self::once()) ->method('dispatch') ->with( - $this->equalTo(new InteractiveLoginEvent($request, $authenticatedToken)), + self::equalTo(new InteractiveLoginEvent($request, $authenticatedToken)), SecurityEvents::INTERACTIVE_LOGIN ); $this->tokenStorage - ->expects($this->at(0)) + ->expects(self::at(0)) ->method('getToken') ->willReturn($existingToken); $this->tokenStorage - ->expects($this->at(1)) + ->expects(self::at(1)) ->method('setToken') ->with($authenticatedToken); $this->tokenStorage - ->expects($this->at(2)) + ->expects(self::at(2)) ->method('getToken') ->willReturn($authenticatedToken); $authenticatedUser = $this->createUser(456); $authenticatedToken - ->expects($this->once()) + ->expects(self::once()) ->method('getUser') ->willReturn($authenticatedUser); $this->configResolver - ->expects($this->once()) + ->expects(self::once()) ->method('getParameter') ->with('anonymous_user_id') ->willReturn($anonymousUserId); - $this->assertSame($authenticatedToken, $this->authenticator->authenticate($request)); + self::assertSame($authenticatedToken, $this->authenticator->authenticate($request)); } public function testAuthenticate() @@ -357,7 +358,7 @@ public function testAuthenticate() $existingToken = $this->getTokenInterfaceMock(); $existingToken - ->expects($this->once()) + ->expects(self::once()) ->method('getUsername') ->willReturn(__METHOD__); @@ -368,39 +369,39 @@ public function testAuthenticate() $usernamePasswordToken = new UsernamePasswordToken($username, $password, self::PROVIDER_KEY); $authenticatedToken = $this->getUsernamePasswordTokenMock(); $this->authenticationManager - ->expects($this->once()) + ->expects(self::once()) ->method('authenticate') - ->with($this->equalTo($usernamePasswordToken)) + ->with(self::equalTo($usernamePasswordToken)) ->willReturn($authenticatedToken); $this->eventDispatcher - ->expects($this->once()) + ->expects(self::once()) ->method('dispatch') ->with( - $this->equalTo(new InteractiveLoginEvent($request, $authenticatedToken)), + self::equalTo(new InteractiveLoginEvent($request, $authenticatedToken)), SecurityEvents::INTERACTIVE_LOGIN ); $this->tokenStorage - ->expects($this->at(0)) + ->expects(self::at(0)) ->method('getToken') ->willReturn($existingToken); $this->tokenStorage - ->expects($this->at(1)) + ->expects(self::at(1)) ->method('setToken') ->with($authenticatedToken); $this->tokenStorage - ->expects($this->at(2)) + ->expects(self::at(2)) ->method('getToken') ->willReturn($authenticatedToken); $authenticatedUser = $this->createUser(456); $authenticatedToken - ->expects($this->once()) + ->expects(self::once()) ->method('getUser') ->willReturn($authenticatedUser); - $this->assertSame($authenticatedToken, $this->authenticator->authenticate($request)); + self::assertSame($authenticatedToken, $this->authenticator->authenticate($request)); } public function testAuthenticatePreviousUserNonEz() @@ -411,11 +412,11 @@ public function testAuthenticatePreviousUserNonEz() $existingUser = $this->createMock(UserInterface::class); $existingToken = $this->getUsernamePasswordTokenMock(); $existingToken - ->expects($this->once()) + ->expects(self::once()) ->method('getUsername') ->willReturn(__METHOD__); $existingToken - ->expects($this->once()) + ->expects(self::once()) ->method('getUser') ->willReturn($existingUser); @@ -426,39 +427,39 @@ public function testAuthenticatePreviousUserNonEz() $usernamePasswordToken = new UsernamePasswordToken($username, $password, self::PROVIDER_KEY); $authenticatedToken = $this->getUsernamePasswordTokenMock(); $this->authenticationManager - ->expects($this->once()) + ->expects(self::once()) ->method('authenticate') - ->with($this->equalTo($usernamePasswordToken)) + ->with(self::equalTo($usernamePasswordToken)) ->willReturn($authenticatedToken); $this->eventDispatcher - ->expects($this->once()) + ->expects(self::once()) ->method('dispatch') ->with( - $this->equalTo(new InteractiveLoginEvent($request, $authenticatedToken)), + self::equalTo(new InteractiveLoginEvent($request, $authenticatedToken)), SecurityEvents::INTERACTIVE_LOGIN ); $this->tokenStorage - ->expects($this->at(0)) + ->expects(self::at(0)) ->method('getToken') ->willReturn($existingToken); $this->tokenStorage - ->expects($this->at(1)) + ->expects(self::at(1)) ->method('setToken') ->with($authenticatedToken); $this->tokenStorage - ->expects($this->at(2)) + ->expects(self::at(2)) ->method('getToken') ->willReturn($authenticatedToken); $authenticatedUser = $this->createUser(456); $authenticatedToken - ->expects($this->once()) + ->expects(self::once()) ->method('getUser') ->willReturn($authenticatedUser); - $this->assertSame($authenticatedToken, $this->authenticator->authenticate($request)); + self::assertSame($authenticatedToken, $this->authenticator->authenticate($request)); } public function testAuthenticatePreviousTokenNotUsernamePassword() @@ -468,7 +469,7 @@ public function testAuthenticatePreviousTokenNotUsernamePassword() $existingToken = $this->getTokenInterfaceMock(); $existingToken - ->expects($this->once()) + ->expects(self::once()) ->method('getUsername') ->willReturn(__METHOD__); @@ -479,51 +480,51 @@ public function testAuthenticatePreviousTokenNotUsernamePassword() $usernamePasswordToken = new UsernamePasswordToken($username, $password, self::PROVIDER_KEY); $authenticatedToken = $this->getUsernamePasswordTokenMock(); $this->authenticationManager - ->expects($this->once()) + ->expects(self::once()) ->method('authenticate') - ->with($this->equalTo($usernamePasswordToken)) + ->with(self::equalTo($usernamePasswordToken)) ->willReturn($authenticatedToken); $this->eventDispatcher - ->expects($this->once()) + ->expects(self::once()) ->method('dispatch') ->with( - $this->equalTo(new InteractiveLoginEvent($request, $authenticatedToken)), + self::equalTo(new InteractiveLoginEvent($request, $authenticatedToken)), SecurityEvents::INTERACTIVE_LOGIN ); $this->tokenStorage - ->expects($this->at(0)) + ->expects(self::at(0)) ->method('getToken') ->willReturn($existingToken); $this->tokenStorage - ->expects($this->at(1)) + ->expects(self::at(1)) ->method('setToken') ->with($authenticatedToken); $this->tokenStorage - ->expects($this->at(2)) + ->expects(self::at(2)) ->method('getToken') ->willReturn($authenticatedToken); $authenticatedUser = $this->createUser(456); $authenticatedToken - ->expects($this->once()) + ->expects(self::once()) ->method('getUser') ->willReturn($authenticatedUser); - $this->assertSame($authenticatedToken, $this->authenticator->authenticate($request)); + self::assertSame($authenticatedToken, $this->authenticator->authenticate($request)); } public function testLogout() { $sessionLogoutHandler = $this->createMock(SessionLogoutHandler::class); $sessionLogoutHandler - ->expects($this->never()) + ->expects(self::never()) ->method('logout'); $token = $this->getTokenInterfaceMock(); $this->tokenStorage - ->expects($this->once()) + ->expects(self::once()) ->method('getToken') ->willReturn($token); @@ -532,20 +533,20 @@ public function testLogout() $logoutHandler1 = $this->createMock(LogoutHandlerInterface::class); $logoutHandler1 - ->expects($this->once()) + ->expects(self::once()) ->method('logout') ->with( $request, - $this->isInstanceOf(Response::class), + self::isInstanceOf(Response::class), $token ); $logoutHandler2 = $this->createMock(LogoutHandlerInterface::class); $logoutHandler2 - ->expects($this->once()) + ->expects(self::once()) ->method('logout') ->with( $request, - $this->isInstanceOf(Response::class), + self::isInstanceOf(Response::class), $token ); @@ -553,7 +554,7 @@ public function testLogout() $this->authenticator->addLogoutHandler($logoutHandler1); $this->authenticator->addLogoutHandler($logoutHandler2); - $this->assertInstanceOf( + self::assertInstanceOf( Response::class, $this->authenticator->logout($request) ); diff --git a/tests/lib/UrlHandler/PatternTest.php b/tests/lib/UrlHandler/PatternTest.php index 9020486e..898ece39 100644 --- a/tests/lib/UrlHandler/PatternTest.php +++ b/tests/lib/UrlHandler/PatternTest.php @@ -4,6 +4,7 @@ * @copyright Copyright (C) Ibexa AS. All rights reserved. * @license For full copyright and license information view LICENSE file distributed with this source code. */ + namespace Ibexa\Tests\Rest\UrlHandler; use Ibexa\Contracts\Core\Repository\Exceptions\InvalidArgumentException; @@ -124,7 +125,7 @@ public function testParseUrl($type, $url, $values) { $urlHandler = $this->getWorkingUrlHandler(); - $this->assertSame( + self::assertSame( $values, $urlHandler->parse($url) ); @@ -189,7 +190,7 @@ public function testGenerateUrl($type, $url, $values) { $urlHandler = $this->getWorkingUrlHandler(); - $this->assertSame( + self::assertSame( $url, $urlHandler->generate($type, $values) ); From 5669d6bffaa899ee2e783e62b3638ba0eb406544 Mon Sep 17 00:00:00 2001 From: konradoboza <konrad.oboza@ibexa.co> Date: Mon, 20 May 2024 12:48:19 +0200 Subject: [PATCH 5/5] Fixed leftover legacy namespace --- phpstan-baseline.neon | 25 ------------------- .../ValueObjectVisitor/LocationTest.php | 4 +-- 2 files changed, 1 insertion(+), 28 deletions(-) diff --git a/phpstan-baseline.neon b/phpstan-baseline.neon index fb9859c7..bd905f18 100644 --- a/phpstan-baseline.neon +++ b/phpstan-baseline.neon @@ -9300,36 +9300,11 @@ parameters: count: 1 path: tests/lib/Server/Output/ValueObjectVisitor/LocationListTest.php - - - message: "#^Access to an undefined property Ibexa\\\\Tests\\\\Rest\\\\Server\\\\Output\\\\ValueObjectVisitor\\\\LocationTest\\:\\:\\$permissionResolverMock\\.$#" - count: 1 - path: tests/lib/Server/Output/ValueObjectVisitor/LocationTest.php - - - - message: "#^Access to property \\$id on an unknown class eZ\\\\Publish\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Location\\.$#" - count: 2 - path: tests/lib/Server/Output/ValueObjectVisitor/LocationTest.php - - - - message: "#^Call to method getContentInfo\\(\\) on an unknown class eZ\\\\Publish\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Location\\.$#" - count: 1 - path: tests/lib/Server/Output/ValueObjectVisitor/LocationTest.php - - - - message: "#^Instantiated class eZ\\\\Publish\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Location not found\\.$#" - count: 2 - path: tests/lib/Server/Output/ValueObjectVisitor/LocationTest.php - - message: "#^Method Ibexa\\\\Tests\\\\Rest\\\\Server\\\\Output\\\\ValueObjectVisitor\\\\LocationTest\\:\\:getDataForTestVisitLocationAttributesResolvesMainLocation\\(\\) return type has no value type specified in iterable type iterable\\.$#" count: 1 path: tests/lib/Server/Output/ValueObjectVisitor/LocationTest.php - - - message: "#^Parameter \\$location of method Ibexa\\\\Tests\\\\Rest\\\\Server\\\\Output\\\\ValueObjectVisitor\\\\LocationTest\\:\\:mockLoadLocation\\(\\) has invalid type eZ\\\\Publish\\\\Core\\\\Repository\\\\Values\\\\Content\\\\Location\\.$#" - count: 1 - path: tests/lib/Server/Output/ValueObjectVisitor/LocationTest.php - - message: "#^Method Ibexa\\\\Tests\\\\Rest\\\\Server\\\\Output\\\\ValueObjectVisitor\\\\NoContentTest\\:\\:testVisit\\(\\) should return string but return statement is missing\\.$#" count: 1 diff --git a/tests/lib/Server/Output/ValueObjectVisitor/LocationTest.php b/tests/lib/Server/Output/ValueObjectVisitor/LocationTest.php index 5236bddb..fdb75e0c 100644 --- a/tests/lib/Server/Output/ValueObjectVisitor/LocationTest.php +++ b/tests/lib/Server/Output/ValueObjectVisitor/LocationTest.php @@ -7,14 +7,13 @@ namespace Ibexa\Tests\Rest\Server\Output\ValueObjectVisitor; -use eZ\Publish\Core\Repository\Values\Content\Location; use Ibexa\Contracts\Core\Repository\ContentService; use Ibexa\Contracts\Core\Repository\LocationService; -use Ibexa\Contracts\Core\Repository\PermissionResolver; use Ibexa\Contracts\Core\Repository\Values\Content\ContentInfo; use Ibexa\Contracts\Core\Repository\Values\Content\Location as ApiLocation; use Ibexa\Core\Base\Exceptions\UnauthorizedException; use Ibexa\Core\Repository\Values\Content\Content; +use Ibexa\Core\Repository\Values\Content\Location; use Ibexa\Core\Repository\Values\Content\VersionInfo; use Ibexa\Core\Repository\Values\ContentType\ContentType; use Ibexa\Rest\Server\Output\ValueObjectVisitor; @@ -36,7 +35,6 @@ final class LocationTest extends ValueObjectVisitorBaseTest protected function setUp(): void { - $this->permissionResolverMock = $this->createMock(PermissionResolver::class); $this->locationServiceMock = $this->createMock(LocationService::class); $this->contentServiceMock = $this->createMock(ContentService::class);