GithubHelp home page GithubHelp logo

flex-pilot's Introduction

Flex Pilot

A library for doing easy testing automation of Flash and Flex
applications. Includes a locator/lookup mechanism, eventing,
and an AS3 test-runner.


flex-pilot's People

Contributors

admc avatar ancanitu avatar jolsen avatar yanne avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

flex-pilot's Issues

Swiz specific issue

Swiz has a BaseMetadataProcessor (BMP) class which creates elements from metadata.
The app I'm working in leverages this construct - passing in a bunch of name/value pairs and letting the BMP construct and display ui elements. In this case the elements are similar to modal windows.
So far i have been unable to successfully click a child button w/i one of these dynamically constructed elements.

Is it possible that Flex Pilot is unaware of their 'automationName' prop/val because the elements do not exist upon the application's creationComplete?

My tests are written in ruby and leverage javascript.
I've tried accessing the infoButton by chain @driver.execute_script("document.App.fp_click({chain:'name:ImageEditingContextualMenu2147/name:ImageEditingContextualMenuSkin2148/id:contextualMenuWrapper/name:ContextualMenuSkin2150/id:contentGroup/id:contentGroup/automationName:infoButton'})")

and by automationName
@driver.execute_script("document.App.fp_click({automationName:'infoButton'})")

Any insight or workaround would be greatly appreciated.
Thanks

How do you leverage webdriver 'wait' ?

i'm trying to get rid of these pesky 'sleep(n)' and use wait instead, but can't get it to work.
any ideas?
require "rubygems"
require "selenium-webdriver"
require "test/unit"

class SmokeTest < Test::Unit::TestCase

def setup
@driver = Selenium::WebDriver.for :firefox
@wait = Selenium::WebDriver::Wait.new(:timeout => 30)
@verification_errors = []
end

def test1
@driver.get "http://myFlexApp.com/index.html"
# sleep(26)
element = @wait.until( assert_equal("Loaded",@driver.execute_script("document.FlexApp.fp_getPropertyValue({id:'titleLabel',attrName:'text'})"))
p('app elements loaded')
end

def test2
@driver.get "http://myFlexApp.com/index.html"
element = @wait.until( @driver.execute_script("document.FlexApp.fp_assertDisplayObject({automationName:'titleLabel'})") ) )
p('app elements loaded')
end

end

I'm beginning to suspect that wait only works with driver.find_element().

any help is appreciated!

type to Spark TextInput - missing event

Hi!
Flex-Pilot and Robot Framework with Selenium library is great combination, but I found bug from type functionality.
Spark TextInput (which extends SkinnableTextBase) dispatch TextOperationEvent.CHANGE after edit completed, but currently flex-pilot don't dispatch it.
Event is documented in SkinnableTextBase source:
/**

  • Dispatched after a user editing operation is complete.
  • @eventtype spark.events.TextOperationEvent.CHANGE
  • @langversion 3.0
  • @playerversion Flash 10
  • @playerversion AIR 1.5
  • @productversion Flex 4
    */
    [Event(name="change", type="spark.events.TextOperationEvent")]

chain to popup

I can't get any commands to work on any elements in a Pop-up. I've tried setting automationNames to various object in it and even to the Pop-Up itself, but it always fails to locate the element. Any idea what's causing this?

issue calling select function on spark.components.DropDownList

getting the following error when calling the function function select(params:Object) using a label=newvalue

TypeError: Error #1034: Type Coercion failed: cannot convert org.flex_pilot.events::FPListEvent@15476fc9 to spark.events.IndexChangeEvent.

this occurs when the code is on this line
if (sel[labelField] != targetLabel) {
Events.triggerListEvent(obj, ListEvent.CHANGE);

on the function select(params:Object) (FPController.as)

complete stack

TypeError: Error #1034: Type Coercion failed: cannot convert org.flex_pilot.events::FPListEvent@15476fc9 to spark.events.IndexChangeEvent.
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at mx.core::UIComponent/dispatchEvent()
at org.flex_pilot.events::Events$/triggerListEvent()[E:\Source\xx\Flex\xx\src\org\flex_pilot\events\Events.as:182]
at org.flex_pilot::FPController$/select()[E:\Source\xx\Flex\xx\src\org\flex_pilot\FPController.as:496]
at Function/http://adobe.com/AS3/2006/builtin::apply()
at Function/()[E:\Source\xx\Flex\xx\src\org\flex_pilot\FlexPilot.as:138]
at Function/http://adobe.com/AS3/2006/builtin::apply()
at flash.external::ExternalInterface$/_callIn()
at Function/()

any idea on how to select an item using this element?

Selenium IDE w/ Flexpilot iframes issue

Apparently the flex pilot IDE extension doesn't function within iframes.
If I extract the movie outside the iframe, by opening it within a separate
browser, the IDE picks up components...

need to click on a tabNavigator which has some views..

How Can I click on TabNavigator??

<mx:TabNavigator id="mainSs" width="100%" height="100%" paddingTop="0" historyManagementEnabled="false" tabHeight="26">

<view:EditView label="Search/Edit Record" id="edit"                     user="{model_Me.user_name}"/>

<view:UploadView label="Upload File" id="upload"                        enabled="{model.user.userInRoleForApp( 'RAP', 'UPLOAD' )}" user="{model_Me.user_name}"
uploadErrors="{model_Me.uploadErrors_found}"/>  

/mx:TabNavigator

I am trying the following, But, not working.

((JavascriptExecutor) webDriver).executeScript("document.getElementById('"+flashObjectId+"').fp_click({
id:'mainSs', label:'Upload File'})");

OR

((JavascriptExecutor) webDriver).executeScript("document.getElementById('"+flashObjectId+"').fp_click({
id:'mainSs', id:'upload'})");

So, Can u help Please??

need to read/get a textfield value?

Hello

How Can I read/get a textfield?

for example, in Flex_Selenium_API, we can get the textfield:

public String getText(String textFieldId) {
return call("getFlexText", textFieldId, "");
}

How can we do it with flexPilot???

I looked at the API, and it has fp_click , fp_type , fp_select ,fp_doubleClick, fp_dragDropElemToElem, fp_dragDropToCoords,
fp_lookupFlash .

there is No fp_get OR fp_read.

Can u help please?

thanks

Fly Out Elements

Hi,

I am doing Flex Automation Project.

I am using Flex Pilot with Robot Framework and Selenium, At some extend I am successful on Flex Automation but I got stuck at Fly Out Elements, I am not able to click on on the fly element. I would really appreciate if somebody helps me to resolve this issue.

Thanks and Regards,
Abhijit Valvekar

fp_getPropertyValue not working from ruby

so i'm able to execute this javascript from the firebug console against my app, w/ flexpilot in place, and receive the expected response of "Howdy"

document.getElementById('FlexPilotSample').fp_getPropertyValue({id:'howdyButton',attrName:'label'})

but when i pull this into my ruby test the same javascript statement returns and my assertion fails

assert_equal(@driver.execute_script("document.getElementById('FlexPilotSample').fp_getPropertyValue({id:'howdyButton',attrName:'label'})"), "Howdy")

other scripts from ruby work as expected
@driver.execute_script("document.getElementById('FlexPilotSample').fp_click({id:'howdyButton'})")
@driver.execute_script("document.getElementById('FlexPilotSample').fp_check({id:'howdyButton'})")

any ideas?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.