Java Mailing List Archive

http://www.gg3721.com/

Home » user.jmock »

[jmock-user] ignoring except never for one method

tominich

2012-06-21

Replies: Find Java Web Hosting

Author LoginPost Reply

I want to ignore all calls on an object but not allow one particular call

eg Ithought this should work, but it allows the kill method to be called too

never(conversation).kill(with(any(String.class)));
ignoring(conversation);

I don't want to have to specify every call on conversation - that makes the
test brittle as the class is tweaked/refactored
--
Sent from the jMock - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

  http://xircles.codehaus.org/manage_email


©2008 gg3721.com - Jax Systems, LLC, U.S.A.