-
Notifications
You must be signed in to change notification settings - Fork 25
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
Add failing spec for sorted block with missing sorted property #13
base: master
Are you sure you want to change the base?
Conversation
Added another failing spec :( |
Joy. Nothing can be simple :P |
I’m now convinced that this should be solved by omitting values from the output if the relation produces null. This probably involves tracking whether each value is currently included in the output. SortedArray in Collections should be modified to complain loudly if someone adds an incomparable value, as SortedSet already does. |
I'm not sure what you mean by this. Would it mean that line 43 of the diff would read expect(object.sorted.length).toEqual(0); but the remainder of that test would remain the same? |
@Stuk Yes, I believe that might work. |
montagejs/collections#171 landed in collections master need release. |
The number of items in the array increase(!) when the property that is sorted on does not exist in the objects, and is then added.