[rspec-users] State-based expectations (as per jMock in GOOS)

Tom Stuart tom at experthuman.com
Fri Dec 18 09:46:50 EST 2009

On 18 Dec 2009, at 14:35, Ashley Moran wrote:
> The principle appears to be 
>  object O has sent message M => O is in state S
> followed by
>  O is in state S     => (expectation E met) passes spec
>  O is not in state S => (expectation E met) violates spec

Can you elaborate? From a position of no knowledge, the most obvious question to me is: why would I care about the state of O? Either the change in O's state is observable through its behaviour (in which case I specify that behaviour) or it's not (in which case I don't care).


More information about the rspec-users mailing list