incubator-flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From p...@apache.org
Subject svn commit: r1369970 [6/16] - in /incubator/flex/trunk/mustella/tests/Managers: ./ CursorManager/ CursorManager/Methods/ CursorManager/Props/ CursorManager/SWFs/ CursorManager/SWFs/Assets/ DragManager/ DragManager/Events/ DragManager/Halo/ DragManager/...
Date Mon, 06 Aug 2012 20:17:23 GMT
Added: incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/DragManager_TreeTests_spark.mxml
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/DragManager_TreeTests_spark.mxml?rev=1369970&view=auto
==============================================================================
--- incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/DragManager_TreeTests_spark.mxml (added)
+++ incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/DragManager_TreeTests_spark.mxml Mon Aug  6 20:17:09 2012
@@ -0,0 +1,215 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+
+-->
+<UnitTester testDir="Managers/DragManager/Spark/"  xmlns:mx="http://www.adobe.com/2006/mxml" xmlns="*" testSWF="DragManager_Tree_spark.mxml">
+
+    <mx:Script>
+    <![CDATA[
+
+    import mx.collections.XMLListCollection;
+    import data.TreeData;
+    import data.TreeData2;
+
+       public static function init(o:DisplayObject):void
+        {
+
+        }
+
+
+    public var XLCAS:XMLListCollection;
+    public var genericObject:TreeData2;
+
+    public function getDataXML():void {
+        var newData:TreeData = new TreeData();
+        XLCAS = new XMLListCollection(newData.myData);
+        application.firstTree.dataProvider = XLCAS;
+        application.firstTree.labelField = "@label";
+        application.firstTree.showRoot = false;
+    }
+
+    public function getDataAS():void {
+        var newData:TreeData2 = new TreeData2();
+        application.firstTree.dataProvider = newData.myData;
+        application.firstTree.labelField = "fileName";
+        application.firstTree.showRoot = false;
+    }
+
+    ]]>
+    </mx:Script>
+
+    <mx:Metadata>
+    <![CDATA[
+        [Mixin]
+    ]]>
+    </mx:Metadata>
+
+
+    <testCases>
+    <!-- Drag Tree to Tree-->
+        <TestCase testID="DragManager_TreeToTree_singleMove" description="Test that you can move Tree items from one to the other." keywords="[DragManager, Tree]">
+            <setup>
+               <ResetComponent target="firstTree" className="mx.controls.Tree" waitTarget="firstTree" waitEvent="updateComplete" />
+               <SetProperty propertyName="dragEnabled" value="true" target="firstTree" />
+               <SetProperty propertyName="width" value="250" target="firstTree" />
+               <RunCode code="getDataXML()" waitTarget="firstTree" waitEvent="updateComplete" />
+               <SetProperty propertyName="dragMoveEnabled" value="true" target="firstTree" />
+               <ResetComponent target="secondTree" className="mx.controls.Tree" waitTarget="secondTree" waitEvent="updateComplete" />
+               <SetProperty propertyName="dropEnabled" value="true" target="secondTree" />
+               <SetProperty propertyName="width" value="250" target="secondTree" />
+               <SetProperty propertyName="labelField" value="@label" target="secondTree" />
+             </setup>
+             <body>
+                <DispatchMouseClickEvent target="firstTree.mx_internal:rendererArray.0.0" localX="5" localY="5" waitEvent="itemOpen" waitTarget="firstTree" />
+                <DispatchMouseEvent target="firstTree.mx_internal:rendererArray.1.0.getChildAt(0)" type="mouseOver" localX="10" localY="8" buttonDown="true" />
+                <DispatchMouseEvent target="firstTree.mx_internal:rendererArray.1.0.getChildAt(0)" type="mouseDown" localX="10" localY="8" buttonDown="true" />
+                <DispatchMouseEvent target="stage" type="mouseMove" localX="100" localY="35" buttonDown="true"
+                    waitTarget="mx.managers::DragManager.mx_internal:dragProxy" />
+                <DispatchMouseEvent target="stage" type="mouseMove" localX="140" localY="35" buttonDown="true"  waitTarget="mx.managers::DragManager.mx_internal:dragProxy" />
+                <DispatchMouseEvent target="stage" type="mouseMove" localX="200" localY="35" buttonDown="true"  waitTarget="mx.managers::DragManager.mx_internal:dragProxy" />
+                <DispatchMouseEvent target="stage" type="mouseMove" localX="250" localY="35" buttonDown="true"  waitTarget="mx.managers::DragManager.mx_internal:dragProxy" />
+                <DispatchMouseEvent target="stage" type="mouseMove" localX="320" localY="40" buttonDown="true"  waitTarget="mx.managers::DragManager.mx_internal:dragProxy" />
+                <DispatchMouseEvent target="stage" type="mouseUp" localX="350" localY="40" waitTarget="secondTree" waitEvent="dragDrop" />
+                <AssertPropertyValue propertyName="label" target="secondTree.mx_internal:rendererArray.0.0.listData" value="Inbox" />
+                <AssertPropertyValue propertyName="label" target="firstTree.mx_internal:rendererArray.1.0.listData" value="Drafts" />
+             </body>
+        </TestCase>
+        <TestCase testID="DragManager_TreeToTree_multipleMove" description="Test that you can move multiple items of a Tree by drag and drop." keywords="[DragManager, Tree, multi-selection]">
+            <setup>
+               <ResetComponent target="firstTree" className="mx.controls.Tree" waitTarget="firstTree" waitEvent="updateComplete" />
+               <SetProperty propertyName="dragEnabled" value="true" target="firstTree" />
+               <SetProperty propertyName="width" value="250" target="firstTree" />
+               <SetProperty propertyName="allowMultipleSelection" value="tree" target="firstTree" />
+               <RunCode code="getDataXML()" waitTarget="firstTree" waitEvent="updateComplete" />
+               <SetProperty propertyName="dragMoveEnabled" value="true" target="firstTree" />
+               <ResetComponent target="secondTree" className="mx.controls.Tree" waitTarget="secondTree" waitEvent="updateComplete" />
+               <SetProperty propertyName="dropEnabled" value="true" target="secondTree" />
+               <SetProperty propertyName="width" value="250" target="secondTree" />
+               <SetProperty propertyName="labelField" value="@label" target="secondTree" />
+             </setup>
+             <body>
+                <DispatchMouseClickEvent target="firstTree.mx_internal:rendererArray.1.0" localX="5" localY="5" waitEvent="itemOpen" waitTarget="firstTree" />
+                <DispatchMouseClickEvent target="firstTree.mx_internal:rendererArray.2.0.getChildAt(0)" localX="4" localY="5" waitEvent="itemClick" waitTarget="firstTree" ctrlKey="true" />
+                <DispatchMouseClickEvent target="firstTree.mx_internal:rendererArray.3.0.getChildAt(0)" localX="4" localY="5" waitEvent="itemClick" waitTarget="firstTree" ctrlKey="true" />
+                <DispatchMouseEvent target="firstTree.mx_internal:rendererArray.2.0.getChildAt(0)" type="mouseOver" localX="5" localY="5"  />
+                <DispatchMouseEvent target="firstTree.mx_internal:rendererArray.2.0.getChildAt(0)" type="mouseDown" localX="5" localY="5" buttonDown="true" />
+                <DispatchMouseEvent target="stage" type="mouseMove" localX="100" localY="75" buttonDown="true"
+                    waitTarget="mx.managers::DragManager.mx_internal:dragProxy" />
+                <DispatchMouseEvent target="stage" type="mouseMove" localX="200" localY="75" buttonDown="true"  waitTarget="mx.managers::DragManager.mx_internal:dragProxy" waitEvent="move"/>
+                <DispatchMouseEvent target="stage" type="mouseMove" localX="260" localY="75" buttonDown="true"   />
+                <DispatchMouseEvent target="stage" type="mouseMove" localX="350" localY="75" buttonDown="true"  waitTarget="mx.managers::DragManager.mx_internal:dragProxy" waitEvent="move"/>
+                <DispatchMouseEvent target="stage" type="mouseMove" localX="480" localY="75" buttonDown="true"  />
+                <DispatchMouseEvent target="stage" type="mouseUp" localX="480" localY="75" waitEvent="dragDrop" waitTarget="secondTree" />
+                <AssertPropertyValue propertyName="length" target="secondTree.dataProvider" value="2" />
+                <AssertPropertyValue propertyName="label" target="firstTree.mx_internal:rendererArray.2.0.listData" value="Juice" />
+             </body>
+        </TestCase>
+
+        <TestCase testID="DragManager_TreeToTree_dragEnabledFalse" description="Test that you cannot drag when dragEnabled=false." keywords="[DragManager, Tree]">
+            <setup>
+               <ResetComponent target="firstTree" className="mx.controls.Tree" waitTarget="firstTree" waitEvent="updateComplete" />
+               <SetProperty propertyName="width" value="250" target="firstTree" />
+               <RunCode code="getDataXML()" waitTarget="firstTree" waitEvent="updateComplete" />
+               <ResetComponent target="secondTree" className="mx.controls.Tree" waitTarget="secondTree" waitEvent="updateComplete" />
+               <SetProperty propertyName="dropEnabled" value="true" target="secondTree" />
+               <SetProperty propertyName="dataProvider" valueExpression="value=[];" target="secondTree" />
+               <SetProperty propertyName="width" value="250" target="secondTree" />
+               <SetProperty propertyName="labelField" value="@label" target="secondTree" />
+             </setup>
+             <body>
+                <DispatchMouseClickEvent target="firstTree.mx_internal:rendererArray.0.0" localX="5" localY="5"  />
+                <WaitForEffectsToEnd/>
+                <DispatchMouseEvent target="firstTree.mx_internal:rendererArray.1.0.getChildAt(0)" type="mouseOver" localX="10" localY="8" buttonDown="true" />
+                <DispatchMouseEvent target="firstTree.mx_internal:rendererArray.1.0.getChildAt(0)" type="mouseDown" localX="10" localY="8" buttonDown="true" />
+                <DispatchMouseEvent target="stage" type="mouseMove" localX="100" localY="75" buttonDown="true"
+                    waitTarget="mx.managers::DragManager.mx_internal:dragProxy" />
+                <WaitForEffectsToEnd/>
+                <DispatchMouseEvent target="stage" type="mouseMove" localX="200" localY="75" buttonDown="true"  waitTarget="mx.managers::DragManager.mx_internal:dragProxy" />
+                <DispatchMouseEvent target="stage" type="mouseMove" localX="260" localY="75" buttonDown="true"  waitTarget="mx.managers::DragManager.mx_internal:dragProxy" />
+                <DispatchMouseEvent target="stage" type="mouseMove" localX="350" localY="75" buttonDown="true"  waitTarget="mx.managers::DragManager.mx_internal:dragProxy" />
+                <DispatchMouseEvent target="stage" type="mouseMove" localX="480" localY="85" buttonDown="true"  waitTarget="mx.managers::DragManager.mx_internal:dragProxy" />
+                <DispatchMouseEvent target="stage" type="mouseUp" localX="480" localY="85" />
+                <WaitForEffectsToEnd/>
+                <AssertPropertyValue propertyName="length" target="secondTree.dataProvider" value="0" />
+                <AssertPropertyValue propertyName="label" target="firstTree.mx_internal:rendererArray.1.0.listData" value="Inbox" />
+             </body>
+        </TestCase>
+        <TestCase testID="DragManager_TreeToTree_dragEnabledTrue" description="Test that you can drag when dragEnabled=true." keywords="[DragManager, Tree, Drop]">
+            <setup>
+               <ResetComponent target="firstTree" className="mx.controls.Tree" waitTarget="firstTree" waitEvent="updateComplete" />
+               <SetProperty propertyName="width" value="250" target="firstTree" />
+               <RunCode code="getDataXML()" waitTarget="firstTree" waitEvent="updateComplete" />
+               <ResetComponent target="secondTree" className="mx.controls.Tree" waitTarget="secondTree" waitEvent="updateComplete" />
+               <SetProperty propertyName="dragEnabled" value="true" target="firstTree" />
+               <SetProperty propertyName="dropEnabled" value="true" target="secondTree" />
+               <SetProperty propertyName="dataProvider" valueExpression="value=[];" target="secondTree" />
+               <SetProperty propertyName="width" value="250" target="secondTree" />
+               <SetProperty propertyName="labelField" value="@label" target="secondTree" />
+             </setup>
+             <body>
+                <DispatchMouseClickEvent target="firstTree.mx_internal:rendererArray.0.0" localX="5" localY="5"  />
+                <WaitForEffectsToEnd/>
+                <Pause timeout="100" />
+                <DispatchMouseEvent target="firstTree.mx_internal:rendererArray.1.0.getChildAt(0)" type="mouseOver" localX="10" localY="8" buttonDown="true" />
+                <DispatchMouseEvent target="firstTree.mx_internal:rendererArray.1.0.getChildAt(0)" type="mouseDown" localX="10" localY="8" buttonDown="true" />
+                <DispatchMouseEvent target="stage" type="mouseMove" localX="100" localY="55" buttonDown="true"
+                    waitTarget="mx.managers::DragManager.mx_internal:dragProxy" />
+                <WaitForEffectsToEnd/>
+                <DispatchMouseEvent target="stage" type="mouseMove" localX="200" localY="55" buttonDown="true"  waitTarget="mx.managers::DragManager.mx_internal:dragProxy" />
+                <DispatchMouseEvent target="stage" type="mouseMove" localX="260" localY="55" buttonDown="true"  waitTarget="mx.managers::DragManager.mx_internal:dragProxy" />
+                <DispatchMouseEvent target="stage" type="mouseMove" localX="350" localY="55" buttonDown="true"  waitTarget="mx.managers::DragManager.mx_internal:dragProxy" />
+                <DispatchMouseEvent target="stage" type="mouseMove" localX="480" localY="65" buttonDown="true"  waitTarget="mx.managers::DragManager.mx_internal:dragProxy" />
+                <DispatchMouseEvent target="stage" type="mouseUp" localX="480" localY="65" />
+                <WaitForEffectsToEnd/>
+                <AssertPropertyValue propertyName="length" target="secondTree.dataProvider" value="1" />
+                <AssertPropertyValue propertyName="label" target="secondTree.mx_internal:rendererArray.0.0.listData" value="Inbox" />
+              </body>
+        </TestCase>
+        <TestCase testID="DragManager_TreeToTree_dataProviderIsObject" description="Ensure that Drag and Drop works for Trees with Object dataProviders"
+            keywords="[Tree, Drag and Drop, dataProvider]" >
+               <setup>
+                   <ResetComponent target="firstTree" className="mx.controls.Tree" waitTarget="firstTree" waitEvent="updateComplete" />
+               </setup>
+               <body>
+                   <RunCode code="getDataAS();" waitTarget="firstTree" waitEvent="updateComplete" />
+                   <SetProperty target="firstTree" propertyName="dragEnabled" value="true" />
+                   <SetProperty target="firstTree" propertyName="dragMoveEnabled" value="true" />
+                   <SetProperty target="firstTree" propertyName="dropEnabled" value="true" />
+                   <DispatchMouseClickEvent target="firstTree.mx_internal:rendererArray.0.0" localX="5" localY="5" />
+                   <WaitForEffectsToEnd/>
+                   <Pause timeout="100" />
+                   <DispatchMouseEvent target="firstTree.mx_internal:rendererArray.1.0.getChildAt(0)" type="mouseOver" localX="10" localY="8" buttonDown="true" />
+                   <WaitForEffectsToEnd/>
+                   <DispatchMouseEvent target="firstTree.mx_internal:rendererArray.1.0.getChildAt(0)" type="mouseDown" localX="10" localY="8" buttonDown="true" />
+                   <WaitForEffectsToEnd/>
+                   <DispatchMouseEvent target="stage" type="mouseMove" localX="90" localY="75" buttonDown="true"
+                        waitTarget="mx.managers::DragManager.mx_internal:dragProxy" />
+                   <WaitForEffectsToEnd/>
+                   <DispatchMouseEvent target="stage" type="mouseMove" localX="100" localY="85" buttonDown="true"   waitTarget="mx.managers::DragManager.mx_internal:dragProxy" />
+                   <WaitForEffectsToEnd/>
+                   <DispatchMouseEvent target="stage" type="mouseMove" localX="105" localY="95" buttonDown="true"   waitTarget="mx.managers::DragManager.mx_internal:dragProxy" />
+                   <WaitForEffectsToEnd/>
+                   <DispatchMouseEvent target="stage" type="mouseMove" localX="105" localY="100" buttonDown="true"  waitTarget="mx.managers::DragManager.mx_internal:dragProxy" />
+                   <WaitForEffectsToEnd/>
+                   <DispatchMouseEvent target="stage" type="mouseMove" localX="105" localY="105" buttonDown="true"  waitTarget="mx.managers::DragManager.mx_internal:dragProxy" />
+                   <DispatchMouseEvent target="stage" type="mouseUp" localX="105" localY="105" waitEvent="dragDrop" waitTarget="firstTree" />
+                   <AssertPropertyValue propertyName="label" target="firstTree.mx_internal:rendererArray.3.0.listData" value="StringUtil.as" />
+               </body>
+        </TestCase>
+    </testCases>
+</UnitTester>

