Skip to content

Commit 936e18a

Browse files
author
cloudhead
committed
fix some error messages
1 parent 64760fe commit 936e18a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/vows.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ function addVow(vow) {
7777
if (vow.callback.length >= 2 || !batch.suite.options.error) {
7878
runTest([err]);
7979
} else {
80-
output('errored', { type: 'promise', error: err });
80+
output('errored', { type: 'promise', error: err.stack || err.message || JSON.stringify(err) });
8181
}
8282
vows.tryEnd(batch);
8383
});
@@ -98,7 +98,7 @@ function addVow(vow) {
9898
if (e.name && e.name.match(/AssertionError/)) {
9999
output('broken', e.toString());
100100
} else {
101-
output('errored', e.stack || e.message || e.toString() || e);
101+
output('errored', e.stack || e.message || e);
102102
}
103103
}
104104
}

0 commit comments

Comments
 (0)