blob: 8779246f57bc1b6b058166631d557a498a8357b4 [file] [log] [blame]
<?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
xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
xmlns="*"
testDir="mobile/StageText/integration/"
testSWF="StageText.mxml" xmlns:mx="library://ns.adobe.com/flex/mx">
<fx:Script><![CDATA[ public static function init(o:DisplayObject):void { } ]]></fx:Script>
<fx:Metadata><![CDATA[ [Mixin] ]]></fx:Metadata>
<fx:Script>
<![CDATA[
import views.*;
import mx.core.FlexGlobals;
import mx.core.mx_internal;
use namespace mx_internal;
]]>
</fx:Script>
<testCases>
<TestCase testID="TextArea_Callout_nominal" keywords="[StageText, TextArea, Callout]" description="Verify a Callout can correctly display a TextArea">
<setup>
<RunCode code="application.stage.focus=null" />
<ResetComponent target="navigator" className="comps.QANavigator" waitEvent="viewChangeComplete" />
<RunCode code="application.navigator.pushView(views.CalloutIntegrationView)" waitTarget="navigator" waitEvent="viewChangeComplete" timeout="6000" />
</setup>
<body>
<RunCode code="application.navigator.activeView.currentState = 'TextArea'" waitEvent="updateComplete" waitTarget="navigator.activeView"/>
<RunCode code="application.navigator.activeView.taCalloutButton.openDropDown()" waitEvent="open" waitTarget="navigator.activeView.taCalloutButton"/>
<Pause timeout="100"/><!-- This is here because we can't get the event from the actual stageText using mustella, and they come at different times on different platforms -->
<AssertPropertyValue target="navigator.activeView.cTextArea" propertyName="text" valueExpression="value=application.navigator.activeView.def;"/>
<CompareBitmap target="navigator.activeView.cTextArea" stageText="true" url="../integration/baselines/TextArea/">
<ConditionalValue deviceDensity="160" os="qnx"/>
<ConditionalValue deviceDensity="240" os="android"/>
<ConditionalValue deviceDensity="320" os="iphone"/>
</CompareBitmap>
</body>
</TestCase>
<TestCase testID="TextArea_Callout_long_text" keywords="[StageText, TextArea, Callout]" description="Verify a Callout can correctly display a TextArea with a longer run of text.">
<setup>
<RunCode code="application.stage.focus=null" />
<ResetComponent target="navigator" className="comps.QANavigator" waitEvent="viewChangeComplete" />
<RunCode code="application.navigator.pushView(views.CalloutIntegrationView)" waitTarget="navigator" waitEvent="viewChangeComplete" timeout="6000" />
</setup>
<body>
<RunCode code="application.navigator.activeView.currentState = 'TextArea'" waitEvent="updateComplete" waitTarget="navigator.activeView"/>
<RunCode code="application.navigator.activeView.taCalloutButton.openDropDown()" waitEvent="open" waitTarget="navigator.activeView.taCalloutButton"/>
<Pause timeout="100"/><!-- This is here because we can't get the event from the actual stageText using mustella, and they come at different times on different platforms -->
<SetProperty target="navigator.activeView.cTextArea" propertyName="text" valueExpression="value=application.navigator.activeView.fib" waitEvent="updateComplete"/>
<AssertPropertyValue target="navigator.activeView.cTextArea" propertyName="text" valueExpression="value=application.navigator.activeView.fib;"/>
<CompareBitmap target="navigator.activeView.cTextArea" stageText="true" url="../integration/baselines/TextArea/">
<ConditionalValue deviceDensity="160" os="qnx"/>
<ConditionalValue deviceDensity="240" os="android"/>
<ConditionalValue deviceDensity="320" os="iphone"/>
</CompareBitmap>
</body>
</TestCase>
<TestCase testID="TextArea_Callout_tall_text" keywords="[StageText, TextArea, Callout]" description="Verify a Callout can correctly display a TextArea with a tall run of text.">
<setup>
<RunCode code="application.stage.focus=null" />
<ResetComponent target="navigator" className="comps.QANavigator" waitEvent="viewChangeComplete" />
<RunCode code="application.navigator.pushView(views.CalloutIntegrationView)" waitTarget="navigator" waitEvent="viewChangeComplete" timeout="6000" />
</setup>
<body>
<RunCode code="application.navigator.activeView.currentState = 'TextArea'" waitEvent="updateComplete" waitTarget="navigator.activeView"/>
<RunCode code="application.navigator.activeView.taCalloutButton.openDropDown()" waitEvent="open" waitTarget="navigator.activeView.taCalloutButton"/>
<Pause timeout="100"/><!-- This is here because we can't get the event from the actual stageText using mustella, and they come at different times on different platforms -->
<SetProperty target="navigator.activeView.cTextArea" propertyName="text" valueExpression="value=application.navigator.activeView.rom" waitEvent="updateComplete"/>
<AssertPropertyValue target="navigator.activeView.cTextArea" propertyName="text" valueExpression="value=application.navigator.activeView.rom;"/>
<CompareBitmap target="navigator.activeView.cTextArea" stageText="true" url="../integration/baselines/TextArea/">
<ConditionalValue deviceDensity="160" os="qnx"/>
<ConditionalValue deviceDensity="240" os="android"/>
<ConditionalValue deviceDensity="320" os="iphone"/>
</CompareBitmap>
</body>
</TestCase>
<TestCase testID="TextArea_Callout_TextArea_Under_Callout" keywords="[StageText, TextArea, Callout]" description="Verify that a TextArea under a TextArea callout is a Bitmap.">
<setup>
<RunCode code="application.stage.focus=null" />
<ResetComponent target="navigator" className="comps.QANavigator" waitEvent="viewChangeComplete" />
<RunCode code="application.navigator.pushView(views.CalloutIntegrationView)" waitTarget="navigator" waitEvent="viewChangeComplete" timeout="6000" />
</setup>
<body>
<RunCode code="application.navigator.activeView.currentState = 'TextArea'" waitEvent="updateComplete" waitTarget="navigator.activeView"/>
<SetProperty target="navigator.activeView.taTextArea" propertyName="text" valueExpression="value=application.navigator.activeView.fib" waitEvent="updateComplete"/>
<AssertPropertyValue target="navigator.activeView.taTextArea" propertyName="text" valueExpression="value=application.navigator.activeView.fib;"/>
<RunCode code="application.navigator.activeView.taCalloutButton.openDropDown()" waitEvent="open" waitTarget="navigator.activeView.taCalloutButton"/>
<Pause timeout="100"/><!-- This is here because we can't get the event from the actual stageText using mustella, and they come at different times on different platforms -->
<AssertPropertyValue target="navigator.activeView.cTextArea" propertyName="text" valueExpression="value=application.navigator.activeView.def;"/>
<CompareBitmap target="navigator.activeView.taTextArea" stageText="false" url="../integration/baselines/TextArea/">
<ConditionalValue deviceDensity="160" os="qnx"/>
<ConditionalValue deviceDensity="240" os="android"/>
<ConditionalValue deviceDensity="320" os="iphone"/>
</CompareBitmap>
</body>
</TestCase>
<TestCase testID="TextArea_Callout_TextInput_Under_Callout" keywords="[StageText, TextArea, TextInput, Callout]" description="Verify that a TextInput under a TextArea callout is a Bitmap.">
<setup>
<RunCode code="application.stage.focus=null" />
<ResetComponent target="navigator" className="comps.QANavigator" waitEvent="viewChangeComplete" />
<RunCode code="application.navigator.pushView(views.CalloutIntegrationView)" waitTarget="navigator" waitEvent="viewChangeComplete" timeout="6000" />
</setup>
<body>
<RunCode code="application.navigator.activeView.currentState = 'TextArea'" waitEvent="updateComplete" waitTarget="navigator.activeView"/>
<SetProperty target="navigator.activeView.taTextInput" propertyName="text" valueExpression="value=application.navigator.activeView.fib" waitEvent="updateComplete"/>
<AssertPropertyValue target="navigator.activeView.taTextInput" propertyName="text" valueExpression="value=application.navigator.activeView.fib;"/>
<RunCode code="application.navigator.activeView.taCalloutButton.openDropDown()" waitEvent="open" waitTarget="navigator.activeView.taCalloutButton"/>
<Pause timeout="100"/><!-- This is here because we can't get the event from the actual stageText using mustella, and they come at different times on different platforms -->
<AssertPropertyValue target="navigator.activeView.cTextArea" propertyName="text" valueExpression="value=application.navigator.activeView.def;"/>
<CompareBitmap target="navigator.activeView.taTextInput" stageText="false" url="../integration/baselines/TextArea/">
<ConditionalValue deviceDensity="160" os="qnx"/>
<ConditionalValue deviceDensity="240" os="android"/>
<ConditionalValue deviceDensity="320" os="iphone"/>
</CompareBitmap>
</body>
</TestCase>
</testCases>
</UnitTester>