Currently ([email protected]
) the MockActionContext
executes actions in a synchronous manner, which differs from how the actions are executed with the real Fluxible action context. We have found that this introduces inconsistencies when testing nested actions (actions that call other actions) since the callbacks for the nested action will not be called in the correct order or at all. This means that some tests were not even executing the callbacks that contained the test assertions.
To fix this, we are unifying the MockActionContext and ActionContext implementation so that they are identical. This guarantees that the tests will be asserting against the real executeAction implementation.
While the changes should not impact most users, there are some cases where a unit test could be relying on the execution order of parallel actions which could be broken. I have tested against several of the largest codebases inside Yahoo to see how large the impact would be and