Stub behavior in ver 3.4

9 views
Skip to first unread message

Dmitry Gusarov

unread,
Jun 11, 2008, 9:43:27 AM6/11/08
to Rhino.Mocks
Hello,

Recently we upgraded from Rhino Mock 3.1 to 3.4. All features look
fine, but yesterday we suddenly caught a problem:

var mocks = new MockRepository();
var my = mocks.Stub<ITest>();

my.Update();

mocks.ReplayAll();

//my.Update();

mocks.VerifyAll();

In the previous build this test example was red, but now it is green.
We are forced to rollback to a previous build, because some number of
test expects such behaviour.

Can anyone describe is it a bug or a planned change?

Ayende Rahien

unread,
Jun 12, 2008, 5:15:39 AM6/12/08
to Rhino...@googlegroups.com
Stub() cannot have expectations and will never fail the test.
Use DynamicMock instead.
Reply all
Reply to author
Forward
0 new messages