Closed jordanlibrande closed 9 years ago
It looks like this feature is undocumented, but it should work to do:
allow(Foo).baz.and_return(object_a, object_b)
The first call will return object_a, the second object_b, and every call after that object_b.
I will update the docs to include this.
I would love if there was a nicer way to specify a series of return values for multiple calls to the same function than the following (best I've found).