< Previous | Next >

Lesson 1: Create a project and record a test script

In this lesson, you will use the Classics CD sample application to create a new project and start recording a test to verify that the sample application correctly totals the amount of music CDs purchased.

A project is a collection of test assets such as test scripts, object maps, verification points, and datapools, that can facilitate the testing of one or more software components. You must create a functional test project before you can record a test.


Disable simplified scripting and application visuals feature

Rational Functional Tester provides you the option to generate simplified test scripts and Java test scripts. If you are familiar with Java scripting, you can disable the simplified scripting and application visuals feature and start recording the test script. In this tutorial, we will work with Java test scripts. Before you start recording the scripts, disable the simplified scripting and application visual features.

  1. To verify whether the feature is enabled, click Window > Preferences.

  2. In the left pane of the Preferences window, expand Functional Test, then Simplified scripting.

  3. In the Simplified Scripting page, clear the Enable Simplified Scripting checkbox.

  4. In the Application Visuals page, clear all the options listed in the page for the application visuals.

  5. Click Apply and then OK.


Create a project

Create a project to store the test assets that you need to test the Classics CD sample application.

  1. Click Windows > Open Perspective > Other to open the functional test perspective . In the Open Perspective dialog box, select the Functional Test option.

  2. Click File > New > Functional Test Project.

  3. Type DataDriveTutorial for the name of the new project.

  4. Click Finish.


Start recording

Start recording a test script to verify that when a customer orders a music CD, the total amount charged to the credit card is the correct amount listed in the application.

  1. On the Functional Test toolbar, click Record a Functional Test Script().

  2. Type OrderTotal for the name of the test script.

  3. Click Next.

    When you create a test script, Functional Tester creates a test datapool and other test assets. Use the defaults for Private Test Datapool and Sequential. A private test datapool is associated with only one script and is not available to any other scripts. When you use the sequential order, the test script accesses datapool records in the order that they appear in the datapool.

  4. Click Finish. The Functional Tester window minimizes and the Recording Monitor opens.


Start the ClassicsCD application

Start the ClassicsCD application and navigate through the application to the dialog box that you will data-drive.

  1. On the Recording toolbar, click Start Application().

  2. If necessary, click the Application Name arrow to see the options, and then select ClassicsJavaA - java.

  3. Click OK. ClassicsJavaA is build 1 of the sample application, ClassicsCD, which comes with Functional Tester.

  4. In the ClassicsCD application, under Composers, double-click Schubert to open the list of CDs for sale by that composer, and then click String Quartets Nos. 4 & 14.

  5. Click Place Order.

  6. Click OK to close the Member Logon window.

  7. In the Place an Order window, type 1234567890 in the Card Number field and then type 09/09 in the Expiration Date field.

< Previous | Next >

+

Search Tips   |   Advanced Search