Index: test/mjsunit/harmony/object-observe.js |
diff --git a/test/mjsunit/harmony/object-observe.js b/test/mjsunit/harmony/object-observe.js |
index 83199f3e239b890a8415c14da546e9e3a719fe09..e2cc3f9d45bcdc29da5526e2afdfaf6e68e6b31a 100644 |
--- a/test/mjsunit/harmony/object-observe.js |
+++ b/test/mjsunit/harmony/object-observe.js |
@@ -129,8 +129,24 @@ assertFalse(recordCreated); // not observed yet |
// Object.deliverChangeRecords |
assertThrows(function() { Object.deliverChangeRecords(nonFunction); }, TypeError); |
-// Multiple records are delivered. |
Object.observe(obj, observer.callback); |
+ |
+// notify uses to [[CreateOwnProperty]] to create changeRecord; |
+reset(); |
+var protoExpandoAccessed = false; |
+Object.defineProperty(Object.prototype, 'protoExpando', |
+ { |
+ configurable: true, |
+ set: function() { protoExpandoAccessed = true; } |
+ } |
+); |
+notifier.notify({ type: 'foo', protoExpando: 'val'}); |
+assertFalse(protoExpandoAccessed); |
+delete Object.prototype.protoExpando; |
+Object.deliverChangeRecords(observer.callback); |
+ |
+// Multiple records are delivered. |
+reset(); |
notifier.notify({ |
type: 'updated', |
name: 'foo', |