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

Unified Diff: test/mjsunit/array-reduce.js

Issue 11358214: Remove 'type' and 'arguments' properties from Error object. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 8 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
Index: test/mjsunit/array-reduce.js
diff --git a/test/mjsunit/array-reduce.js b/test/mjsunit/array-reduce.js
index 1e96188265c9a4215eaf499475ca94c3bb4d43d3..429f34808d74152e25705b296dc584c2f41837e0 100755
--- a/test/mjsunit/array-reduce.js
+++ b/test/mjsunit/array-reduce.js
@@ -418,8 +418,8 @@ try {
exception = true;
assertTrue(e instanceof TypeError,
"reduce callback not a function not throwing TypeError");
- assertEquals("called_non_callable", e.type,
- "reduce non function TypeError type");
+ assertTrue(e.message.indexOf(" is not a function") >= 0,
+ "reduce non function TypeError type");
}
assertTrue(exception);
@@ -430,8 +430,8 @@ try {
exception = true;
assertTrue(e instanceof TypeError,
"reduceRight callback not a function not throwing TypeError");
- assertEquals("called_non_callable", e.type,
- "reduceRight non function TypeError type");
+ assertTrue(e.message.indexOf(" is not a function") >= 0,
+ "reduceRight non function TypeError type");
}
assertTrue(exception);
@@ -442,7 +442,7 @@ try {
exception = true;
assertTrue(e instanceof TypeError,
"reduce no initial value not throwing TypeError");
- assertEquals("reduce_no_initial", e.type,
+ assertEquals("Reduce of empty array with no initial value", e.message,
"reduce no initial TypeError type");
}
assertTrue(exception);
@@ -454,7 +454,7 @@ try {
exception = true;
assertTrue(e instanceof TypeError,
"reduceRight no initial value not throwing TypeError");
- assertEquals("reduce_no_initial", e.type,
+ assertEquals("Reduce of empty array with no initial value", e.message,
"reduceRight no initial TypeError type");
}
assertTrue(exception);
@@ -466,7 +466,7 @@ try {
exception = true;
assertTrue(e instanceof TypeError,
"reduce sparse no initial value not throwing TypeError");
- assertEquals("reduce_no_initial", e.type,
+ assertEquals("Reduce of empty array with no initial value", e.message,
"reduce no initial TypeError type");
}
assertTrue(exception);
@@ -478,7 +478,7 @@ try {
exception = true;
assertTrue(e instanceof TypeError,
"reduceRight sparse no initial value not throwing TypeError");
- assertEquals("reduce_no_initial", e.type,
+ assertEquals("Reduce of empty array with no initial value", e.message,
"reduceRight no initial TypeError type");
}
assertTrue(exception);

Powered by Google App Engine
This is Rietveld 408576698