Closed fritsvt closed 5 years ago
Thanks! I'm sorry I saw the PR yesterday and worked today on fixing the tests. It seems we have both fixed the test, sorry about that!
I managed to include some of your commit into that branch, I'll push a PR. I decided to mimic the behavior of the AppFactory
from Slim, instead of extending App
. I think that will be more in line with what's documented in Slim.
Alright, I wasn't sure what to do with the behaviour so I decided to keep it the same in the end. But I agree that keeping it similar to the framework is better. New PR looks good 👍
Closing this so v4 can move to #47
Did some hacking today and managed to get it working in Slim 4.
I still need to clean things up and add/change tests but it all seems to work so far.
I had to change the way the App gets created because this seemed to have changed in Slim 4.
A basic example of booting up an app would now look like this:
Will continue to work on this in the coming days to hopefully get it all working.
EDIT: Changed the behaviour to still be the same as before. So the DI-Bridge App would accept the same parameters as the
Appfactory::create
method does. Only changed it so thecontainer
becomes the first parameter because that's the one people would use most.Example would now look like:
So this would create a DI container for you
I removed the ErrorTest and ContainerTest because I think that behaviour changed. But please let me know if I'm wrong there.
I can't seem to fix one of the Travis checks. So if someone knows why that's failing please let me know.
@mnapoli when you have time, please let me know what you think :)
resolves #22