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 ec53f1a commit ec78f7dCopy full SHA for ec78f7d
1 file changed
packages/jest-jasmine2/src/jasmine/Env.js
@@ -188,18 +188,13 @@ module.exports = function(j$) {
188
}
189
190
const uncaught = err => {
191
- let name;
192
- let current;
193
if (currentSpec) {
194
- current = currentSpec;
195
- name = current.getFullName();
196
- current.onException(err);
197
- current.cancel();
198
- // TODO: how to cancel the current running spec
+ currentSpec.onException(err);
+ currentSpec.cancel();
199
} else {
200
- // TODO: Handle top level failures
+ console.error('Unhandled error');
+ console.error(err.stack);
201
202
- // console.error('caught in ' + name);
203
};
204
205
process.on('uncaughtException', uncaught);
0 commit comments