We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 51c5cb0 commit c4dc4b5Copy full SHA for c4dc4b5
1 file changed
packages/jest-jasmine2/src/queue_runner.js
@@ -71,10 +71,15 @@ function queueRunner(options: Options) {
71
);
72
};
73
74
- return options.queueableFns.reduce(
75
- (promise, fn) => promise.then(() => mapper(fn)),
76
- Promise.resolve(),
77
- );
+ return PCancelable.fn(onCancel => {
+ onCancel(() => {
+ token.cancel();
+ });
78
+ return options.queueableFns.reduce(
79
+ (promise, fn) => promise.then(() => mapper(fn)),
80
+ Promise.resolve(),
81
+ );
82
83
}
84
85
module.exports = queueRunner;
0 commit comments