Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
test: update error message for pending exceptions
Updated the error message for pending exceptions so that it was a bit
more clear.
  • Loading branch information
blairwilcox committed Jan 31, 2018
commit 1d2cc64cbdca42f471b37d5628a2faae5676e825
8 changes: 4 additions & 4 deletions test/addons-napi/test_exception/test.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ const theError = new Error('Some error');
// before it was handled on the JS side
const exception_pending = test_exception.wasPending();
assert.strictEqual(exception_pending, true,
'Expected exception to be pending, but' +
`it was marked as ${exception_pending}`);
'Exception not pending as expected,' +
` .wasPending() returned ${exception_pending}`);

// Test that the native side does not capture a non-existing exception
returnedError = test_exception.returnException(common.mustCall());
Expand All @@ -47,6 +47,6 @@ const theError = new Error('Some error');
// Test that the exception state remains clear when no exception is thrown
const exception_pending = test_exception.wasPending();
assert.strictEqual(exception_pending, false,
'Expected no exception to be pending, but' +
` it was marked as ${exception_pending}`);
'Exception state did not remain clear as expected,' +
` .wasPending() returned ${exception_pending}`);
}