Added: incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/baselines/DragManager_Mirroring_defaultDragImageSkin.png
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/baselines/DragManager_Mirroring_defaultDragImageSkin.png?rev=1369970&view=auto
==============================================================================
Binary file - no diff available.

Propchange: incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/baselines/DragManager_Mirroring_defaultDragImageSkin.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/baselines/copyCursor_custom.png
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/baselines/copyCursor_custom.png?rev=1369970&view=auto
==============================================================================
Binary file - no diff available.

Propchange: incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/baselines/copyCursor_custom.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/baselines/customDragProxy.png
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/baselines/customDragProxy.png?rev=1369970&view=auto
==============================================================================
Binary file - no diff available.

Propchange: incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/baselines/customDragProxy.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/baselines/customDropIndicatorSkin.png
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/baselines/customDropIndicatorSkin.png?rev=1369970&view=auto
==============================================================================
Binary file - no diff available.

Propchange: incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/baselines/customDropIndicatorSkin.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/baselines/moveCursor_custom.png
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/baselines/moveCursor_custom.png?rev=1369970&view=auto
==============================================================================
Binary file - no diff available.

Propchange: incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/baselines/moveCursor_custom.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/baselines/rejectCursor_custom.png
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/baselines/rejectCursor_custom.png?rev=1369970&view=auto
==============================================================================
Binary file - no diff available.

