wrong icon indicating copy to clipboard operation
wrong copied to clipboard

Puzzling behavior with eventually and rspec be_nil matcher

Open ziobrando opened this issue 13 years ago • 0 comments

I found an odd behavior when using eventually and should_not be_nil.

it "should work with be_nil" do
    found = "X"
    eventually {
      found.should_not be_nil
    }
end

Error message is:

Expected found.should_not(be_nil), but found is "X" be_nil is #<RSpec::Matchers::BuiltIn::BeNil:0x007ff531aea8e8 @expected=nil>

Am I doing anything wrong?

ziobrando avatar Jan 09 '13 09:01 ziobrando