-
Notifications
You must be signed in to change notification settings - Fork 776
Create an inconclusive assertion #326
Copy link
Copy link
Closed
Labels
Description
The inconclusive assert would be used as follows:
test("My test", function () {
inconclusive();
// or with message
inconclusive("The submit click handler needs a test case");
});When run the, the test would display in (say) orange (compared to red for fail and green for pass) , with the provided message or the default "Test pending" message.
We've hacked this together to work for us, here is a snippet that adds a class for the styling.
li.className = assertion.result === null ? "inconclusive" : (assertion.result ? "pass" : "fail");
It would be great if this can be included in the API.
It has proven very useful for creating place-holders for pending tests, and also for frameworks on top of QUnit that iterate an object and flag untested methods.
Thanks.
Noel
Reactions are currently unavailable