mirror of
https://github.com/status-im/realm-js.git
synced 2025-01-11 23:04:29 +00:00
catch errors thrown from tests and display error information
This commit is contained in:
parent
39b262b279
commit
2384f2cf9b
@ -28,7 +28,6 @@ function runTests() {
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
console.log('-', testName);
|
|
||||||
|
|
||||||
if (testSuite.beforeEach) {
|
if (testSuite.beforeEach) {
|
||||||
testSuite.beforeEach();
|
testSuite.beforeEach();
|
||||||
@ -36,6 +35,11 @@ function runTests() {
|
|||||||
|
|
||||||
try {
|
try {
|
||||||
testSuite[testName]();
|
testSuite[testName]();
|
||||||
|
console.log('+ ' + testName);
|
||||||
|
}
|
||||||
|
catch (e) {
|
||||||
|
console.log('- ' + testName);
|
||||||
|
console.warn(e);
|
||||||
}
|
}
|
||||||
finally {
|
finally {
|
||||||
if (testSuite.afterEach) {
|
if (testSuite.afterEach) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user