Task #87973

LinkGeneratorTests should use a proper backend user context for versioned link generation checks

Added by Benjamin Franzke about 2 months ago. Updated 13 days ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Tests
Start date:
2019-03-21
Due date:
% Done:

100%

TYPO3 Version:
10
PHP Version:
Tags:
Complexity:
Sprint Focus:

Description

Currently typo3/sysext/frontend/Tests/Functional/SiteHandling/SlugLinkGeneratorTest.php linkIsGeneratedForPageVersionDataProvider() does only specify a workspaceId, but misses a backend user id.

In that case the workspace id was ignored ignored by the test framework, see TYPO3\JsonResponse\Middleware\BackendUserMiddleware: https://github.com/TYPO3/testing-framework/blob/3d03574ce47d247f1c893cd8bd49292982418d0b/Resources/Core/Functional/Extensions/json_response/Classes/Middleware/BackendUserHandler.php#L53-L54

Some of the current todos fail because the test context is wrong.

Associated revisions

Revision 3cc78c96 (diff)
Added by Benjamin Franzke about 2 months ago

[TASK] Add be_user id to LinkGenerator page-version test context

Some of the previous todos were failing because the test context
contained a workspace id, but missed a backend user id.
In that case the workspace id was ignored by the test
framework (see TYPO3\JsonResponse\Middleware\BackendUserMiddleware).

This patch also adapts the SlugLinkGeneratorTest to check link
generation to versioned record both with and without a backend user
authentication.

Releases: master, 9.5
Resolves: #87973
Change-Id: I0a2ec41234963fd8af0ed3adf951f139f1e85215
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/60302
Tested-by: Daniel Goerz <>
Tested-by: TYPO3com <>
Tested-by: Oliver Hader <>
Reviewed-by: Daniel Goerz <>
Reviewed-by: Oliver Hader <>

Revision 1283168b (diff)
Added by Oliver Hader about 2 months ago

[TASK] Add be_user id to LinkGenerator page-version test context

Some of the previous todos were failing because the test context
contained a workspace id, but missed a backend user id.
In that case the workspace id was ignored by the test
framework (see TYPO3\JsonResponse\Middleware\BackendUserMiddleware).

This patch also adapts the SlugLinkGeneratorTest to check link
generation to versioned record both with and without a backend user
authentication.

Releases: master, 9.5
Resolves: #87973
Change-Id: I0a2ec41234963fd8af0ed3adf951f139f1e85215
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/60328
Tested-by: TYPO3com <>
Tested-by: Oliver Hader <>
Reviewed-by: Oliver Hader <>

History

#1 Updated by Gerrit Code Review about 2 months ago

  • Status changed from New to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/60302

#2 Updated by Gerrit Code Review about 2 months ago

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/60302

#3 Updated by Gerrit Code Review about 2 months ago

Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/60302

#4 Updated by Gerrit Code Review about 2 months ago

Patch set 1 for branch 9.5 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/60328

#5 Updated by Benjamin Franzke about 2 months ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100

#6 Updated by Gerrit Code Review about 2 months ago

  • Status changed from Resolved to Under Review

Patch set 2 for branch 9.5 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/60328

#7 Updated by Oliver Hader about 2 months ago

  • Status changed from Under Review to Resolved

#8 Updated by Benni Mack 13 days ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF