[BUGFIX] Clean up error handler for site handling 57/57057/4
authorBenni Mack <benni@typo3.org>
Sun, 27 May 2018 15:11:46 +0000 (17:11 +0200)
committerGeorg Ringer <georg.ringer@gmail.com>
Mon, 28 May 2018 19:14:51 +0000 (21:14 +0200)
commit80b29e6cdae09a4352b897fc7d7681f2f256bcee
treec4967e3421ea525f2d314868b084ed7ebdf7162a
parent9301ce961038ee6835fea495d87e1415161228fd
[BUGFIX] Clean up error handler for site handling

This patch handles several issues related to the new
site error handling introduced in TYPO3 v9.2.0:

1. It adds unit tests
2. It adds a missing exception when an error handler
is configured which does not implement the PageErrorHandlerInterface
3. It fixes one minor issue in PageContentErrorHandler
where a wrong "InvalidArgumentException" was thrown
4. All PageErrorHandler logic was moved from EXT:frontend
to EXT:core, as this would be a penalty across packages -
the "Site" entity depends on them, so they must go to the same
package (core).

Releases: master
Resolves: #85101
Change-Id: Ibdc05024abd7c719dd8d5dcb3388bf1679b69990
Reviewed-on: https://review.typo3.org/57057
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Tested-by: Wouter Wolters <typo3@wouterwolters.nl>
Reviewed-by: Georg Ringer <georg.ringer@gmail.com>
Tested-by: Georg Ringer <georg.ringer@gmail.com>
typo3/sysext/core/Classes/Error/PageErrorHandler/FluidPageErrorHandler.php [new file with mode: 0644]
typo3/sysext/core/Classes/Error/PageErrorHandler/InvalidPageErrorHandlerException.php [new file with mode: 0644]
typo3/sysext/core/Classes/Error/PageErrorHandler/PageContentErrorHandler.php [new file with mode: 0644]
typo3/sysext/core/Classes/Error/PageErrorHandler/PageErrorHandlerInterface.php [new file with mode: 0644]
typo3/sysext/core/Classes/Site/Entity/Site.php
typo3/sysext/core/Tests/Unit/Site/Entity/SiteTest.php [new file with mode: 0644]
typo3/sysext/frontend/Classes/PageErrorHandler/FluidPageErrorHandler.php [deleted file]
typo3/sysext/frontend/Classes/PageErrorHandler/PageContentErrorHandler.php [deleted file]
typo3/sysext/frontend/Classes/PageErrorHandler/PageErrorHandlerInterface.php [deleted file]