Propchange: incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/baselines/rejectCursor_custom.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/baselines/showDropFeedbackTest.png
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/baselines/showDropFeedbackTest.png?rev=1369970&view=auto
==============================================================================
Binary file - no diff available.

Propchange: incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/baselines/showDropFeedbackTest.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/data/ListDataAS.as
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/data/ListDataAS.as?rev=1369970&view=auto
==============================================================================
--- incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/data/ListDataAS.as (added)
+++ incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/data/ListDataAS.as Mon Aug  6 20:17:09 2012
@@ -0,0 +1,44 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package data {
+
+    public class ListDataAS  {
+    
+        public var myData:Object;
+        public function ListDataAS(): void
+        {
+            var date1:Date = new Date(2007,4,20);
+			var date2:Date = new Date(2007,0,15);
+            var date3:Date = new Date(2007,9,24); 
+            
+            myData = [
+						{label:"Toys", available:false, quantity: 0, shipDate: date1, url: "../../../../../Assets/Images/redrect.jpg", color: "Red"}, 
+						{label:"Stuffed Animals", available:false, quantity: 0, shipDate: date1, url: "../../../../../Assets/Images/orangerect.jpg", color: "Red"}, 
+						{label:"Stuffed Bears", available:true, quantity: 2, shipDate: date2, url: "../../../../../Assets/Images/brownrect.jpg", color: "Green"}, 
+						{label:"Dinosaur", available:true, quantity: 8, shipDate: date1, url: "../../../../../Assets/Images/purplerect.jpg", color: "Fuscia"}, 
+						{label:"Movies", available:true, quantity: 9, shipDate: date1, url: "../../../../../Assets/Images/yellowrect.jpg", color: "Yellow"}, 
+						{label:"Games", available:false, quantity: 0, shipDate: date2, url: "../../../../../Assets/Images/greenrect.jpg", color: "Black"}, 
+						{label:"Board Games", available:false, quantity: 0, shipDate: date3, url: "../../../../../Assets/Images/bluerect.jpg", color: "Black"}, 
+						{label:"White Squares", available:true, quantity: 4, shipDate: date3, url: "../../../../../Assets/Images/whiterect.jpg", color: "White"}, 
+						{label:"Some Action Figure", available:false, quantity: 0, shipDate: date1, url: "../../../../../Assets/Images/blackrect.jpg", color: "Rose"}, 
+						{label:"Video Game",available:true, quantity: 8, shipDate: date3, url: "../../../../../Assets/Images/cyanrect.jpg", color: "Periwinkle"}, 
+					  ]; 
+        }
+    }
+}
\ No newline at end of file

Added: incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/data/TreeData.as
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/data/TreeData.as?rev=1369970&view=auto
==============================================================================
--- incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/data/TreeData.as (added)
+++ incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/data/TreeData.as Mon Aug  6 20:17:09 2012
@@ -0,0 +1,43 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package data {
+    
+    import XMLList;
+    
+    public class TreeData  {
+    
+        public var myData:XMLList;
+        public function TreeData(): void
+        {
+                 myData =
+			     <>
+			     <root>
+			         <nodes label="Mail" data="mail">
+			             <nodes label="Inbox" data="inbox" />
+			         </nodes>
+			         <nodes label="Drafts" data="drafts">
+			             <nodes label="Memos" data="memos" />
+			             <nodes label="Faxes" data="faxes" />
+			             <node label="Juice" data="juice" />
+			         </nodes>
+			     </root>
+                 </>;
+        }
+    }
+}
\ No newline at end of file

Added: incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/data/TreeData2.as
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/data/TreeData2.as?rev=1369970&view=auto
==============================================================================
--- incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/data/TreeData2.as (added)
+++ incubator/flex/trunk/mustella/tests/Managers/DragManager/Spark/data/TreeData2.as Mon Aug  6 20:17:09 2012
@@ -0,0 +1,46 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package data {
+    
+    public class TreeData2  {
+    
+        public var myData:Object;
+        public function TreeData2(): void
+        {
+            myData =
+				 {fileName:"mx", Summary:"true", children: [
+				 	{fileName: "utils", children: [
+				 		{fileName: "StringUtil.as", Summary:"true", size:"5563 bytes", lastModified:"October 6, 2006", type:"File", attributes:"Read Only"},
+				 		{fileName: "ArrayUtil.as", size:"2509 bytes", lastModified:"June 12, 2006", type:"File", attributes:"Read Only"}
+				 	]},
+				 	{fileName:"accessibility", Summary:"false", children: [
+				 		{fileName:"DataGridAccImpl.as", size:"17045 bytes", lastModified:"November 2, 2006", type:"File", attributes:"Read Only"},
+				 		{fileName:"AccImpl.as", Summary:"true", size:"7263 bytes", lastModified:"June 1, 2006", type:"File", attributes:"Read Only"}
+				 	]},
+				 	{fileName: "controls", children: [
+				 		{fileName: "DataGrid.as", size:"169825 bytes", lastModified:"December 6, 2006", type:"File", attributes:"Read Only"},
+				 		{fileName: "dataGridClasses", children: [
+				 			{fileName: "DataGridItemRenderer.as", size:"18587 bytes", lastModified:"November 20, 2006", type:"File", attributes:"Read Only"},
+				 			{fileName: "DataGridBase.as", size:"36419 bytes", lastModified:"December 6, 2006", type:"File", attributes:"Read Only"}
+				 		]}
+				 	]}
+				 ]}
+        }
+    }
+}
\ No newline at end of file

Added: incubator/flex/trunk/mustella/tests/Managers/DragManager/smoke.properties
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/tests/Managers/DragManager/smoke.properties?rev=1369970&view=auto
==============================================================================
--- incubator/flex/trunk/mustella/tests/Managers/DragManager/smoke.properties (added)
+++ incubator/flex/trunk/mustella/tests/Managers/DragManager/smoke.properties Mon Aug  6 20:17:09 2012
@@ -0,0 +1,38 @@
+################################################################################
+##
+##  Licensed to the Apache Software Foundation (ASF) under one or more
+##  contributor license agreements.  See the NOTICE file distributed with
+##  this work for additional information regarding copyright ownership.
+##  The ASF licenses this file to You under the Apache License, Version 2.0
+##  (the "License"); you may not use this file except in compliance with
+##  the License.  You may obtain a copy of the License at
+##
+##      http://www.apache.org/licenses/LICENSE-2.0
+##
+##  Unless required by applicable law or agreed to in writing, software
+##  distributed under the License is distributed on an "AS IS" BASIS,
+##  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+##  See the License for the specific language governing permissions and
+##  limitations under the License.
+##
+################################################################################
+DragManager_ComponentTests
+DragManager_ComponentTests$DragManager_ListToList_singleMove
+DragManager_ComponentTests$DragManager_ListToList_multipleMove
+DragManager_ComponentTests$DragManager_ListToList_singleCopy
+DragManager_ComponentTests$DragManager_ListToList_multipleCopy
+DragManager_ComponentTests$DragManager_DGridToDGrid_singleMove
+DragManager_ComponentTests$DragManager_DataGridToDataGrid_multipleMove
+DragManager_ComponentTests$DragManager_DataGridToDataGrid_singleCopy
+DragManager_ComponentTests$DragManager_DataGridToDataGrid_multipleCopy
+DragManager_ComponentTests$DragManager_TileListToTileList_singleMove
+DragManager_ComponentTests$DragManager_TileListToTileList_singleCopy
+DragManager_TreeTests
+DragManager_TreeTests$DragManager_TreeToTree_singleMove
+DragManager_TreeTests$DragManager_TreeToTree_multipleMove
+DragManager_EventsTests
+DragManager_EventsTests$DragManager_dragStart_single
+DragManager_EventsTests$DragManager_dragEnter_single
+DragManager_EventsTests$DragManager_dragDrop_single
+DragManager_EventsTests$DragManager_dragExit_single
+DragManager_EventsTests$DragManager_dragComplete_single_dropped
\ No newline at end of file

