[mocha-developer] Expectations on portions of arguments called.
James Mead
jamesmead44 at gmail.com
Wed Sep 12 05:03:19 EDT 2007
You should be able to do this with the has_entry parameter matcher (
http://mocha.rubyforge.org/classes/Mocha/ParameterMatchers.html#M000010)
something like this...
def test_referring_journals_should_order_by_citation_count
article = articles(:highly_cited_article)
Journal.expects(:find).with(:first, has_entry(:order, 'citations_count
DESC'))
article.referring_journals
end
Let me know if I've misunderstood.
--
James.
http://blog.floehopper.org
http://tumble.floehopper.org
More information about the mocha-developer
mailing list