EDIT: I have not seen an extension method before Stub, just a method in the repository.
I suspect that the main difference is that you can call Stubwhen the layout is in any mode (playback or recording). It will temporarily return it to recording mode, record the action, and then return to playback if it starts playback in playback mode.
It also allows you to cut out multiple actions in a single lambda expression if you only need one of the actions (the last) to return the result.
source
share