Added: incubator/flex/trunk/mustella/tests/Managers/LayoutManager/Events/LayoutManager_Events_SparkTests.mxml
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/tests/Managers/LayoutManager/Events/LayoutManager_Events_SparkTests.mxml?rev=1369970&view=auto
==============================================================================
--- incubator/flex/trunk/mustella/tests/Managers/LayoutManager/Events/LayoutManager_Events_SparkTests.mxml (added)
+++ incubator/flex/trunk/mustella/tests/Managers/LayoutManager/Events/LayoutManager_Events_SparkTests.mxml Mon Aug  6 20:17:09 2012
@@ -0,0 +1,61 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+
+-->
+<UnitTester testDir="Managers/LayoutManager/Events/"  xmlns:mx="http://www.adobe.com/2006/mxml" xmlns="*" testSWF="LayoutManager_Events_Spark.mxml">
+
+    <mx:Script>
+	<![CDATA[
+
+       public static function init(o:DisplayObject):void
+		{
+
+		}
+
+	]]>
+	</mx:Script>
+
+	<mx:Metadata>
+	<![CDATA[
+		[Mixin]
+	]]>
+	</mx:Metadata>
+
+	<testCases>
+<!-- updateComplete event -->
+	    <TestCase testID="LayoutManager_events_updateComplete_addChild" description="Ensure that the updateComplete event is sent when addChild is called. This should cover SDK-20994"
+	        keywords="[LayoutManager, updateComplete, addChild, bug]">
+			<body>
+			     <RunCode code="application.addChildToCanvas()" waitEvent="added" waitTarget="canvas1" />
+			     <AssertEvent eventName="updateComplete" eventClass="mx.events::FlexEvent" target="managerInstance" />
+			</body>
+	    </TestCase>
+	    <TestCase testID="LayoutManager_events_updateComplete_addElement" description="Ensure that the updateComplete event is sent when addElement is called. This should cover SDK-20994"
+	        keywords="[LayoutManager, updateComplete, addElement, bug]">
+			<setup>
+			    <ResetComponent target="group1" className="spark.components.Group" waitTarget="group1" waitEvent="updateComplete"/>
+			</setup>
+			<body>
+			     <RunCode code="application.addElementToGroup()" waitEvent="added" waitTarget="group1" />
+			     <AssertEvent eventName="updateComplete" eventClass="mx.events::FlexEvent" target="managerInstance" numExpectedEvents="1"
+			          timeout="2000" />
+			</body>
+	    </TestCase>
+
+	</testCases>
+</UnitTester>

Added: incubator/flex/trunk/mustella/tests/Managers/LayoutManager/SWFs/LayoutManager_Events_Spark.mxml
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/tests/Managers/LayoutManager/SWFs/LayoutManager_Events_Spark.mxml?rev=1369970&view=auto
==============================================================================
--- incubator/flex/trunk/mustella/tests/Managers/LayoutManager/SWFs/LayoutManager_Events_Spark.mxml (added)
+++ incubator/flex/trunk/mustella/tests/Managers/LayoutManager/SWFs/LayoutManager_Events_Spark.mxml Mon Aug  6 20:17:09 2012
@@ -0,0 +1,64 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+
+-->
+<s:Application
+       xmlns:fx="http://ns.adobe.com/mxml/2009"
+       xmlns:d="http://ns.adobe.com/fxg/2008/dt"
+       xmlns:s="library://ns.adobe.com/flex/spark"
+       width="800" height="600" backgroundColor="#ffffff" xmlns:mx="library://ns.adobe.com/flex/mx" creationComplete="init()">
+   <s:layout>
+       <s:VerticalLayout />
+   </s:layout>
+   <fx:Script>
+       <![CDATA[
+           import mx.core.mx_internal;
+           import spark.components.Button;
+           import mx.managers.LayoutManager;
+
+           public var testSprite:Sprite;
+           public var managerInstance:LayoutManager;
+
+           public function init(): void
+           {
+               managerInstance = LayoutManager.getInstance();
+           }
+
+           public function addElementToGroup():void
+           {
+               var myBtn:Button = new Button();
+               myBtn.label="hello";
+               group1.addElement(myBtn);
+
+           }
+
+           public function addChildToCanvas():void
+           {
+               var myBtn2:Button = new Button();
+               myBtn2.label="hello again";
+               canvas1.addChild(myBtn2);
+           }
+
+       ]]>
+   </fx:Script>
+
+   <s:Group id="group1">
+       <mx:Canvas id="canvas1"/>
+   </s:Group>
+
+</s:Application>
\ No newline at end of file

Added: incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Events/PopUpManager_events.mxml
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Events/PopUpManager_events.mxml?rev=1369970&view=auto
==============================================================================
--- incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Events/PopUpManager_events.mxml (added)
+++ incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Events/PopUpManager_events.mxml Mon Aug  6 20:17:09 2012
@@ -0,0 +1,84 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+
+-->
+<UnitTester testDir="Managers/PopUpManager/Events/"  xmlns:mx="http://www.adobe.com/2006/mxml" xmlns="*" testSWF="PopUpManager_Basic.mxml">
+
+    <mx:Script>
+	<![CDATA[
+
+       public static function init(o:DisplayObject):void
+		{
+
+		}
+
+		public function cleanUpPopUps(): void
+		{
+		    if(application.parent.numChildren > 1)
+		    {
+		        var popups:int = application.parent.popUpChildren.numChildren;
+				if(popups > 0)
+				{
+					for (var i:int=0; i<popups; i++)
+					{
+						application.parent.removeChild(application.parent.popUpChildren.getChildAt(i));
+					}
+				}
+		    }
+		}
+	]]>
+	</mx:Script>
+
+	<mx:Metadata>
+	<![CDATA[
+		[Mixin]
+	]]>
+	</mx:Metadata>
+
+	<testCases>
+    <!--mouseDownOutside event -->
+        <TestCase testID="PopUpManager_mouseDownOutside_modal" description="Test the mouseDownOutside event for a modal popup" keywords="[mouseDownOutside, PopUpManager]">
+			<setup>
+			    <RunCode code="cleanUpPopUps()" />
+			    <WaitForEffectsToEnd />
+			    <!--<RunCode code="application.openWindow(true)" waitTarget="systemManager.topLevelSystemManager.getChildAt(0)" waitEvent="updateComplete" />-->
+			    <RunCode code="application.openWindow(true)" waitTarget="systemManager.topLevelSystemManager.getChildAt(0)" waitEvent="updateComplete" />
+			    <WaitForEffectsToEnd/>
+			</setup>
+			<body>
+			    <DispatchMouseEvent target="" type="mouseDown" localX="305" localY="205"  />
+	            <AssertEvent eventName="mouseDownOutside" eventClass="mx.events::FlexMouseEvent" target="iPopUp" />
+			    <DispatchMouseEvent target="" type="mouseUp" localX="305" localY="205"  />
+			    <RunCode code="application.closeWindow(application.iPopUp)" />
+			</body>
+		</TestCase>
+        <TestCase testID="PopUpManager_mouseDownOutside_nonmodal" description="Test the mouseDownOutside event for a non-modal popup" keywords="[mouseDownOutside, PopUpManager]">
+			<setup>
+			    <RunCode code="cleanUpPopUps()" />
+			    <WaitForEffectsToEnd />
+			    <RunCode code="application.openWindow(false)" waitTarget="systemManager.topLevelSystemManager.getChildAt(0)" waitEvent="updateComplete" />
+			</setup>
+			<body>
+			    <DispatchMouseEvent target="" type="mouseDown" localX="305" localY="205"  />
+	            <AssertEvent eventName="mouseDownOutside" eventClass="mx.events::FlexMouseEvent" target="iPopUp" />
+			    <DispatchMouseEvent target="" type="mouseUp" localX="305" localY="205"  />
+			    <RunCode code="application.closeWindow(application.iPopUp)" />
+			</body>
+		</TestCase>
+	</testCases>
+</UnitTester>

