Automating Flex application testing

Long gone are the times when software testing was greatly undervalued. It is now believed that good tests are essential for the success of the entire project.
By: Verax Systems
 
May 5, 2010 - PRLog -- Introduction
Long gone are the times when software testing was greatly undervalued. It is now believed that good tests are essential for the success of the entire project. However, the testing phase still tends to be the one that is shortened when a project comes across any obstacles and there is pressure to deliver on time. The impression that the product is almost finished helps to turn a blind eye on the fact that the tests were conducted with a lower quality than they in fact should.
Quality tests are usually time-consuming so a tendency exists to attempt to automate as much of these tests as possible. This task is relatively easy when it comes to unit testing, but the situation gets more complicated when functional testing is involved. One of the best examples that is hard to automate are functional tests of graphical user interface.
Over the time until now quite a number of techniques and tools for automatic GUI testing were created. Software manufacturers discovered that it pays off to invest in preparing and maintaining automatic test cases for their GUI applications instead of re-running everything manually before each release. Automation of user interface tests - in a long run - saves a lot of effort.
Functional testing of Flex application
There exist many tools for automation of user interface tests, especially when it comes to GUIs running in a web browser. It is relatively easy to simulate behavior of a browser and replicate real scenarios into functional test cases. However, this task gets more challenging when it comes to the increasingly popular RIA technology of Adobe - Flex. Despite the fact that Flex applications run in browser, the Flash container used to run the application what renders HTML-based automatic testing tools useless.
An answer to the lack of Flex GUI testing tools is FunFx. It is an open-source framework and uses Ruby to generate functional tests for Flex applications and "run them through the browser". Ruby is a simple yet powerful language and was chosen because it allows writing easy-to-understand tests.
Creating test cases with FunFx requires writing a Ruby script that interacts with the Flex GUI. Example instructions would be: click a button, check a message, etc. The results of the tests are checked against assertion values that interrupt conduction of the scenarios when an error is encountered. Because FunFx is run from the command line, it is easy to bind the tests together with build management software like Maven, so that the tests can be run even automatically in development environments or on continuous integration servers.
Challenges
FunFx is a powerful tool, but unfortunately it has its limitations. Several things need to be remembered when working with the platform:
1.   All the widgets must have unique IDs. Developers have to remember to apply them for every element.
2.   Flex SDK in version 3 should be used. It is possible to use older versions but custom compilation is required.
3.   When creating tests, the application source code is required - widget IDs have to be known to identify those to be used in the tests.
4.   Ruby must be installed.
Summary
FunFx is quite a powerful library that allows reducing the time needed for repetitive test runs. The tool is under constant development and is definitely worth trying to improve the testing process.

# # #

Verax Systems is a software house and a consultancy & solution provider specialising in advanced and innovative IT solutions for the telecommunications, banking and enterprise markets.
End
Source:Verax Systems
Email:***@veraxsystems.com Email Verified
Zip:61-369
Industry:Computers
Location:Poland
Account Email Address Verified     Disclaimer     Report Abuse
Verax Systems Corp. PRs
Trending News
Most Viewed
Top Daily News



Like PRLog?
9K2K1K
Click to Share