DEV: Fix `qunit/no-negated-ok` (PR #14837)


I’m not sure this is actually better… It feels kinda similar to how Ruby’s unless blah can be much harder to read than if !blah :thinking:

I’m mostly after consistency. I’d be fine with either, as long it’s the only way we do such asserts. Though the upside of notOk() and avoiding negations are better error messages - we get to see what’s the actual returned value, instead of converting it to true or false.

Related: when we’re dealing with actual true and false values, we could use assert.true() and assert.false() to be more strict about the types. (it’s also a eslint-plugin-qunit rule) But that’s another call based on preference. 🤷

I agree with @davidtaylorhq here that notOk isn’t drastically better to me than ok with a ! operator. I am often a fan of consistency but how does this actually help us?

Ok, closing this. Will stick to only fixing asserts and dropping jQuery.