From: Tim M. <tim...@po...> - 2003-06-29 22:57:14
|
Yes its missing in 0.09 - we should add this into the current head version (its trivial to do). Francois subclass Mock and add the sugar if you need it immediately. I would also advocate adding Chris' toString suggestion as well. In the meantime - while there is some push for Nat's branch going on - Sorry I'm not yet convinced by the direction. I'm particularly not convinced by adding additional names like matchNameAndReturn, nor the explosion of all generated types. There is a lot of discussion required to make that branch acceptable. Tim > -----Original Message----- > From: moc...@li... > [mailto:moc...@li...]On Behalf Of > Francois Beausoleil > Sent: 29 June 2003 02:48 > To: moc...@li... > Subject: [MO-java-dev] How to match and not return ? > > > Hi ! > > I need functionnality equivalent to expect(String, Object), but for > match(). Currently, in 0.09, there are matchAndReturn methods, but no > simple match(String). In this specific test instance, it does not matter > how many times I call method X as it has been asserted elsewhere that the > correct number of calls is made. > > Instead of: > mock.expect("eat", C.ANY_ARGS); > > I would like: > mock.match("eat", C.ANY_ARGS); > > This is something like the nice mock feature I spoke about a few weeks > back. What I want is no exception if I call the method 100 times or 10 > times. > > Thanks ! > François > -- > Francois Beausoleil > Developer of Java Gui Builder > http://jgb.sourceforge.net/ > > > ------------------------------------------------------- > This SF.Net email sponsored by: Free pre-built ASP.NET sites including > Data Reports, E-commerce, Portals, and Forums are available now. > Download today and enter to win an XBOX or Visual Studio .NET. > http://aspnet.click-url.com/go/psa00100006ave/direct;at.asp_061203_01/01 > _______________________________________________ > Mockobjects-java-dev mailing list > Moc...@li... > https://lists.sourceforge.net/lists/listinfo/mockobjects-java-dev > > --- > Incoming mail is certified Virus Free. > Checked by AVG anti-virus system (http://www.grisoft.com). > Version: 6.0.490 / Virus Database: 289 - Release Date: 16/06/2003 > --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.490 / Virus Database: 289 - Release Date: 16/06/2003 |