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

Unified Diff: test/mjsunit/harmony/typedarray-proto.js

Issue 1215863003: Include Harmony Array/TypedArray methods unconditionally (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: remove the flag and move the tests Created 5 years, 6 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/typedarray-iteration.js ('k') | test/mjsunit/harmony/typedarray-reduce.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/harmony/typedarray-proto.js
diff --git a/test/mjsunit/harmony/typedarray-proto.js b/test/mjsunit/harmony/typedarray-proto.js
deleted file mode 100644
index c164a317e52b32029fae157379ac869cdabf0016..0000000000000000000000000000000000000000
--- a/test/mjsunit/harmony/typedarray-proto.js
+++ /dev/null
@@ -1,44 +0,0 @@
-// Copyright 2015 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-arrays
-
-// Test that the methods for different TypedArray types have the same
-// identity.
-// TODO(dehrenberg): Test that the TypedArray proto hierarchy is set
-// up properly.
-// TODO(dehrenberg): subarray is currently left out because that still
-// uses per-type methods. When that's fixed, stop leaving it out.
-
-var typedArrayConstructors = [
- Uint8Array,
- Int8Array,
- Uint16Array,
- Int16Array,
- Uint32Array,
- Int32Array,
- Uint8ClampedArray,
- Float32Array,
- Float64Array];
-
-function functionProperties(object) {
- return Object.getOwnPropertyNames(object).filter(function(name) {
- return typeof Object.getOwnPropertyDescriptor(object, name).value
- == "function"
- && name != 'constructor' && name != 'subarray';
- });
-}
-
-var typedArrayMethods = functionProperties(Uint8Array.prototype);
-var typedArrayClassMethods = functionProperties(Uint8Array);
-
-for (var constructor of typedArrayConstructors) {
- for (var method of typedArrayMethods) {
- assertEquals(constructor.prototype[method],
- Uint8Array.prototype[method], method);
- }
- for (var classMethod of typedArrayClassMethods) {
- assertEquals(constructor[method], Uint8Array[method], classMethod);
- }
-}
« no previous file with comments | « test/mjsunit/harmony/typedarray-iteration.js ('k') | test/mjsunit/harmony/typedarray-reduce.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698