Well, the tests that are failing are because those items are directly manipulating the data underneath the the collection (this would be akin to manipulating the source array in an array collection, by putting watches on them, and changing the order without using the overlying collection. While that is technically legal, it's very bad practice. Putting a flag for the old method is fine, but if people modify the source data using the collection instead of the source directly then it is broken. The reason why we have failed tests is because even the SDK writers were working around this bug (in mx:Menu and mx:Tree). It looks like it's been working this way since 3.x at the least.
I'm still trying to get my own local copy of Mustella compiling right. Sometime last month it stopped running fully on git bash (it's not compiling tests). No idea on that one, but I'm trying to install it on my Mac right now since I know that is what most of you use (so it should work). -Nick On Fri, Jun 6, 2014 at 4:11 PM, Alex Harui <aha...@adobe.com> wrote: > I still think you should add a flag that preserves old behavior. Mustella > is telling you that there is a potential that folks are relying on old > behavior. It is fine to default to new behavior and have the mustella > tests set the flag for old behavior (and make copies of those tests with > results expecting new behavior). > > Or provide a clear argument that nobody in their right mind could ever > want the old behavior. > > -Alex > > On 6/6/14 11:55 AM, "Nicholas Kwiatkowski" <nicho...@spoon.as> wrote: > > >I've reverted this back to the original version. I'll continue work in a > >separate branch, but I need some help in testing that branch before I > >merge > >again. This fixes a pretty nasty bug that we should really take care of. > > > >-Nick > > > > > >On Thu, Jun 5, 2014 at 4:01 AM, Erik de Bruin <e...@ixsoftware.nl> wrote: > > > >> -1 (binding) > >> > >> I'm vetoing this commit because it is causing the following (sets of) > >> Mustella tests to fail: > >> > >> - components/MenuBar/Halo/Styles/MenuBar_MenuStyles > >> - components/Menu/Halo/Properties/Menu_Properties > >> - components/Menu/Halo/Styles/Menu_Styles > >> - components/Menu/Spark/Properties/Menu_Properties_spark > >> - components/Tree/Properties/Tree_Properties > >> - components/Tree/Properties/Tree_Properties_spark > >> - components/Tree/Properties/Tree_PropertiesDragDrop > >> - components/Tree/Properties/Tree_PropertiesDragDrop_spark > >> - gumbo/components/DataGrid/Properties/DataGrid_dataProvider_test001 > >> - gumbo/components/MXItemRenderer/integration/MXTIR_Integration_main > >> > >> (aharui: "I looked at MXItemRenderer and it appears that the test is > >> expecting an updateComplete when an XML node is added to the collection. > >> Does this no longer happen because the parent is not notified?") > >> > >> It has been three weeks without a working solution (or 'fix' of the > >>tests) > >> and we need the successful Mustella runs because we're looking to get > >>out a > >> new release, so: please revert - or fix - this commit and all related > >>ones. > >> > >> Thanks, > >> > >> EdB > >> > >> > >> > >> On Tue, May 20, 2014 at 1:19 AM, <que...@apache.org> wrote: > >> > >> > Repository: flex-sdk > >> > Updated Branches: > >> > refs/heads/FLEX-34283 [created] e780eaa81 > >> > > >> > > >> > Now XMLListCollection behaves closer to be expected -- does not update > >> > parent from updated XMLList. I guess it should be debated wether it > >> > should... > >> > > >> > > >> > Project: http://git-wip-us.apache.org/repos/asf/flex-sdk/repo > >> > Commit: > >>http://git-wip-us.apache.org/repos/asf/flex-sdk/commit/e780eaa8 > >> > Tree: http://git-wip-us.apache.org/repos/asf/flex-sdk/tree/e780eaa8 > >> > Diff: http://git-wip-us.apache.org/repos/asf/flex-sdk/diff/e780eaa8 > >> > > >> > Branch: refs/heads/FLEX-34283 > >> > Commit: e780eaa814b5ac76e9dbfc88208f88022b57c5f4 > >> > Parents: 79073bf > >> > Author: Nick Kwiatkowski <n...@msu.edu> > >> > Authored: Mon May 19 19:18:15 2014 -0400 > >> > Committer: Nick Kwiatkowski <n...@msu.edu> > >> > Committed: Mon May 19 19:18:15 2014 -0400 > >> > > >> > ---------------------------------------------------------------------- > >> > .../src/mx/collections/XMLListAdapter.as | 32 > >> ++++++++++++++------ > >> > 1 file changed, 23 insertions(+), 9 deletions(-) > >> > ---------------------------------------------------------------------- > >> > > >> > > >> > > >> > > >> > >> > http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/e780eaa8/frameworks/ > >>projects/framework/src/mx/collections/XMLListAdapter.as > >> > ---------------------------------------------------------------------- > >> > diff --git > >> > a/frameworks/projects/framework/src/mx/collections/XMLListAdapter.as > >> > b/frameworks/projects/framework/src/mx/collections/XMLListAdapter.as > >> > index 17d2173..7c29798 100644 > >> > --- > >>a/frameworks/projects/framework/src/mx/collections/XMLListAdapter.as > >> > +++ > >>b/frameworks/projects/framework/src/mx/collections/XMLListAdapter.as > >> > @@ -248,16 +248,30 @@ public class XMLListAdapter extends > >>EventDispatcher > >> > implements IList, IXMLNotifi > >> > > >> > if (length > 0) > >> > { > >> > - var localLength:uint = source.length(); > >> > - > >> > - // Adjust all indexes by 1 > >> > - for (var i:uint = localLength; i>index; i--) > >> > - { > >> > - source[i] = source[i - 1]; > >> > - } > >> > + var newSource:XMLList = new XMLList(); > >> > + > >> > + for (var i:uint = 0; i <= (length); i++) > >> > + { > >> > + if (i < index) > >> > + { > >> > + newSource[i] = source[i]; > >> > + } > >> > + else if (i == index) > >> > + { > >> > + newSource[i] = item; > >> > + } > >> > + else if (i > index) > >> > + { > >> > + newSource[i] = source[i-1]; > >> > + } > >> > + } > >> > + > >> > + source = newSource; > >> > } > >> > - > >> > - source[index] = item; > >> > + else > >> > + { > >> > + source[index] = item; > >> > + } > >> > > >> > startTrackUpdates(item, seedUID + uidCounter.toString()); > >> > uidCounter++; > >> > > >> > > >> > >> > >> -- > >> Ix Multimedia Software > >> > >> Jan Luykenstraat 27 > >> 3521 VB Utrecht > >> > >> T. 06-51952295 > >> I. www.ixsoftware.nl > >> > >