Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(77)

Unified Diff: test/mjsunit/mjsunit.js

Issue 2525313003: [mjsunit] Change assertThrows such that it can check the exception message. (Closed)
Patch Set: Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | test/mjsunit/regress/regress-2263.js » ('j') | test/mjsunit/wasm/divrem-trap.js » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/mjsunit.js
diff --git a/test/mjsunit/mjsunit.js b/test/mjsunit/mjsunit.js
index d4759a281f734c45072aad61d101da416bb03796..88d4d3677c4edc84fc2e9128737083cb246a64bb 100644
--- a/test/mjsunit/mjsunit.js
+++ b/test/mjsunit/mjsunit.js
@@ -376,7 +376,7 @@ var assertMatches;
failWithMessage("invalid use of assertThrows, maybe you want assertThrowsEquals");
}
if (arguments.length >= 3) {
- assertEquals(e.type, cause_opt);
+ assertEquals(e.message, cause_opt);
titzer 2016/11/24 15:37:01 What about checking both the type and the cause he
ahaas 2016/11/28 09:47:53 The JS standard defines only message, not type. I
}
// Success.
return;
« no previous file with comments | « no previous file | test/mjsunit/regress/regress-2263.js » ('j') | test/mjsunit/wasm/divrem-trap.js » ('J')

Powered by Google App Engine
This is Rietveld 408576698