Added: incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Events/PopUpManager_events_spark.mxml
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Events/PopUpManager_events_spark.mxml?rev=1369970&view=auto
==============================================================================
--- incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Events/PopUpManager_events_spark.mxml (added)
+++ incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Events/PopUpManager_events_spark.mxml Mon Aug  6 20:17:09 2012
@@ -0,0 +1,82 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+
+-->
+<UnitTester testDir="Managers/PopUpManager/Events/"  xmlns:mx="http://www.adobe.com/2006/mxml" xmlns="*" testSWF="PopUpManager_Basic_spark.mxml">
+
+    <mx:Script>
+	<![CDATA[
+
+       public static function init(o:DisplayObject):void
+		{
+
+		}
+
+		public function cleanUpPopUps(): void
+		{
+		    if(application.parent.numChildren > 1)
+		    {
+		        var popups:int = application.parent.popUpChildren.numChildren;
+				if(popups > 0)
+				{
+					for (var i:int=0; i<popups; i++)
+					{
+						application.parent.removeChild(application.parent.popUpChildren.getChildAt(i));
+					}
+				}
+		    }
+		}
+	]]>
+	</mx:Script>
+
+	<mx:Metadata>
+	<![CDATA[
+		[Mixin]
+	]]>
+	</mx:Metadata>
+
+	<testCases>
+    <!--mouseDownOutside event -->
+        <TestCase testID="PopUpManager_mouseDownOutside_nonmodal" description="Test the mouseDownOutside event for a non-modal popup" keywords="[mouseDownOutside, PopUpManager]">
+			<setup>
+			    <RunCode code="cleanUpPopUps()" />
+			    <WaitForEffectsToEnd />
+			    <RunCode code="application.openWindow(false)" waitTarget="systemManager" waitEvent="added" />
+			</setup>
+			<body>
+			    <DispatchMouseEvent target="" type="mouseDown" localX="305" localY="205"  />
+	            <AssertEvent eventName="mouseDownOutside" eventClass="mx.events::FlexMouseEvent" target="iPopUp" />
+			    <DispatchMouseEvent target="" type="mouseUp" localX="305" localY="205"  />
+			    <RunCode code="application.closeWindow(application.iPopUp)" />
+			</body>
+		</TestCase>
+        <TestCase testID="PopUpManager_mouseDownOutside_modal" description="Test the mouseDownOutside event for a modal popup" keywords="[mouseDownOutside, PopUpManager]">
+			<setup>
+			    <RunCode code="cleanUpPopUps()" />
+			    <WaitForEffectsToEnd />
+			    <RunCode code="application.openWindow(true)" waitTarget="systemManager" waitEvent="added" />
+			</setup>
+			<body>
+			    <DispatchMouseEvent target="" type="mouseDown" localX="305" localY="205"  />
+	            <AssertEvent eventName="mouseDownOutside" eventClass="mx.events::FlexMouseEvent" target="iPopUp" />
+			    <DispatchMouseEvent target="" type="mouseUp" localX="305" localY="205"  />
+			    <RunCode code="application.closeWindow(application.iPopUp)" />
+			</body>
+		</TestCase>
+	</testCases>
+</UnitTester>

Added: incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Methods/PopUpManager_Bug148179Test.mxml
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Methods/PopUpManager_Bug148179Test.mxml?rev=1369970&view=auto
==============================================================================
--- incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Methods/PopUpManager_Bug148179Test.mxml (added)
+++ incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Methods/PopUpManager_Bug148179Test.mxml Mon Aug  6 20:17:09 2012
@@ -0,0 +1,50 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+
+-->
+<UnitTester testDir="Managers/PopUpManager/Methods/"  xmlns:mx="http://www.adobe.com/2006/mxml" xmlns="*" testSWF="PopUpManager_Bug148179.mxml">
+
+    <mx:Script>
+    <![CDATA[
+
+       public static function init(o:DisplayObject):void
+        {
+
+        }
+
+    ]]>
+    </mx:Script>
+
+    <mx:Metadata>
+    <![CDATA[
+        [Mixin]
+    ]]>
+    </mx:Metadata>
+
+    <testCases>
+        <TestCase testID="PopUpManager_bug148179" description="Bug #148179: centerPopUp doesn't work when called from creationComplete" keywords="[Bugs, centerPopUp, PopUpManager]">
+            <setup>
+                <SetStyle styleName="backgroundColor" target="iPopUp" value="0x00FF00" waitEvent="updateComplete" waitTarget="iPopUp" />
+            </setup>
+            <body>
+                <AssertPropertyValue propertyName="x" target="iPopUp" value="200" />
+                <AssertPropertyValue propertyName="y" target="iPopUp" value="225" />
+            </body>
+        </TestCase>
+    </testCases>
+</UnitTester>

