How to dynamically stop the execution of the scripts upon verification point failure in Rational Functional Tester

Technote (FAQ)


Question

How do you dynamically stop the execution of scripts upon verification point failure in IBM Rational Functional Tester (RFT)?

Cause

The execution result would be incomplete if the script execution is made to progress further even upon the verification failure taking place.

Answer

Procedure:

Disclaimer

All source code and/or binaries attached to this document are referred to here as "the Program". IBM is not providing program services of any kind for the Program. IBM is providing the Program on an "AS IS" basis without warranty of any kind. IBM WILL NOT BE LIABLE FOR ANY ACTUAL, DIRECT, SPECIAL, INCIDENTAL, OR INDIRECT DAMAGES OR FOR ANY ECONOMIC CONSEQUENTIAL DAMAGES (INCLUDING LOST PROFITS OR SAVINGS), EVEN IF IBM, OR ITS RESELLER, HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.

  1. Insert the below code within the verification point.

    boolean b= texttext3().performTest(Text_TextVP());
           if(b==false)
               {  System.out.println("VP Fails");
                   stop();
                 }



    Execution of the verification point results in a Boolean value (True/False).

  2. Invoke the method named stop() , to stop the script execution

    Example: A snippet of such code is described below.

    public void testMain(Object[] args)
       {

           texttext3().click(atPoint(56,14));
           mozillaFirefoxIBMEditionwindow().inputChars("Test");
           boolean b= texttext3().performTest(Text_TextVP());
           if(b==false)
           {
               System.out.println("VP Fails");
               stop();
           }
           else
           {
               System.out.println("VP Pass");
           }

       }

Rate this page:

(0 users)Average rating

Add comments

Document information


More support for:

Rational Functional Tester
Eclipse

Software version:

8.2, 8.2.0.1, 8.2.0.2, 8.2.1, 8.2.1.1, 8.2.2, 8.2.2.1, 8.3, 8.3.0.1

Operating system(s):

Windows

Reference #:

1626298

Modified date:

2013-03-29

Translate my page

Machine Translation

Content navigation