-
Notifications
You must be signed in to change notification settings - Fork 195
Description
I am running a test of a controller that returns void. It automates pulling data via an API call and updates a db table.
In the test, since I am using request, I addCallables which point to Mock_Libraries.
When the Controller attempts to load the class being mocked, I get a response about the Resource exists but is not an Instance of that class. This therefore returns a 500 vs a 200.
Also, when I use the Mock_Libraries and try to use verifyInvoked causes 'Call to undefined method 'expects'.
Should that method be added to the Mock_Libraries_ file?
Is there a better way?
Is there a way to verify invocation on MonkeyPatched calls?
I found MonkeyPatch::verifyInvoke methods in the docs, but I get 0 invocations even though the logs show the patched response is returned. Do the verifyInvoked method params have to match values used in the controller?