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

Unified Diff: test/mjsunit/harmony/typedarrays-of.js

Issue 1186733002: Add %TypedArray% to proto chain (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: changes from arv's review 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/typedarrays.js ('k') | test/mjsunit/regress/regress-typedarray-length.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/harmony/typedarrays-of.js
diff --git a/test/mjsunit/harmony/typedarrays-of.js b/test/mjsunit/harmony/typedarrays-of.js
index 9df1d30c8eed87f3fc427a505d98e70078d5d76d..66f5e2a07e6432b40184af92fd47ea3e1a51f41a 100644
--- a/test/mjsunit/harmony/typedarrays-of.js
+++ b/test/mjsunit/harmony/typedarrays-of.js
@@ -15,8 +15,16 @@ var typedArrayConstructors = [
Int32Array,
Uint8ClampedArray,
Float32Array,
- Float64Array];
+ Float64Array
+];
+function getPropertyDescriptor(object, field, expectedDepth) {
+ for (var depth = 0; depth < expectedDepth; depth++) {
+ assertFalse(Object.hasOwnProperty(object, field));
+ object = object.__proto__;
+ }
+ return Object.getOwnPropertyDescriptor(object, field);
+}
function TestTypedArrayOf(constructor) {
// %TypedArray%.of basics.
@@ -111,7 +119,7 @@ function TestTypedArrayOf(constructor) {
assertEquals("pass", status);
// Check superficial features of %TypedArray%.of.
- var desc = Object.getOwnPropertyDescriptor(constructor, "of");
+ var desc = getPropertyDescriptor(constructor, "of", 1);
assertEquals(desc.configurable, false);
assertEquals(desc.enumerable, false);
« no previous file with comments | « test/mjsunit/harmony/typedarrays.js ('k') | test/mjsunit/regress/regress-typedarray-length.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698