From: Nat P. <nat...@b1...> - 2002-11-19 18:22:08
|
On Tue, 2002-11-19 at 17:30, Barry Kaplan wrote: > Nat Pryce wrote: > > The Constraints do not have any knowledge of the class of the object > > being constraint, except for the IsInstanceOf constraint, which is a > > special case. > But they have the object being constrained. The object knows its > Class. Am I missing something? The MockCall object passes the method arguments to the constraints when it is called. Each constraint returns true if the argument that it is checking meets the constraint or false if it doesn't. If any constraint returns false, the MockCall throws an AssertionFailedError. Cheers, Nat. -- Nat Pryce <nat...@b1...> B13media |