flow-development-collection
flow-development-collection copied to clipboard
!!! WIP BUGFIX instantiation of singletons with new should fail?
see https://github.com/neos/flow-development-collection/issues/3078
@robertlemke i talked with you about this behaviour and i could reproduce it as described to you in this test. What do you say, is this intended behaviour?
it does makes sense from a technical point of view, why it behaves like this, because the proxy contains this line in the constructor:
if (get_class($this) === 'Neos\Flow\Tests\Functional\ObjectManagement\Fixtures\SingletonClassA') \Neos\Flow\Core\Bootstrap::$staticObjectManager->setInstance('Neos\Flow\Tests\Functional\ObjectManagement\Fixtures\SingletonClassA', $this);
Upgrade instructions
Review instructions
Checklist
- [ ] Code follows the PSR-2 coding style
- [ ] Tests have been created, run and adjusted as needed
- [ ] The PR is created against the lowest maintained branch
- [ ] Reviewer - PR Title is brief but complete and starts with
FEATURE|TASK|BUGFIX - [ ] Reviewer - The first section explains the change briefly for change-logs
- [ ] Reviewer - Breaking Changes are marked wit
!!!and have upgrade-instructions