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

Unified Diff: test/mjsunit/es6/typedarray.js

Issue 1501673002: Revert of [es6] Correctify and unify ArrayBuffer and SharedArrayBuffer constructors. (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/es6/classes-subclass-builtins.js ('k') | test/mjsunit/get-prototype-of.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/es6/typedarray.js
diff --git a/test/mjsunit/es6/typedarray.js b/test/mjsunit/es6/typedarray.js
index babb942c5b65e86d55fd3717eac9838c80ab9f21..a45b6308f319d2b04593f5d5269e6166c59f6864 100644
--- a/test/mjsunit/es6/typedarray.js
+++ b/test/mjsunit/es6/typedarray.js
@@ -39,7 +39,7 @@
TestByteLength(256, 256);
TestByteLength(2.567, 2);
- TestByteLength("0", 0);
+ TestByteLength("abc", 0);
TestByteLength(0, 0);
@@ -52,7 +52,7 @@
}, RangeError);
*/
- var ab = new ArrayBuffer(0);
+ var ab = new ArrayBuffer();
assertSame(0, ab.byteLength);
assertEquals("[object ArrayBuffer]",
Object.prototype.toString.call(ab));
@@ -729,11 +729,11 @@
if (obj)
assertArrayEquals([], props(obj));
}
-TestEnumerable(ArrayBuffer, new ArrayBuffer(0));
+TestEnumerable(ArrayBuffer, new ArrayBuffer());
for(i = 0; i < typedArrayConstructors.length; i++) {
TestEnumerable(typedArrayConstructors[i]);
}
-TestEnumerable(DataView, new DataView(new ArrayBuffer(0)));
+TestEnumerable(DataView, new DataView(new ArrayBuffer()));
// Test arbitrary properties on ArrayBuffer
function TestArbitrary(m) {
@@ -754,8 +754,8 @@
// Test direct constructor call
-assertThrows(function() { ArrayBuffer(0); }, TypeError);
-assertThrows(function() { DataView(new ArrayBuffer(0)); }, TypeError);
+assertThrows(function() { ArrayBuffer(); }, TypeError);
+assertThrows(function() { DataView(new ArrayBuffer()); }, TypeError);
function TestNonConfigurableProperties(constructor) {
var arr = new constructor([100])
« no previous file with comments | « test/mjsunit/es6/classes-subclass-builtins.js ('k') | test/mjsunit/get-prototype-of.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698