Added: incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Methods/PopUpManager_methods.mxml
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Methods/PopUpManager_methods.mxml?rev=1369970&view=auto
==============================================================================
--- incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Methods/PopUpManager_methods.mxml (added)
+++ incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Methods/PopUpManager_methods.mxml Mon Aug  6 20:17:09 2012
@@ -0,0 +1,186 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+
+-->
+<UnitTester testDir="Managers/PopUpManager/Methods/"  xmlns:mx="http://www.adobe.com/2006/mxml" xmlns="*" testSWF="PopUpManager_Basic.mxml">
+
+    <mx:Script>
+	<![CDATA[
+
+       import mx.managers.PopUpManager;
+       public static function init(o:DisplayObject):void
+		{
+
+		}
+
+		public function cleanUpPopUps(): void
+		{
+		    if(application.parent.numChildren > 1)
+		    {
+		        var popups:int = application.parent.popUpChildren.numChildren;
+				if(popups > 0)
+				{
+					for (var i:int=0; i<popups; i++)
+					{
+						application.parent.removeChild(application.parent.popUpChildren.getChildAt(i));
+					}
+				}
+		    }
+		}
+
+	]]>
+	</mx:Script>
+
+	<mx:Metadata>
+	<![CDATA[
+		[Mixin]
+	]]>
+	</mx:Metadata>
+
+	<testCases>
+    <!--method: centerPopUp -->
+        <TestCase testID="PopUpManager_centerPopUp_modal" description="Test the centerPopUp method for a modal popup" keywords="[centerPopUp, PopUpManager]">
+			<setup>
+			    <RunCode code="cleanUpPopUps()" />
+			    <WaitForEffectsToEnd />
+			    <RunCode code="application.openWindow4(true)" waitTarget="systemManager.topLevelSystemManager.getChildAt(0)" waitEvent="updateComplete" />
+			</setup>
+			<body>
+			    <RunCode code="application.centerMyPopUp()" waitTarget="iPopUp" waitEvent="move" />
+			    <AssertPropertyValue propertyName="x" target="iPopUp" value="200" />
+			    <AssertPropertyValue propertyName="y" target="iPopUp" value="225" />
+			    <RunCode code="application.closeWindow(application.iPopUp)" />
+			</body>
+		</TestCase>
+        <TestCase testID="PopUpManager_centerPopUp_nonmodal" description="Test the centerPopUp method for a non-modal popup" keywords="[centerPopUp, PopUpManager]">
+			<setup>
+			    <RunCode code="cleanUpPopUps()" />
+			    <WaitForEffectsToEnd />
+			    <RunCode code="application.openWindow4(false)" />
+			    <WaitForEffectsToEnd />
+			    
+			</setup>
+			<body>
+			    <RunCode code="application.centerMyPopUp()" waitTarget="iPopUp" waitEvent="move" />
+			    <AssertPropertyValue propertyName="x" target="iPopUp" value="200" />
+			    <AssertPropertyValue propertyName="y" target="iPopUp" value="225" />
+			    <!--RunCode code="application.closeWindow(application.iPopUp)" waitTarget="systemManager.topLevelSystemManager.getChildAt(0)" waitEvent="updateComplete" /-->
+			    <RunCode code="PopUpManager.removePopUp(application.iPopUp)" />
+			    <WaitForEffectsToEnd />
+			    
+			</body>
+		</TestCase>
+    <!--method: createPopUP Note, the first test requires a Pause because it is testing that when a modal dialog is up,
+        you cannot edit the parent application. So, when an edit is attempted, no actual events are triggered. -->
+        <TestCase testID="PopUpManager_createPopUP_modal" description="Test the createPopUP method for a modal popup" keywords="[createPopUp, PopUpManager]">
+			<setup>
+			    <RunCode code="cleanUpPopUps()" />
+			    <WaitForEffectsToEnd />
+			    <ResetComponent target="ta" className="mx.controls.TextInput" waitTarget="ta" waitEvent="updateComplete"/>
+			    <RunCode code="application.openWindow(true)" waitTarget="systemManager.topLevelSystemManager.getChildAt(0)" waitEvent="updateComplete" />
+			</setup>
+			<body>
+			    <DispatchMouseClickEvent localX="330" localY="33" target="" waitEvent="mouseDownOutside" waitTarget="iPopUp"/>
+			    <DispatchKeyEvent char="Hello" />
+			    <!--Pause timeout="200" /-->
+			    <WaitForEffectsToEnd />
+			    <AssertPropertyValue target="ta" propertyName="text" value="" />
+			    <RunCode code="application.closeWindow(application.iPopUp)"  waitTarget="systemManager.topLevelSystemManager.getChildAt(0)" waitEvent="effectEnd"/>
+			</body>
+		</TestCase>
+        <TestCase testID="PopUpManager_createPopUP_nonmodal" description="Test the createPopUP method for a non-modal popup" keywords="[createPopUp, PopUpManager]">
+			<setup>
+			    <RunCode code="cleanUpPopUps()" />
+			    <WaitForEffectsToEnd />
+			    <ResetComponent target="ta" className="mx.controls.TextInput" waitTarget="ta" waitEvent="updateComplete"/>
+			    <RunCode code="application.openWindow(false)" />
+			    <WaitForEffectsToEnd />
+			</setup>
+			<body>
+			    <DispatchMouseClickEvent localX="330" localY="33" target="" waitEvent="mouseDownOutside" waitTarget="iPopUp"/>
+			    <DispatchKeyEvent char="Hello" waitTarget="ta" waitEvent="change" />
+			    <AssertPropertyValue target="ta" propertyName="text" value="Hello" />
+			    <RunCode code="PopUpManager.removePopUp(application.iPopUp)" waitTarget="iPopUp" waitEvent="remove" />
+			 </body>
+		</TestCase>
+      <TestCase testID="PopUpManager_createPopUP_parent_modal" description="Test the createPopUP method for a modal popup when setting the parent argument" keywords="[createPopUp, parent, PopUpManager]">
+			<setup>
+			    <RunCode code="cleanUpPopUps()" />
+			    <WaitForEffectsToEnd />
+			    <ResetComponent target="ta" className="mx.controls.TextInput" waitTarget="ta" waitEvent="updateComplete"/>
+			    <RunCode code="application.openWindow6(true)" waitTarget="systemManager.topLevelSystemManager.getChildAt(0)" waitEvent="updateComplete" />
+			</setup>
+			<body>
+			    <DispatchMouseClickEvent localX="330" localY="33" target="" waitEvent="mouseDownOutside" waitTarget="iPopUp"/>
+			    <DispatchKeyEvent char="Hello" />
+			    <!--Pause timeout="200" /-->
+			    <WaitForEffectsToEnd />
+			    <AssertPropertyValue target="ta" propertyName="text" value="" />
+			    <RunCode code="application.closeWindow(application.iPopUp)" waitTarget="systemManager.topLevelSystemManager.getChildAt(0)" waitEvent="effectEnd" />
+			</body>
+		</TestCase>
+        <TestCase testID="PopUpManager_createPopUP_parent_nonmodal" description="Test the createPopUP method for a non-modal popup when setting the parent argument" keywords="[createPopUp, parent, PopUpManager]">
+			<setup>
+			    <RunCode code="cleanUpPopUps()" />
+			    <WaitForEffectsToEnd />
+			    <ResetComponent target="ta" className="mx.controls.TextInput" waitTarget="ta" waitEvent="updateComplete"/>
+			    <RunCode code="application.openWindow6(false)" />
+			    <WaitForEffectsToEnd />
+			</setup>
+			<body>
+			    <DispatchMouseClickEvent localX="330" localY="33" target="" waitEvent="mouseDownOutside" waitTarget="iPopUp"/>
+			    <DispatchKeyEvent char="Hello" waitTarget="ta" waitEvent="change" />
+			    <AssertPropertyValue target="ta" propertyName="text" value="Hello" />
+			    <RunCode code="PopUpManager.removePopUp(application.iPopUp)" waitTarget="iPopUp" waitEvent="remove" />
+			</body>
+		</TestCase>
+    <!--method: addPopUp Note, the first test requires a Pause because it is testing that when a modal dialog is up,
+        you cannot edit the parent application. So, when an edit is attempted, no actual events are triggered. -->
+        <TestCase testID="PopUpManager_addPopUp_modal" description="Test the addPopUp method for a modal popup" keywords="[addPopUp, PopUpManager]">
+			<setup>
+			    <RunCode code="cleanUpPopUps()" />
+			    <WaitForEffectsToEnd />
+			    <ResetComponent target="ta" className="mx.controls.TextInput" waitTarget="ta" waitEvent="updateComplete"/>
+			    <RunCode code="application.addWindow(true)" waitTarget="systemManager.topLevelSystemManager.getChildAt(0)" waitEvent="updateComplete" />
+			</setup>
+			<body>
+			    <DispatchMouseClickEvent localX="330" localY="33" target="" waitEvent="mouseDownOutside" waitTarget="iPanel"/>
+			    <DispatchKeyEvent char="Hello" />
+			    <!--Pause timeout="200" /-->
+			    <WaitForEffectsToEnd />
+			    <AssertPropertyValue target="ta" propertyName="text" value="" />
+			    <RunCode code="application.closeWindow(application.iPanel)" waitTarget="systemManager.topLevelSystemManager.getChildAt(0)" waitEvent="effectEnd" />
+			</body>
+		</TestCase>
+        <TestCase testID="PopUpManager_addPopUp_nonmodal" description="Test the addPopUp method for a non-modal popup" keywords="[addPopUp, PopUpManager]">
+			<setup>
+			    <RunCode code="cleanUpPopUps()" />
+			    <WaitForEffectsToEnd />
+			    <ResetComponent target="ta" className="mx.controls.TextInput" waitTarget="ta" waitEvent="updateComplete"/>
+			    <RunCode code="application.addWindow(false)" />
+			    <WaitForEffectsToEnd />
+			</setup>
+			<body>
+			    <DispatchMouseClickEvent localX="330" localY="33" target="" waitEvent="mouseDownOutside" waitTarget="iPanel"/>
+			    <DispatchKeyEvent char="Hello" waitTarget="ta" waitEvent="change" />
+			    <AssertPropertyValue target="ta" propertyName="text" value="Hello" />
+			    <RunCode code="application.closeWindow(application.iPanel)" waitTarget="iPanel" waitEvent="remove" />
+			</body>
+		</TestCase>
+	</testCases>
+</UnitTester>

Added: incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Methods/PopUpManager_methods_spark.mxml
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Methods/PopUpManager_methods_spark.mxml?rev=1369970&view=auto
==============================================================================
--- incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Methods/PopUpManager_methods_spark.mxml (added)
+++ incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Methods/PopUpManager_methods_spark.mxml Mon Aug  6 20:17:09 2012
@@ -0,0 +1,75 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+
+-->
+<UnitTester testDir="Managers/PopUpManager/Methods/"  xmlns:mx="http://www.adobe.com/2006/mxml" xmlns="*" testSWF="PopUpManager_Basic_spark.mxml">
+
+    <mx:Script>
+	<![CDATA[
+
+       import mx.managers.PopUpManager;
+       public static function init(o:DisplayObject):void
+		{
+
+		}
+
+		public function cleanUpPopUps(): void
+		{
+		    if(application.parent.numChildren > 1)
+		    {
+		        var popups:int = application.parent.popUpChildren.numChildren;
+				if(popups > 0)
+				{
+					for (var i:int=0; i<popups; i++)
+					{
+						application.parent.removeChild(application.parent.popUpChildren.getChildAt(i));
+					}
+				}
+		    }
+		}
+
+	]]>
+	</mx:Script>
+
+	<mx:Metadata>
+	<![CDATA[
+		[Mixin]
+	]]>
+	</mx:Metadata>
+
+	<testCases>
+
+        <TestCase testID="PopUpManager_centerPopUp_nonmodal" description="Test the centerPopUp method for a non-modal popup" keywords="[centerPopUp, PopUpManager]">
+			<setup>
+			    <!--RunCode code="cleanUpPopUps()" /-->
+			    <WaitForEffectsToEnd />
+			    <Pause timeout="2000"/>
+			    <RunCode code="application.openWindow4(false)" waitTarget="canvasPopUp" waitEvent="updateComplete" />
+			    <AssertPropertyValue propertyName="y" target="canvasPopUp" value="3333" />
+			</setup>
+			<body>
+			    <SetProperty propertyName="x" target="canvasPopUp" value="0" waitTarget="canvasPopUp" waitEvent="move"/>
+			    <RunCode code="application.centerMyPopUp()" waitTarget="canvasPopUp" waitEvent="move" />
+			    <AssertPropertyValue propertyName="x" target="canvasPopUp" value="200" />
+			    <AssertPropertyValue propertyName="y" target="canvasPopUp" value="225" />
+			    <RunCode code="PopUpManager.removePopUp(application.canvasPopUp)"  />
+			</body>
+		</TestCase>
+ 
+	</testCases>
+</UnitTester>

