mirror of
https://github.com/FlipsideCrypto/DefinitelyTyped.git
synced 2026-02-06 10:56:53 +00:00
adjusted jasmine tests
This commit is contained in:
parent
fb67861390
commit
946862740a
@ -60,7 +60,7 @@ describe("Included matchers:", () => {
|
||||
foo: 'foo'
|
||||
};
|
||||
expect(a.foo).toBeDefined();
|
||||
expect(a.bar).not.toBeDefined();
|
||||
expect((<any>a).bar).not.toBeDefined();
|
||||
});
|
||||
|
||||
it("The `toBeUndefined` matcher compares against `undefined`", () => {
|
||||
@ -68,7 +68,7 @@ describe("Included matchers:", () => {
|
||||
foo: 'foo'
|
||||
};
|
||||
expect(a.foo).not.toBeUndefined();
|
||||
expect(a.bar).toBeUndefined();
|
||||
expect((<any>a).bar).toBeUndefined();
|
||||
});
|
||||
|
||||
it("The 'toBeNull' matcher compares against null", () => {
|
||||
@ -120,7 +120,7 @@ describe("Included matchers:", () => {
|
||||
return 1 + 2;
|
||||
};
|
||||
var bar = () => {
|
||||
return a + 1;
|
||||
//return a + 1;
|
||||
};
|
||||
expect(foo).not.toThrow();
|
||||
expect(bar).toThrow();
|
||||
@ -439,7 +439,7 @@ describe("Asynchronous specs", () => {
|
||||
currentWindowOnload(null);
|
||||
}
|
||||
|
||||
document.querySelector('.version').innerHTML = jasmineEnv.versionString();
|
||||
(<HTMLElement>document.querySelector('.version')).innerHTML = jasmineEnv.versionString();
|
||||
execJasmine();
|
||||
};
|
||||
|
||||
|
||||
5
jasmine/jasmine.d.ts
vendored
5
jasmine/jasmine.d.ts
vendored
@ -23,7 +23,6 @@ declare function runs(asyncMethod: Function): void;
|
||||
declare function waitsFor(latchMethod: () => bool, failureMessage: string, timeout?: number): void;
|
||||
declare function waits(timeout?: number): void;
|
||||
|
||||
|
||||
declare module jasmine {
|
||||
|
||||
var Clock: Clock;
|
||||
@ -165,6 +164,8 @@ declare module jasmine {
|
||||
toBeLessThan(expected): bool;
|
||||
toBeGreaterThan(expected): bool;
|
||||
toBeCloseTo(expected, precision): bool;
|
||||
toContainHtml(expected: string): bool;
|
||||
toContainText(expected: string): bool;
|
||||
toThrow(expected? ): bool;
|
||||
not: Matchers;
|
||||
|
||||
@ -291,4 +292,6 @@ declare module jasmine {
|
||||
Clock: Clock;
|
||||
util: Util;
|
||||
}
|
||||
|
||||
export var HtmlReporter: any;
|
||||
}
|
||||
Loading…
Reference in New Issue
Block a user