You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by David Glasser <gl...@mit.edu> on 2007/03/28 20:19:10 UTC
expects(ExpectationBuilder) method in Expectations?
One method that ExpectationGroupBuilder (ie, InThisOrder and
InAnyOrder) had that Expectations doesn't was the expects method:
public void expects(ExpectationGroupBuilder subgroupBuilder) {
elementBuilders.add(subgroupBuilder);
expectationBuilder = null;
}
This allowed me to factor out sets of expectations that were common to
several tests into helper methods that returned
ExpectationGroupBuilders, which were then included with expects().
This felt a little dirty (since it required referencing a class in
org.jmock.internal) but worked well. Any chance of reinstating it?
Or is there another workaround?
--dave
--
David Glasser | glasser@mit.edu | http://www.davidglasser.net/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Re: expects(ExpectationBuilder) method in Expectations?
Posted by David Glasser <gl...@mit.edu>.
Sorry, wrong dev@ list!
embarrassed,
dave
On 3/28/07, David Glasser <gl...@mit.edu> wrote:
> One method that ExpectationGroupBuilder (ie, InThisOrder and
> InAnyOrder) had that Expectations doesn't was the expects method:
>
> public void expects(ExpectationGroupBuilder subgroupBuilder) {
> elementBuilders.add(subgroupBuilder);
> expectationBuilder = null;
> }
>
> This allowed me to factor out sets of expectations that were common to
> several tests into helper methods that returned
> ExpectationGroupBuilders, which were then included with expects().
> This felt a little dirty (since it required referencing a class in
> org.jmock.internal) but worked well. Any chance of reinstating it?
> Or is there another workaround?
>
> --dave
>
> --
> David Glasser | glasser@mit.edu | http://www.davidglasser.net/
>
--
David Glasser | glasser@mit.edu | http://www.davidglasser.net/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org