mirror of
https://github.com/wassname/DefinitelyTyped.git
synced 2026-09-06 16:20:26 +08:00
Added global fail() function to Jasmine typings
This commit is contained in:
@@ -714,6 +714,22 @@ describe("Asynchronous specs", function () {
|
||||
});
|
||||
});
|
||||
|
||||
describe("Fail", function () {
|
||||
|
||||
it("should fail test when called without arguments", function () {
|
||||
fail();
|
||||
});
|
||||
|
||||
it("should fail test when called with a fail message", function () {
|
||||
fail("The test failed");
|
||||
});
|
||||
|
||||
it("should fail test when called an error", function () {
|
||||
fail(new Error("The test failed with this error"));
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
(() => {
|
||||
// from boot.js
|
||||
var env = jasmine.getEnv();
|
||||
|
||||
Vendored
+2
@@ -33,6 +33,8 @@ declare function afterAll(action: (done: () => void) => void): void;
|
||||
declare function expect(spy: Function): jasmine.Matchers;
|
||||
declare function expect(actual: any): jasmine.Matchers;
|
||||
|
||||
declare function fail(e?: any): void;
|
||||
|
||||
declare function spyOn(object: any, method: string): jasmine.Spy;
|
||||
|
||||
declare function runs(asyncMethod: Function): void;
|
||||
|
||||
Reference in New Issue
Block a user