Commit d6198835 by Prem Sichanugrist

Patch `window.it` to raise error on pending tests

parent 27c83bd6
......@@ -7,3 +7,12 @@ jQuery.cookie = (key, value) =>
@stubCookies[key] = value
else
@stubCookies[key]
# Path Jasmine's `it` method to raise an error when the test is not defined.
# This is helpful when writing the specs first before writing the test.
@it = (desc, func) ->
if func?
jasmine.getEnv().it(desc, func)
else
jasmine.getEnv().it desc, ->
throw "test is undefined"
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment