[rspec-users] .with(:anything) issue
dchelimsky at gmail.com
Thu Nov 13 08:45:24 EST 2008
On Thu, Nov 13, 2008 at 7:44 AM, Matt Wynne <matt at mattwynne.net> wrote:
> On 13 Nov 2008, at 13:42, David Chelimsky wrote:
>> On Thu, Nov 13, 2008 at 7:38 AM, Emmanuel Pirsch <emmanuel at pirsch.org>
>>> I'm using a expectation like this :
>>> repository.should_receive(:add_gem).with("test.txt", :anything)
>> Try the anything() method. Support for symbols as argument matchers
>> was deprecated and removed.
>> Are you still seeing docs somewhere that talk about using symbols?
> I know I always go on about this (and never do anything about it) but the
> symbols are still all over the docs:
>> Argument Constraints
>> Constraints can be placed on individual arguments which are looser than
>> equivalence (as above).
>> accepts any value for this argument, e.g.:
>> my_mock.should_receive(:msg).with(1, :anything, "A")
There is just no time for the present.
Update coming shortly.
> rspec-users mailing list
> rspec-users at rubyforge.org
More information about the rspec-users