Open Flex applications using the Runtime Loader

This task describes how to open Flex applications for UFT testing in Internet Explorer, using the UFT Flex Runtime Loader.

The UFT Flex Runtime Loader enables you to test Flex applications (.swf files) directly without having to prepare the application manually for testing.

This method is supported only when testing .swf files directly.

Note:  

  • If you are testing an .swf application that must remain embedded in an HTML file, or other types of Flex applications, you can choose an alternative method of enabling UFT to communicate with your Flex application.  For details, see Enabling UFT to identify objects in your Flex application.

  • Do not use the Runtime Loader to load applications that you already compiled with the UFT Flex pre-compiled agent.

Prerequisites

The UFT Flex Runtime Loader files are installed with UFT, in the <UFT installation folder>\dat\Flash\Flex\Runtime Loader folder.

  • Use one of the following Flex Runtime Loaders:

    • UFTFlexAUTLoader_4_9_1.swf - for testing Flex applications developed using the Flex SDK 4.9.1 or earlier
    • UFTFlexAUTLoader_4_12_1.swf - for testing Flex applications developed using the Flex SDK 4.12.x
  • Make sure that the UFT Flex Runtime Loader is located in the same application and security domain as the Flex application you are testing.

    If the application you are testing resides on a Web server, you must place a copy of the Runtime Loader on the same Web server and use that copy to open the application.

    Note:  

    If you use tests that were recorded on pre-compiled Flex applications to test Flex applications opened with the Runtime Loader (or vice versa), you may need to modify the object repositories associated with the test and any test scripts that use programmatic descriptions to identify Flex test objects.

    The uid property value in all Flex test objects and the id property value in FlexWindow test objects will differ between applications opened with the Runtime Loader and pre-compiled Flex applications. Before running your test, make sure that test objects whose descriptions includes these properties match the objects found in the application you are testing.

    If the application is on the file system, use the Runtime Loader stored in the file system.

  • If you use a copy of the Runtime Loader, and not one of the ones stored in the <UFT installation folder>\dat\Flash\Flex\Runtime Loader folder, make sure to recopy the file after any UFT upgrade to ensure that you use the most recent file version provided with UFT.

Back to top

Open the Flex Web application using the Runtime Loader

Open the application in a 32-bit Internet Explorer, using the following syntax in the URL box:

<UFTFlexAUTLoaderPath.swf>?swf_url=<ApplicationName.swf>&<param_name1>=<param_value1>&<param_name2>=<param_value2>
UFTFlexAUTLoaderPath

The URL or file system path to the UFT Flex Runtime Loader file.

If using file system paths, prefix the path with file://.
For example: 
file://C:\...\UFTFlexAUTLoader.swf?swf_url=C:\...\ApplicationName.swf

Make sure to use the Runtime Loader file suitable for your application:

  • UFTFlexAUTLoader_4_9_1.swf - for testing Flex applications developed using the Flex SDK 4.9.1 or earlier

  • UFTFlexAUTLoader_4_12_1.swf - for testing Flex applications developed using the Flex SDK 4.12.x

ApplicationName

The file name of the Flex application that you want to open.

If the application is stored in a different folder than the Runtime Loader, include the URL or file system path to the application.

A file system path can be a full path or the path relative to the location of the Runtime Loader.

param_names=param_values (Optional) A list of parameters and their values to pass to the application being opened. Parameters are separated by the ampersand (&) character.

Back to top