Task #52868
Enable mock of ResourceFactory in ContentObjectRenderer
Status: | Resolved | Start date: | 2013-10-15 | |
---|---|---|---|---|
Priority: | Should have | Due date: | ||
Assigned To: | - | % Done: | 100% |
|
Category: | Unit/Functional Tests | Spent time: | - | |
Target version: | 6.2.0 | |||
TYPO3 Version: | 6.2 | Complexity: | easy | |
PHP Version: | 5.4 | Sprint Focus: |
Related issues
Associated revisions
[TASK] Enable mock of ResourceFactory in ContentObjectRenderer
ext:frontend ContentObjectRenderer calls ResourceFactory::getInstance
at various places. This static call can not be mocked and is a hard
dependency to FAL.
The patch encapsulates the static call in a method and uses this
to mock instances of the ResourceFactory within some tests to have
controlled return values.
As a side effect one test does not fail anymore if only the
ext:frontend tests are executed and not the whole test suite. The
according hook-test was renamed and now tests the method that calls
the hook directly.
Change-Id: I0ee75462b7e7f25f70c6c8fb132045084b9ac537
Resolves: #52868
Resolves: #52643
Releases: 6.2
Reviewed-on: https://review.typo3.org/24821
Reviewed-by: Wouter Wolters
Tested-by: Wouter Wolters
Reviewed-by: Christian Kuhn
Tested-by: Christian Kuhn
History
#1 Updated by Gerrit Code Review almost 2 years ago
- Status changed from New to Under Review
Patch set 1 for branch master has been pushed to the review server.
It is available at https://review.typo3.org/24821
#2 Updated by Gerrit Code Review almost 2 years ago
Patch set 2 for branch master has been pushed to the review server.
It is available at https://review.typo3.org/24821
#3 Updated by Christian Kuhn almost 2 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset 684acdd316ada696c10ecf2d0daa58544ab9d2e7.