Skip to content
This repository was archived by the owner on Feb 26, 2024. It is now read-only.

Commit a85fd68

Browse files
committed
fix(jasmine): propagate all arguments of it/describe/etc...
1 parent 5f1ea90 commit a85fd68

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

lib/jasmine/jasmine.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -39,14 +39,16 @@
3939
});
4040
['it', 'xit', 'fit'].forEach((methodName) => {
4141
let originalJasmineFn: Function = jasmineEnv[methodName];
42-
jasmineEnv[methodName] = function(description: string, specDefinitions: Function) {
43-
return originalJasmineFn.call(this, description, wrapTestInZone(specDefinitions));
42+
jasmineEnv[methodName] = function(description: string, specDefinitions: Function, timeout: number) {
43+
arguments[1] = wrapTestInZone(specDefinitions);
44+
return originalJasmineFn.apply(this, arguments);
4445
}
4546
});
4647
['beforeEach', 'afterEach'].forEach((methodName) => {
4748
let originalJasmineFn: Function = jasmineEnv[methodName];
4849
jasmineEnv[methodName] = function(specDefinitions: Function) {
49-
return originalJasmineFn.call(this, wrapTestInZone(specDefinitions));
50+
arguments[0] = wrapTestInZone(specDefinitions);
51+
return originalJasmineFn.apply(this, arguments);
5052
}
5153
});
5254

0 commit comments

Comments
 (0)