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

Unified Diff: test/mjsunit/harmony/typed-array-iterator.js

Issue 446023002: Enable ES6 iteration by default (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Moved tests to es6, fixed duplicate ExtendArrayPrototype name in unscopables.js Created 6 years, 4 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 | « test/mjsunit/harmony/string-iterator.js ('k') | test/mjsunit/mjsunit.status » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/harmony/typed-array-iterator.js
diff --git a/test/mjsunit/harmony/typed-array-iterator.js b/test/mjsunit/harmony/typed-array-iterator.js
deleted file mode 100644
index 8559dfe9af0deff2cd84354981c03063af927196..0000000000000000000000000000000000000000
--- a/test/mjsunit/harmony/typed-array-iterator.js
+++ /dev/null
@@ -1,41 +0,0 @@
-// Copyright 2014 the V8 project authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-// Flags: --harmony-iteration
-
-
-var constructors = [Uint8Array, Int8Array,
- Uint16Array, Int16Array,
- Uint32Array, Int32Array,
- Float32Array, Float64Array,
- Uint8ClampedArray];
-
-function TestTypedArrayPrototype(constructor) {
- assertTrue(constructor.prototype.hasOwnProperty('entries'));
- assertTrue(constructor.prototype.hasOwnProperty('values'));
- assertTrue(constructor.prototype.hasOwnProperty('keys'));
- assertTrue(constructor.prototype.hasOwnProperty(Symbol.iterator));
-
- assertFalse(constructor.prototype.propertyIsEnumerable('entries'));
- assertFalse(constructor.prototype.propertyIsEnumerable('values'));
- assertFalse(constructor.prototype.propertyIsEnumerable('keys'));
- assertFalse(constructor.prototype.propertyIsEnumerable(Symbol.iterator));
-
- assertEquals(Array.prototype.entries, constructor.prototype.entries);
- assertEquals(Array.prototype.values, constructor.prototype.values);
- assertEquals(Array.prototype.keys, constructor.prototype.keys);
- assertEquals(Array.prototype.values, constructor.prototype[Symbol.iterator]);
-}
-constructors.forEach(TestTypedArrayPrototype);
-
-
-function TestTypedArrayValues(constructor) {
- var array = [1, 2, 3];
- var i = 0;
- for (var value of new constructor(array)) {
- assertEquals(array[i++], value);
- }
- assertEquals(i, array.length);
-}
-constructors.forEach(TestTypedArrayValues);
« no previous file with comments | « test/mjsunit/harmony/string-iterator.js ('k') | test/mjsunit/mjsunit.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698