Added: incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Properties/PopUpManager_BugTests.mxml
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Properties/PopUpManager_BugTests.mxml?rev=1369970&view=auto
==============================================================================
--- incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Properties/PopUpManager_BugTests.mxml (added)
+++ incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Properties/PopUpManager_BugTests.mxml Mon Aug  6 20:17:09 2012
@@ -0,0 +1,158 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+
+-->
+<UnitTester testDir="Managers/PopUpManager/Properties/"  xmlns:mx="http://www.adobe.com/2006/mxml" xmlns="*" testSWF="PopUpManager_Bugs.mxml">
+
+    <mx:Script>
+    <![CDATA[
+
+       import mx.managers.PopUpManager;
+       import mx.controls.Alert;
+       import mx.core.IFlexDisplayObject;
+       import mx.events.FlexEvent;
+
+
+       public static function init(o:DisplayObject):void
+        {
+
+        }
+
+        public function cleanUpPopUps(): void
+        {
+            var numPopUps:int = application.parent.numModalWindows;
+            var popUpChildren:int = application.parent.numChildren;
+            if(numPopUps != 0)
+            {
+               //remove the PopUps
+               var childIndex:int = 2;
+               for(var i:int = 0; i < numPopUps; i++)
+               {
+                   application.closeWindow(application.systemManager.topLevelSystemManager.getChildAt(childIndex));
+                   childIndex = childIndex +2;
+               }
+            }
+            else if (popUpChildren > 1)
+            {
+               
+               for(var j:int=1; j < popUpChildren; j++)
+               {
+                   application.closeWindow(application.systemManager.topLevelSystemManager.getChildAt(1));
+               }
+            }
+            else
+            {
+              var newEvent:FlexEvent = new FlexEvent(FlexEvent.UPDATE_COMPLETE, false, false);
+              application.systemManager.topLevelSystemManager.getChildAt(0).dispatchEvent(newEvent);
+            }
+        }
+
+    ]]>
+    </mx:Script>
+
+    <mx:Metadata>
+    <![CDATA[
+        [Mixin]
+    ]]>
+    </mx:Metadata>
+
+    <testCases>
+        <!--As far as I know, there is no reliable event to wait for when a non-modal popUp pops up. So, I am using
+        Pauses.-->
+        <TestCase testID="PopUpManager_bug164989" description="Bug #164989: reusing an instance of the same popUp fails" keywords="[Bugs, PopUpManager]">
+            <body>
+                <RunCode code="application.testPopupBug()" />
+                <WaitForEffectsToEnd />
+                <RunCode code="PopUpManager.removePopUp(application.t1)" />
+                <WaitForEffectsToEnd />
+                <RunCode code="PopUpManager.addPopUp(application.t1, application.pnl1, true);" />
+                <WaitForEffectsToEnd />
+                <RunCode code="application.closeWindow(application.t1)" />
+                <AssertEvent target="systemManager.topLevelSystemManager.getChildAt(0)" eventName="effectEnd" eventClass="mx.events::EffectEvent" timeout="700"/>
+            </body>
+        </TestCase>
+        <TestCase testID="PopUpManager_bug177669" description="Bug #177669: ncludeInLayout does not work correctly in PopUps." keywords="[Bugs, PopUpManager]">
+            <setup>
+                <WaitForEffectsToEnd />
+                <RunCode code="cleanUpPopUps()" waitTarget="systemManager.topLevelSystemManager.getChildAt(0)" waitEvent="updateComplete" />
+            </setup>
+            <body>
+                <RunCode code="application.openWindow2(true)" waitTarget="systemManager.topLevelSystemManager.getChildAt(0)" waitEvent="effectEnd" />
+                <Pause timeout="200" />
+                <AssertPropertyValue target="systemManager.topLevelSystemManager.getChildAt(2).box1" propertyName="height" value="0" />
+                <AssertPropertyValue target="systemManager.topLevelSystemManager.getChildAt(2).box1" propertyName="width" value="0" />
+                <DispatchMouseClickEvent target="systemManager.topLevelSystemManager.getChildAt(2).includeButton" localX="5" localY="5" />
+                <Pause timeout="100"/>
+                <SetProperty target="systemManager.topLevelSystemManager.getChildAt(2).box1" propertyName="visible" value="true" />
+                <SetProperty target="systemManager.topLevelSystemManager.getChildAt(2).box1" propertyName="height" value="23" />
+                <SetProperty target="systemManager.topLevelSystemManager.getChildAt(2).box1" propertyName="width" value="120" />
+               <Pause timeout="500"/>
+               <AssertPropertyValue target="systemManager.topLevelSystemManager.getChildAt(2).box1" propertyName="height" value="23" />
+                <AssertPropertyValue target="systemManager.topLevelSystemManager.getChildAt(2).box1" propertyName="width" value="120" />
+            </body>
+        </TestCase>
+        <TestCase testID="PopUpManager_bug99429" description="Bug #99429: modalTransparency doesn't work on modal popups." keywords="[modalTransparency, Bugs, PopUpManager]">
+            <setup>
+                <WaitForEffectsToEnd />
+                <RunCode code="cleanUpPopUps()" waitTarget="systemManager.topLevelSystemManager.getChildAt(0)" waitEvent="updateComplete" />
+            </setup>
+            <body>
+                <RunCode code="application.openWindow3(true)" waitTarget="systemManager.topLevelSystemManager.getChildAt(0)" waitEvent="updateComplete" />
+                <RunCode code="application.centerMyPopUp()" waitTarget="iPopUp" waitEvent="move" />
+                <DispatchMouseClickEvent localX="330" localY="33" target="" waitEvent="mouseDownOutside" waitTarget="iPopUp"/>
+                <DispatchKeyEvent char="Hello" />
+                <Pause timeout="200" />
+                <AssertPropertyValue target="ta" propertyName="text" value="" />
+                <AssertPixelValue target="" x="501" y="70" value="0xFFFFFF" />
+                <RunCode code="application.closeWindow(application.iPopUp)" />
+            </body>
+        </TestCase>
+        <TestCase testID="PopUpManager_bug104191" description="Bug #104191: Popped up title windows are not always gaining focus." keywords="[Focus, Bugs, PopUpManager]">
+            <setup>
+                <WaitForEffectsToEnd />
+                <RunCode code="cleanUpPopUps()" waitTarget="systemManager.topLevelSystemManager.getChildAt(0)" waitEvent="updateComplete" />
+            </setup>
+            <body>
+                <RunCode code="application.openWindow4()" waitTarget="systemManager.topLevelSystemManager.getChildAt(0)" waitEvent="updateComplete" />
+                <DispatchMouseClickEvent localX="3" localY="3" target="tw1.getChildAt(0)" />
+                <Pause timeout="800" />
+                <DispatchKeyEvent key="TAB" waitEvent="focusIn" waitTarget="tw2.getChildAt(0)"/>
+                <AssertMethodValue target="tw2" method="value=application.tw2.getFocus()" valueExpression="value=application.tw2.getChildAt(0)" />
+            </body>
+        </TestCase>
+        <TestCase testID="PopUpManager_bugSDK9428" description="Ensure that when clicked, popUps always jump to the front" keywords="[Bugs, PopUpManager, Panel]">
+            <setup>
+                <WaitForEffectsToEnd />
+                <RunCode code="cleanUpPopUps()" waitTarget="systemManager.topLevelSystemManager.getChildAt(0)" waitEvent="updateComplete" />
+               <RunCode code="application.popupPanel();" />
+               <Pause timeout="500" />
+            </setup>
+            <body>
+               <DispatchMouseClickEvent target="systemManager.topLevelSystemManager.getChildAt(1)" localX="170" localY="13" />
+               <WaitForEffectsToEnd />
+               <CompareBitmap target="systemManager.topLevelSystemManager.getChildAt(3)" url="../Properties/baselines/bug_SDK9428_1.png" timeout="2500" />
+               <DispatchMouseClickEvent target="systemManager.topLevelSystemManager.getChildAt(2)" localX="170" localY="13" />
+               <WaitForEffectsToEnd />
+               <CompareBitmap target="systemManager.topLevelSystemManager.getChildAt(3)" url="../Properties/baselines/bug_SDK9428_2.png" timeout="2500" />
+               <DispatchMouseClickEvent target="systemManager.topLevelSystemManager.getChildAt(1)" localX="170" localY="13" />
+               <WaitForEffectsToEnd />
+               <CompareBitmap target="systemManager.topLevelSystemManager.getChildAt(3)" url="../Properties/baselines/bug_SDK9428_3.png" timeout="2500" />
+            </body>
+        </TestCase>
+    </testCases>
+</UnitTester>

