You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The model homepage-item is expecting records that implement the itemizeable type, however no records do.
The included polymorphic test only checks whether these records can be loaded, it doesn't check the hasMany relationships state.
While working on relationships in ember-data I recently noticed that our polymorphic assertion does not currently run for canonical/remote state updates (but does run for all forms of local state updates). Adding this missing assertion causes this test to fail.
I'm opening this issue because while I think the test should correctly implement the current polymorphic setup requirements (e.g. post and comment should implement itemizeable via shared base class or mixin) the current work I am doing is intended to firm up some things that would allow us to utilize polymorphic relationships without mixins or inheritance. E.g. in a future state, because this relationship has no inverse defined on post or comment (or even on the itemizeable mixin) then this setup could possibly be considered correct.
Thanks, agree and surprised itemizable isn't being used anywhere.
What's the best way for me to see this assertion fail with storefront's test suite? When I run ember try:one ember-canary --- ember test all tests pass.
@ryanto we have auto-publishing canary versions now but I think it runs once mid-week, I'll publish one for you now because else you have to run the script from ember-data's side that creates the tarballs and inserts them into this package.
The model
homepage-item
is expecting records that implement theitemizeable
type, however no records do.The included polymorphic test only checks whether these records can be loaded, it doesn't check the hasMany relationships state.
While working on relationships in
ember-data
I recently noticed that our polymorphic assertion does not currently run for canonical/remote state updates (but does run for all forms of local state updates). Adding this missing assertion causes this test to fail.I'm opening this issue because while I think the test should correctly implement the current polymorphic setup requirements (e.g.
post
andcomment
should implementitemizeable
via shared base class or mixin) the current work I am doing is intended to firm up some things that would allow us to utilize polymorphic relationships without mixins or inheritance. E.g. in a future state, because this relationship has no inverse defined onpost
orcomment
(or even on theitemizeable
mixin) then this setup could possibly be considered correct.See emberjs/data#7491 for the PR which uncovered this.
The text was updated successfully, but these errors were encountered: