-
Notifications
You must be signed in to change notification settings - Fork 61
Conversation
]]); | ||
$this->setExpectedException('Zend\ServiceManager\Exception\InvalidServiceException'); | ||
$this->setExpectedException('Zend\View\Exception\InvalidHelperException'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will need to check for a different exception depending on whether it's run under v2 or v3. Easiest way is to call a getInvalidServiceException()
method in the same way the CommonPluginManagerTrait
does. Or, if it's not a whole load of retooling, use the trait in this test and ditch the compatibility test.
Good stuff! Don't forget to add this to https://github.com/zendframework/maintainers/wiki/ZF3-ServiceManager-component-refactors,-phase-2 |
I updated the code according to kynx's feedback. I tested it with ServiceManager v3 (by temporarily setting required version as |
@mtymek The approach I've been using for dependencies that are in the
This works in most situations, particularly when we start seeing circular dependencies (essentially, any zend-mvc dependency observed is likely a circular dependency at this point). In this particular component, we have forwards-compat changes for a good portion of the components listed in the I'm willing to do that work today when merging; zend-view is a dep for a number of other components (navigation and form in particular), so this would help unblock some of those. |
Helper\EscapeHtml::class => InvokableFactory::class, | ||
'zendviewhelperescapehtml' => InvokableFactory::class, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Separate the FQCN and normalized names, and group them by type. This will allow us to remove the normalized versions more easily at a later date. (I can do this on merge if needed.)
|
As per your suggestion, I marked some tests as "skipped". Unfortunately I still get some errors in
How can I work around it? edit: pasted wrong error before... |
@mtymek ha! I've already pulled locally to review! In that particular case, the plugin requires zend-session, which does not have a forwards-compat version yet. As such, I'd override the Since I'm in the process of review anyways, I can do that for you if you'd like. |
OK, please do - I was about to finish for today :-) |
[WIP] V3 readiness
Merged with #42! |
This PR prepares
zend-view
for supporting ServiceManager v3.zend-mvc
is v3-compatibleLast element is blocked by zendframework/zend-cache#68 - SMv3 cannot be installed at this moment because cache component is not V3-ready.
Edit:
zend-cache
was fixed, apparentlyzend-mvc
is the blocker now.