diff --git a/packages/ember-runtime/lib/system/core_object.js b/packages/ember-runtime/lib/system/core_object.js index 489b1c0fcf9..4efce64b996 100644 --- a/packages/ember-runtime/lib/system/core_object.js +++ b/packages/ember-runtime/lib/system/core_object.js @@ -98,6 +98,8 @@ function makeCtor() { property === 'willWatchProperty' || property === 'didUnwatchProperty' || property === 'didAddListener' || + property === '__DESCRIPTOR__' || + property === 'isDescriptor' || property in target ) { return Reflect.get(target, property, receiver); diff --git a/packages/ember-runtime/tests/system/core_object_test.js b/packages/ember-runtime/tests/system/core_object_test.js index e0337ee111c..0e84ba6c1be 100644 --- a/packages/ember-runtime/tests/system/core_object_test.js +++ b/packages/ember-runtime/tests/system/core_object_test.js @@ -1,3 +1,4 @@ +import { get } from 'ember-metal'; import CoreObject from '../../system/core_object'; QUnit.module('Ember.CoreObject'); @@ -36,3 +37,18 @@ QUnit.test('toString should be not be added as a property when calling toString( assert.notOk(obj.hasOwnProperty('toString'), 'Calling toString() should not create a toString class property'); }); + +QUnit.test('should not trigger proxy assertion when retrieving a proxy with (GH#16263)', function(assert) { + let someProxyishThing = CoreObject.extend({ + unknownProperty() { + return true; + } + }).create(); + + let obj = new CoreObject({ + someProxyishThing + }); + + let proxy = get(obj, 'someProxyishThing'); + assert.equal(get(proxy, 'lolol'), true, 'should be able to get data from a proxy'); +});