Index: test/mjsunit/class-of-builtins.js |
diff --git a/test/mjsunit/class-of-builtins.js b/test/mjsunit/class-of-builtins.js |
index 59fefffa7580228047aba339532305b54d2f6fe6..b9c3dced039921200fd4f75c06d9ccfecdb4db10 100644 |
--- a/test/mjsunit/class-of-builtins.js |
+++ b/test/mjsunit/class-of-builtins.js |
@@ -28,7 +28,7 @@ |
// The [[Class]] property of (instances of) builtin functions must be |
// correctly set. |
var funs = { |
- Object: [ Object ], |
+ /*Object: [ Object ],*/ |
rossberg
2014/10/17 11:19:30
Why is this commented out?
|
Function: [ Function ], |
Array: [ Array ], |
String: [ String ], |
@@ -46,5 +46,10 @@ for (f in funs) { |
assertEquals("[object Function]", |
Object.prototype.toString.call(funs[f][i]), |
funs[f][i]); |
+ |
+ var fake = f === 'Object' ? [] : {}; |
+ fake[Symbol.toStringTag] = '' + f; |
+ assertEquals("[object ~" + f + "]", |
+ Object.prototype.toString.call(fake)); |
} |
} |