specta / expecta

A Matcher Framework for Objective-C/Cocoa

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

`expect(nil).notTo.beNil;` doesn't fail

xareelee opened this issue · comments

I tried the follow expectation:

expect(nil).toNot.beNil;
expect(nil).notTo.beNil;
expect(nil).to.beNil;

but all of them were not failed which first two should be.

You are missing the parens to invoke the matcher beNil e.g.

expect(nil).toNot.beNil()

Gosh! I'm so stupid that I didn't notice this. Maybe try to let the compiler complain this situation when this happens.

Thanks for your rapidly reply.