Feature #30018

For functional tests: provide function for forgetting instances

Added by Robert Lemke about 10 years ago. Updated about 10 years ago.

Status:
Resolved
Priority:
Should have
Assignee:
Category:
Object
Start date:
2011-09-19
Due date:
% Done:

100%

Estimated time:
PHP Version:
Has patch:
Complexity:

Description

In some situations during functional testing, it is necessary to drop a registered singleton instance before / after running a single test, to make sure that a fresh one is used for the next test.

One example is the TYPO3CR NodeRepository which keeps track of added objects. Instead of implementing a special tearDown() method for that NodeRepository, it would be much cleaner to just drop the instance and thus getting a fresh NodeRepository for the next test.

Also available in: Atom PDF