codeception icon indicating copy to clipboard operation
codeception copied to clipboard

Broken with cakephp 3.6

Open icex opened this issue 7 years ago • 5 comments
trafficstars

I recently upgraded to cake 3.6 and all my tests are broken.

  • Routes are not loaded at runtime, amOnRoute cannot be used(nothing is found). [Cake\Routing\Exception\MissingRouteException] A route matching "array (...
  • Router::reload(); in reloadRoutes can result in 'duplicate routes' errors. see https://github.com/cakephp/app/issues/593
  • Lots of deprecated errors. Event::$data is deprecated. Use Event::getData() instead. eventManager() is deprecated. Use getEventManager()/setEventManager() instead. etc..

icex avatar Aug 17 '18 11:08 icex

Would you like to send a pull request with the fix for this issue?

lorenzo avatar Aug 17 '18 11:08 lorenzo

Hi, working on it :)

icex avatar Aug 17 '18 11:08 icex

Also note that "Lots of deprecated errors" doesnt mean broken. It can and should then just be silenced. It is good to support more than just the latest minor if possible here anyway. Only force ^3.6 as dependency here if really necessary and one is forced to use a new method that is only available in this new minor.

dereuromark avatar Aug 17 '18 11:08 dereuromark

@icex Thanks so much!

lorenzo avatar Aug 17 '18 11:08 lorenzo

I have got it working on my branch (only for the latest version of cake, it should be 4.x ready) https://github.com/icex/codeception

I'll submit a PR after more testing and add back support for older versions

icex avatar Aug 20 '18 09:08 icex