Added: incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Properties/PopUpManager_BugTests_spark.mxml
URL: http://svn.apache.org/viewvc/incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Properties/PopUpManager_BugTests_spark.mxml?rev=1369970&view=auto
==============================================================================
--- incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Properties/PopUpManager_BugTests_spark.mxml (added)
+++ incubator/flex/trunk/mustella/tests/Managers/PopUpManager/Properties/PopUpManager_BugTests_spark.mxml Mon Aug  6 20:17:09 2012
@@ -0,0 +1,186 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+
+-->
+<UnitTester testDir="Managers/PopUpManager/Properties/"  xmlns:mx="http://www.adobe.com/2006/mxml" xmlns="*" testSWF="PopUpManager_Bugs_spark.mxml">
+
+    <mx:Script>
+    <![CDATA[
+
+       import mx.managers.PopUpManager;
+       import mx.controls.Alert;
+       import mx.core.IFlexDisplayObject;
+       import mx.events.FlexEvent;
+
+
+       public static function init(o:DisplayObject):void
+        {
+
+        }
+
+        public function cleanUpPopUps(): void
+        {
+            var numPopUps:int = application.parent.numModalWindows;
+            var popUpChildren:int = application.parent.numChildren;
+            if(numPopUps != 0)
+            {
+               //remove the PopUps
+               var childIndex:int = 2;
+               for(var i:int = 0; i < numPopUps; i++)
+               {
+                   application.closeWindow(application.systemManager.topLevelSystemManager.getChildAt(childIndex));
+                   childIndex = childIndex +2;
+               }
+            }
+            else if (popUpChildren > 1)
+            {
+
+               for(var j:int=1; j < popUpChildren; j++)
+               {
+                   application.closeWindow(application.systemManager.topLevelSystemManager.getChildAt(1));
+               }
+            }
+            else
+            {
+              var newEvent:FlexEvent = new FlexEvent(FlexEvent.UPDATE_COMPLETE, false, false);
+              application.systemManager.topLevelSystemManager.getChildAt(0).dispatchEvent(newEvent);
+            }
+        }
+        
+
+
+    ]]>
+    </mx:Script>
+
+    <mx:Metadata>
+    <![CDATA[
+        [Mixin]
+    ]]>
+    </mx:Metadata>
+
+    <testCases>
+        <!--As far as I know, there is no reliable event to wait for when a non-modal popUp pops up. So, I am using
+        Pauses.-->
+        <TestCase testID="PopUpManager_bug164989" description="Bug #164989: reusing an instance of the same popUp fails" keywords="[Bugs, PopUpManager]">
+            <body>
+                <RunCode code="application.testPopupBug()" />
+                <WaitForEffectsToEnd />
+                <RunCode code="PopUpManager.removePopUp(application.t1)" />
+                <WaitForEffectsToEnd />
+                <RunCode code="PopUpManager.addPopUp(application.t1, application.pnl1, true);" />
+                <WaitForEffectsToEnd />
+                <RunCode code="application.closeWindow(application.t1)" />
+                <AssertEvent target="systemManager.topLevelSystemManager.getChildAt(0)" eventName="effectEnd" eventClass="mx.events::EffectEvent" timeout="700"/>
+            </body>
+        </TestCase>
+        <TestCase testID="PopUpManager_bug177669" description="Bug #177669: ncludeInLayout does not work correctly in PopUps." keywords="[Bugs, PopUpManager]">
+            <setup>
+                <WaitForEffectsToEnd />
+                <RunCode code="cleanUpPopUps()" waitTarget="systemManager.topLevelSystemManager.getChildAt(0)" waitEvent="updateComplete" />
+            </setup>
+            <body>
+                <RunCode code="application.openWindow2(true)" waitTarget="systemManager.topLevelSystemManager.getChildAt(0)" waitEvent="effectEnd" />
+                <Pause timeout="200" />
+                <AssertPropertyValue target="systemManager.topLevelSystemManager.getChildAt(2).box1" propertyName="height" value="0" />
+                <AssertPropertyValue target="systemManager.topLevelSystemManager.getChildAt(2).box1" propertyName="width" value="0" />
+                <DispatchMouseClickEvent target="systemManager.topLevelSystemManager.getChildAt(2).includeButton" localX="5" localY="5" waitEvent="updateComplete"
+                    waitTarget="systemManager.topLevelSystemManager.getChildAt(2).box1" />
+                <AssertPropertyValue target="systemManager.topLevelSystemManager.getChildAt(2).box1" propertyName="height" value="23" />
+                <AssertPropertyValue target="systemManager.topLevelSystemManager.getChildAt(2).box1" propertyName="width" value="120" />
+            </body>
+        </TestCase>
+        <TestCase testID="PopUpManager_bug99429" description="Bug #99429: modalTransparency doesn't work on modal popups." keywords="[modalTransparency, Bugs, PopUpManager]">
+            <setup>
+                <WaitForEffectsToEnd />
+                <RunCode code="cleanUpPopUps()" waitTarget="systemManager.topLevelSystemManager.getChildAt(0)" waitEvent="updateComplete" />
+            </setup>
+            <body>
+                <RunCode code="application.openWindow3(true)" waitTarget="systemManager" waitEvent="added" />
+                <RunCode code="application.centerMyPopUp()" waitTarget="iPopUp" waitEvent="move" />
+                <DispatchMouseClickEvent localX="330" localY="33" target="" waitEvent="mouseDownOutside" waitTarget="iPopUp"/>
+                <DispatchKeyEvent char="Hello" />
+                <Pause timeout="200" />
+                <AssertPropertyValue target="ta" propertyName="text" value="" />
+                <AssertPixelValue target="" x="501" y="70" value="0xFFFFFF" />
+                <RunCode code="application.closeWindow(application.iPopUp)" />
+            </body>
+        </TestCase>
+        <TestCase testID="PopUpManager_bug104191" description="Bug #104191: Popped up title windows are not always gaining focus." keywords="[Focus, Bugs, PopUpManager]">
+            <setup>
+                <WaitForEffectsToEnd />
+                <RunCode code="cleanUpPopUps()" waitTarget="" waitEvent="updateComplete" />
+            </setup>
+            <body>
+                <RunCode code="application.openWindow4()" waitTarget="systemManager" waitEvent="added" />
+                <Pause timeout="500" />
+                <DispatchMouseClickEvent localX="3" localY="3" target="tw1.getChildAt(0)" />
+                <Pause timeout="800" />
+                <DispatchKeyEvent key="TAB" waitEvent="focusIn" waitTarget="tw2.getChildAt(0)"/>
+                <AssertMethodValue target="tw2" method="value=application.tw2.getFocus()" valueExpression="value=application.tw2.getChildAt(0)" />
+            </body>
+        </TestCase>
+        <TestCase testID="PopUpManager_bugSDK9428_spark" description="Ensure that when clicked, popUps always jump to the front" keywords="[Bugs, PopUpManager, Panel]">
+            <setup>
+               <WaitForEffectsToEnd />
+               <RunCode code="cleanUpPopUps()" />
+               <RunCode code="application.popupPanel();" waitTarget="systemManager" waitEvent="added" />
+            </setup>
+            <body>
+               <DispatchMouseClickEvent target="systemManager.topLevelSystemManager.getChildAt(1)" localX="170" localY="13" 
+                  waitEvent="mouseDownOutside" waitTarget="systemManager.topLevelSystemManager.getChildAt(3)"/>
+               <WaitForEffectsToEnd />
+               <DispatchMouseClickEvent target="systemManager.topLevelSystemManager.getChildAt(2)" localX="170" localY="13" 
+                    waitEvent="mouseDownOutside" waitTarget="systemManager.topLevelSystemManager.getChildAt(3)"/>
+               <WaitForEffectsToEnd />
+               <DispatchMouseClickEvent target="systemManager.topLevelSystemManager.getChildAt(1)" localX="170" localY="13" 
+                    waitEvent="mouseDownOutside" waitTarget="systemManager.topLevelSystemManager.getChildAt(3)"/>
+               <WaitForEffectsToEnd />
+               <CompareBitmap numColorVariances="25" ignoreMaxColorVariance="true" target="" url="../Properties/baselines/$testID.png" timeout="2500" />
+            </body>
+        </TestCase>
+        <TestCase testID="PopUpManager_addPopUp_sparkPanel" description="Check that a Spark Panel is in focus when its first popped up" 
+            keywords="[Bugs, PopUpManager, Panel]">
+            <setup>
+               <WaitForEffectsToEnd />
+               <RunCode code="cleanUpPopUps()" />
+               <DispatchMouseClickEvent target="button1" localX="10" localY="10" waitTarget="systemManager" waitEvent="added" />
+               <WaitForEffectsToEnd />
+            </setup>
+            <body>
+               <DispatchKeyEvent keys="[TAB]" />
+               <AssertEvent target="sparkPanel.getElementAt(0)" eventName="focusIn" eventClass="flash.events::FocusEvent" />
+            </body>
+        </TestCase>
+        <TestCase testID="PopUpManager_addPopUp_sparkPanel_ModalFocus" description="Check that a Spark Panel is in focus when its first popped up" 
+            keywords="[Bugs, PopUpManager, Panel]">
+            <setup>
+               <WaitForEffectsToEnd />
+               <RunCode code="cleanUpPopUps()" waitEvent="updateComplete" waitTarget=""/>
+               <DispatchMouseClickEvent target="button1" localX="10" localY="10" waitTarget="systemManager" waitEvent="added" />
+               <WaitForEffectsToEnd />
+            </setup>
+            <body>
+               <DispatchKeyEvent keys="[TAB]" waitTarget="sparkPanel.getElementAt(0)" waitEvent="focusIn"/>
+               <DispatchKeyEvent keys="[TAB]" waitTarget="sparkPanel.getElementAt(1)" waitEvent="focusIn"/>
+               <DispatchKeyEvent keys="[TAB]" waitTarget="sparkPanel.getElementAt(2)" waitEvent="focusIn"/>
+               <DispatchKeyEvent keys="[TAB]" />
+               <AssertEvent target="sparkPanel.getElementAt(0)" eventName="focusIn" eventClass="flash.events::FocusEvent" />
+            </body>
+        </TestCase>
+    </testCases>
+</UnitTester>



Mime
View raw message