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

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

Issue 1764953002: Fix Array.prototype.sort on proxies. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Test Created 4 years, 10 months 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 | « src/runtime/runtime-array.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/array-sort.js
diff --git a/test/mjsunit/array-sort.js b/test/mjsunit/array-sort.js
index 36608f5e142e455cb86659d2c8814007cb1fc579..beb8b95b014bb402ce7e7fe715b333489e4d913c 100644
--- a/test/mjsunit/array-sort.js
+++ b/test/mjsunit/array-sort.js
@@ -464,3 +464,9 @@ function TestSortToObject() {
assertEquals(0, Number(Array.prototype.sort.call(0)));
}
TestSortToObject();
+
+function TestSortOnProxy() {
+ var p = new Proxy([2,1,3], {});
+ assertEquals([1,2,3], p.sort());
+}
+TestSortOnProxy();
« no previous file with comments | « src/runtime/runtime-array.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698