Packagesrc.test
Classpublic class FunFXMock
InheritanceFunFXMock Inheritance FunFX Inheritance flash.display.Sprite

A mock class of the FunFX class, used for unit testing



Protected Properties
 PropertyDefined by
  applicationRoot : Object
[read-only] This method is an override from the FunFX
FunFXMock
 InheritedautomationManager : IAutomationManager
A getter method to the Automation.automationManager It eases testing
FunFX
  list : Object
FunFXMock
  rootObj : DisplayObject
FunFXMock
Public Methods
 MethodDefined by
  
FunFXMock(root:DisplayObject)
FunFXMock
 Inherited
applicationReady(str:String):Boolean
[static] Checks wether the application root is ready/initialized or not
FunFX
 Inherited
[static] Sets the adapter in recording mode
FunFX
 Inherited
catchEvent(eventType:String, eventClass:String, objectID:String, properties:Object = null):String
The method the testing framework (Ruby implemented Funfx) access to perform events.
FunFX
 Inherited
catchProperty(objectID:String, property:String):*
Checks the value of an objects property.
FunFX
 Inherited
checkComponent(parentID:String, name:String):*
Helps the Funfx framework to figure out if the object exist in the application.
FunFX
 Inherited
checkName(obj:UIComponent, name:String):Boolean
Takes a display object and a name, and checks different values on the object to see if it matches the name.
FunFX
 Inherited
endRecording():void
Makes the adapter leave the recording mode
FunFX
 Inherited
findObject(parentID:String, name:String):IAutomationObject
Uses the objectTree string, which is a comma separated string, to go through the display object hierarchy to find the wanted object.
FunFX
 Inherited
getChildren(objectID:String):String
Helper method for displaying the children of a component Is used to ease writing tests, finding the right children
FunFX
 Inherited
getColumnNames(objectID:String):String
Returns the column names of a component supporting tabular data e.g.
FunFX
 Inherited
getFirstVisibleRow(objectID:String):int
Returns the index of the first visible row in a component supporting tabular data e.g.
FunFX
 Inherited
getHierarchy(obj:IAutomationObject):String
[static] Prints the hierarchy of parent to the object in Ruby syntax.
FunFX
 Inherited
getLastVisibleRow(objectID:String):int
Returns the index of the last visible row in a component supporting tabular data e.g.
FunFX
 Inherited
getNumColumns(objectID:String):int
Returns the number of columns in a component supporting tabular data e.g.
FunFX
 Inherited
getNumRows(objectID:String):int
Returns the number of rows in a component supporting tabular data e.g.
FunFX
 Inherited
getTabularDataValue(objectID:String, arg:Object):String
FunFX
 Inherited
getTabularDataValues(objectID:String, start:int = 0, end:int = 0):String
Extracts and passes the values of an object that supports tabulardata (ex DataGrid, List etc) to the testing framework.
FunFX
 Inherited
init(root:DisplayObject):void
[static] Init method that initializes the adapter class when added as a library to a Flex application.
FunFX
 Inherited
isSynchronized(objectID:String):Boolean
Method that checks whether the Flex application is ready or busy doing some action.
FunFX
 Inherited
resolveObjFromID(objectID:String):UIComponent
Method that resolves the object from the cerated ID
FunFX
 Inherited
setProperties(replayEvent:*, object:UIComponent, properties:Object):String
Merges the properties added by the framework to the actual event
FunFX
 Inherited
setTestingEnvironment(te:String):void
Sets the testing environment, with a XML file that describes all the Flex components.
FunFX
Protected Methods
 MethodDefined by
  
createID(obj:IAutomationObject):String
Overridden method from FunFX
FunFXMock
  
performSearch(openList:Array, name:String):UIComponent
Overridden method from FunFX
FunFXMock
  
resolveID(objID:String):Array
Overridden method from FunFX
FunFXMock
  
startPlayback(obj:IAutomationObject, ev:Event):void
Method that overrides the same method in FunFX, this to be able to test FunFX methods
FunFXMock
 Inherited
startSearch(name:String):UIComponent
A helper method that is used to find the first display object from the System manager.
FunFX
Property detail
applicationRootproperty
applicationRoot:Object  [read-only]

This method is an override from the FunFX

Implementation
    protected function get applicationRoot():Object
listproperty 
protected var list:Object
rootObjproperty 
protected var rootObj:DisplayObject
Constructor detail
FunFXMock()constructor
public function FunFXMock(root:DisplayObject)Parameters
root:DisplayObject
Method detail
createID()method
protected override function createID(obj:IAutomationObject):String

Overridden method from FunFX

Parameters
obj:IAutomationObject — The object

Returns
String — The id created
performSearch()method 
protected override function performSearch(openList:Array, name:String):UIComponent

Overridden method from FunFX

Parameters
openList:Array — List of objects not yet investigated
 
name:String — The name of the object

Returns
UIComponent — The object found
resolveID()method 
protected override function resolveID(objID:String):Array

Overridden method from FunFX

Parameters
objID:String — The object id

Returns
Array — The object responding to the object id in array form
startPlayback()method 
protected override function startPlayback(obj:IAutomationObject, ev:Event):void

Method that overrides the same method in FunFX, this to be able to test FunFX methods

Parameters
obj:IAutomationObject — The object that the event will be replayed on
 
ev:Event — The event that shall be replayed