Add have_ predicate matcher
Similar to the be_
predicate matcher. The have_
predicate matcher would check an equivalent has_
method. Additionally, it could take arguments for the underlying method.
expect(foo).to have_thing(:foo)
# Would be equivalent to:
expect(foo.has_thing?(:foo)).to be_true
RSpec has support for this matcher.
Edited by Mike Miller