Get Scripting Access – the Flash Injector way

0
80
Flash Player Debugger Version
Flash Player Debugger Version

Flash Injector – Configuration for testing flex based applications using TestComplete

TestComplete needs scripting access of application internals, to test Flex applications. There are four ways to get access to Flash and Flex applications, which make them testable using TestComplete. Click on the links below to know more about each ways from smartbear website.

In this post we will discuss about the Flash Player Debug version approach, which is the easiest and quickest one among all these. In this approach we use the debug version of Flash Player with the FlashInjector.swf helper module shipped along with TestComplete. It is also known as the Flash Injector way.

This is quite simple and is a three step procedure.

Step 1: Installation of Debugger version of the Flash Player

  1. go to Adobe – Find Version – Flash Player page.
  2. find section “5. Troubleshoot Flash Player” – under “Find Flash Player version type and capabilities (Flash developers only)” verify you have debugger version installed (Debug Player = Yes).

    Flash Player Debugger Version
    Flash Player Debugger Version
  3. If Debug Player is No then it means you don’t have debug player installed.  Install Debug player. Find the latest Flash Player version available for your operating system  at section 3 and click on the appropriate link to install under section 4 Install Flash Player. Debugger versions are available to download here.

Step 2: Modify or create the mm.cfg

If the file mm.cfg is not created in the user profile folder, then create one adding the preloadswf parameter and initialize it with the fully-qualified path to the FlashInjector.swf module. By Default, this module is installed in the <TestComplete Installation Dir>\Open Apps\Flex foler.

– On Windows Vista, Windows 7, Windows Server 2008 and later operating systems, the typical path to this file is<System_Drive>\<Users>\<User_name>\mm.cfg.

– On Windows XP and Windows Server, the typical path is <System_Drive>\<Documents and Settings>\<User_name>\.

Add the preload parameter

On a 32-bit version of Windows:

PreloadSwf=C:\Program Files\Smartbear\TestComplete 9\Open Apps\Flex\FlashInjector.swf

On a 64-bit version of Windows:

PreloadSwf=C:\Program Files (x86)\Smartbear\TestComplete 9\Open Apps\Flex\FlashInjector.swf

Step 3: Add the FlashInjector.swf path to the list of trusted locations in Flash Player’s settings

Navigate to Global Flash Player Security Settings page,

Select Edit Location > Add Location from the drop down List for “Always trust files in these locations”

Global Security Settings Panel
Global Security Settings Panel

Enter the fully qualified name of the  <TestComplete>\Open Apps\Flex directory and click Confirm.

Global Security Settings Panel
Global Security Settings Panel

LEAVE A REPLY

Please enter your comment!
Please enter your name here

This site uses Akismet to reduce spam. Learn how your comment data is processed.