Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUGFIX] observed properties not being marked as enum #16735

Merged
merged 1 commit into from
Jan 4, 2019

Conversation

bekzod
Copy link
Contributor

@bekzod bekzod commented Jun 10, 2018

fixes #14594

@bekzod bekzod force-pushed the fix-object-key branch 2 times, most recently from b5e6530 to 2cbd94d Compare June 10, 2018 13:04
Copy link
Member

@rwjblue rwjblue left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fix looks good to me, only a few tweaks needed to the test then we can land...

@@ -93,6 +93,28 @@ moduleFor(
getOwner(proxy);
}

['@test `Object.keys` works properly'](assert) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you tweak this test title? I'd like to see it reference the original issue, and specifically what it is intended to test.

Something like this seems reasonable:

@test observed properties are enumerable when set GH#14594

Also, can you move this to two tests one in packages/ember-metal/tests/accessors/set_test.js and another in packages/ember-metal/tests/set_properties_test.js?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sure

@bekzod bekzod force-pushed the fix-object-key branch 2 times, most recently from 8fbf9c9 to 04c48cb Compare June 11, 2018 15:09
@@ -1,4 +1,5 @@
import { setProperties } from '..';
import { CoreObject } from 'ember-runtime';
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In general we shouldn't be importing from ember-runtime from within ember-metal.

The tests in ember-metal will need to be updated to use POJO's instead of CoreObject...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Issue does not happen with POJO objects it only happens with CoreObject, so moving back to CoreObject test

@rwjblue rwjblue merged commit a97afa8 into emberjs:master Jan 4, 2019
@rwjblue
Copy link
Member

rwjblue commented Jan 4, 2019

Sorry it took so long here, but this looks good to me. Thanks again @bekzod!

@bekzod bekzod deleted the fix-object-key branch January 8, 2019 07:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Ember.set & Ember.setProperties fail to set properties "enumerable"
2 participants