New mock objects framework

Robert Krahn robert.krahn at student.hpi.uni-potsdam.de
Tue Sep 18 23:01:09 UTC 2007


Hello Denis,

I dipped into your BehaviorMockup package and it seems really  
powerful. I like the block notation so that the expected behavior is  
stated after the exercised code. This way the tests can be more  
uniform (Four-Phase Test) and clearer.

One thing I didn't found out is how to have the mocks ignore certain  
message calls.
E.g. I want this to pass:
[:mock | mock m1; m2] should lenient satisfy: [:mock | mock m1]

I tried it the 'lenient way' as above but I get a SpecFailed:  
WrongMessageSelector. How can one do this?

Best regards,
Robert

Am 20.08.2007 um 11:32 schrieb Denis Kudriashov:

> I realize new smalltalk mock objects framework named BehaviorMockup  
> with SSpec functionality.
> There is Squeak (http://www.squeaksource.com/BehaviorMockup.html)  
> and VW versions (cincom public repository)
>
> Simplest language for behavior specfications:
> [:mock | mock someMessage] should strictly satisfy: [:mock | mock  
> someMessage willReturn: 'some']
>
> or
>
> [:mock | mock someMessage] should lenient satisfy: [:mock | mock  
> someMessage willReturn: 'some']
>
> SSpec functionality:
>
> 5 should equals: 6
> and ...
> For more detailes see Wiki on SqueakSource and many acceptance  
> tests in package
>
> Best regards,
> Denis
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20070919/805b1b3f/attachment.htm


More information about the Squeak-dev mailing list