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

Unified Diff: test/mjsunit/messages.js

Issue 1533803002: Revert of [es6] Correct Function.prototype.apply, Reflect.construct and Reflect.apply. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years 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 | « test/mjsunit/apply.js ('k') | test/webkit/fast/js/function-apply.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/messages.js
diff --git a/test/mjsunit/messages.js b/test/mjsunit/messages.js
index b42cc3019342760d9bde3a18eb8a204ad0cb252a..5739c965cd0b456864daa109e8916efb449c85e3 100644
--- a/test/mjsunit/messages.js
+++ b/test/mjsunit/messages.js
@@ -57,18 +57,6 @@
Object.defineProperty(1, "x", {});
}, "Object.defineProperty called on non-object", TypeError);
-test(function() {
- (function() {}).apply({}, 1);
-}, "CreateListFromArrayLike called on non-object", TypeError);
-
-test(function() {
- Reflect.apply(function() {}, {}, 1);
-}, "CreateListFromArrayLike called on non-object", TypeError);
-
-test(function() {
- Reflect.construct(function() {}, 1);
-}, "CreateListFromArrayLike called on non-object", TypeError);
-
// kCalledOnNullOrUndefined
test(function() {
Array.prototype.shift.call(null);
@@ -342,6 +330,19 @@
}, "Invalid property descriptor. Cannot both specify accessors " +
"and a value or writable attribute, #<Object>", TypeError);
+// kWrongArgs
+test(function() {
+ (function() {}).apply({}, 1);
+}, "Function.prototype.apply: Arguments list has wrong type", TypeError);
+
+test(function() {
+ Reflect.apply(function() {}, {}, 1);
+}, "Reflect.apply: Arguments list has wrong type", TypeError);
+
+test(function() {
+ Reflect.construct(function() {}, 1);
+}, "Reflect.construct: Arguments list has wrong type", TypeError);
+
// === SyntaxError ===
« no previous file with comments | « test/mjsunit/apply.js ('k') | test/webkit/fast/js/function-apply.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698