Introduction To QTP: STC Technologies PVT LTD

Download as ppt, pdf, or txt
Download as ppt, pdf, or txt
You are on page 1of 31

Introduction to QTP

STC Technologies Pvt Ltd


Introduction to QuickTest

• Welcome to QuickTest Professional, the Mercury


advanced keyword-driven testing solution.

• QuickTest Professional enables you to test


• standard Windows applications
• Web objects
• ActiveX controls
• Visual Basic applications.

STC Technologies Pvt Ltd


Testing Process
• The QuickTest testing process consists of 7 main phases:

Preparing to Record

Recording a Session

Enhancing Your Test

Debugging Your Test

Running Your Test

Analyzing the Test Results

Reporting defects
STC Technologies Pvt Ltd
Creating Tests

STC Technologies Pvt Ltd


Recording a Test
You create a test by recording the
typical processes that users perform.

QuickTest records the operations you


perform, displays them as steps in the
Keyword View, and generates them in
a script.

STC Technologies Pvt Ltd


Choosing the Recording Mode
• Three kinds of Recording Modes are
available in Quick Test. They are,

» Normal Recording Mode


» Analog Recording Mode
» Low-Level Recording Mode

STC Technologies Pvt Ltd


Normal Recording Mode

• It records the objects in your application


and the operations performed on them.

• This mode is the default Mode .

• and takes full advantage of QuickTest's test


object model, recognizing the objects in
your application regardless of their location
on the screen.

STC Technologies Pvt Ltd


Analog Recording Mode

• enables you to record the exact mouse and


keyboard operations you perform in relation to
either the screen or the application window.

• In this recording mode, QuickTest records and


tracks every movement of the mouse as you
drag the mouse around a screen or window.

STC Technologies Pvt Ltd


Low-Level Recording
• Enables you to record on any object in your
application, whether or not QuickTest
recognizes the specific object or the specific
operation.
• Use low-level recording for recording in an
environment or on an object not recognized by
QuickTest.
• You can also use low-level recording if the
exact coordinates of the object are important for
your test or component.
STC Technologies Pvt Ltd
Working with Test Objects

STC Technologies Pvt Ltd


how QuickTest learns and identifies
objects
• QuickTest tests your dynamically changing
application by learning and identifying test
objects and their expected properties and
values.
• During recording QuickTest analyzes each
object in your application much the same
way that a person would look at a
photograph and remember its details.

STC Technologies Pvt Ltd


Understanding the Object Repository
Dialog Box

• The Object Repository dialog box displays


a tree of all objects in the current in the
current action or entire test.
• You can use the Object Repository dialog
box to view or modify the test object
description of any test object in the
repository or to add new objects to your
repository.

STC Technologies Pvt Ltd


Synchronizing Your Test

STC Technologies Pvt Ltd


What is Synchronizing?
• When you run a test , your application may
not always respond with the same speed.

• You can handle these anticipated timing


problems by synchronizing your test to
ensure that QuickTest waits until your
application is ready before performing a
certain step.

STC Technologies Pvt Ltd


When do we Synchronize?

• for a progress bar to reach 100%


• for a status message to appear
• for a button to become enabled
• for a window or pop-up message to open

STC Technologies Pvt Ltd


Checkpoints

STC Technologies Pvt Ltd


Understanding Checkpoints

• A checkpoint is a verification point that


compares a current value for a specified
property with the expected value for that
property.

• This enables you to identify whether your


Web site or application is functioning A checkpoint is a
correctly.

STC Technologies Pvt Ltd


Understanding Types of Checkpoints

• Standard Checkpoint checks the property value of an


object in your application or Web page.

• Image Checkpoint checks the value of an image in your


application or Web page.

• Bitmap Checkpoint checks an area of your Web page or


application as a bitmap.

• Table Checkpoint checks information within a table.

STC Technologies Pvt Ltd


• Text Checkpoint checks that a text string is displayed in the
appropriate place in your application or on a Web page.

• Text Area Checkpoint checks that a text string is displayed


within a defined area in a Windows application.

• Accessibility Checkpoint identifies areas of your Web site that


may not conform to the World Wide Web Consortium (W3C)
Web Content Accessibility Guidelines.

• Page Checkpoint checks the characteristics of a Web page.

• Database Checkpoint checks the contents of a database


accessed by your application.

STC Technologies Pvt Ltd


Working with Actions

STC Technologies Pvt Ltd


About Working with Actions

• A test is made up of calls to actions.


• When you create a new test, it contains a
call to a single action.
• By creating tests that call multiple actions,
you can design more modular and efficient
tests.

STC Technologies Pvt Ltd



Using Multiple Actions in a Test
You can divide your test into multiple actions by creating new
actions and inserting calls to them, or by inserting calls to
existing actions.
• There are three kinds of actions:
• non-reusable action — an action that can be called only in the
test with which it is stored, and can be called only once.
• reusable action — an action that can be called multiple times
by the test with which it is stored (the local test) as well as by
other tests.
• external action—a reusable action stored with another test.
External actions are read-only in the calling test, but you can
choose to use a local, editable copy of the Data Table
information for the external action.

By default, new actions are non-reusable.


STC Technologies Pvt Ltd
Parameterizing Values

STC Technologies Pvt Ltd


About Parameterizing Values
• QuickTest enables you to expand the scope of
a basic test by replacing fixed values with
parameters.

• This process, known as parameterization.

• Which greatly increases the power and


flexibility of your test or component.

STC Technologies Pvt Ltd


Data Table Parameters
• You can supply the list of possible values for a
parameter by creating a Data Table parameter.

• Data Table parameters enable you to create a


data-driven test,or action that runs several times
using the data you supply.

• In each repetition, or iteration, QuickTest uses


a different value from the Data Table.

STC Technologies Pvt Ltd


Using the Data Driver Wizard

• The Data Driver enables you to quickly


parameterize several (or all) property values
for test objects, checkpoints, and/or method
arguments containing the same constant value
within a given action.

STC Technologies Pvt Ltd


Test Batch

STC Technologies Pvt Ltd


About Test Batch
• You can use Test Batch Runner to run several
tests in succession.
• The results for each test are stored in their
default location.
• Using Test Batch Runner, you can set up a list
of tests and save the list as an .mtb file, so that
you can easily run the same batch of tests again,
at another time.
• You can also choose to include or exclude a test
in your batch list from running during a batch
run.
STC Technologies Pvt Ltd
Defining and Using Recovery
Scenarios

STC Technologies Pvt Ltd


About Recovery Scenarios
• Unexpected events, errors, and application
crashes during a run session can disrupt your
run session and distort results.

• The Recovery Scenario Manager provides a


wizard that guides you through the process of
defining a recovery scenario—a definition of
an unexpected event and the operation(s)
necessary to recover the run session.
STC Technologies Pvt Ltd
• A recovery scenario consists of the following:

• Trigger Event —> The event that interrupts your run session.
For example, a window that may pop up on screen.

• Recovery Operation(s) —> The operation(s) that need to be


performed in order to continue running the test. For example,
clicking an OK button in a pop-up window.

• Post-Recovery Test Run Option —> The instructions on how


QuickTest should proceed once the recovery operations have
been performed, and from which point in the test should
continue.

STC Technologies Pvt Ltd

You might also like