QTP VBScript new series + Interview Question Bank on QTP for enrichment of Knowledge in QTP

This Site has been brought to you by HP Certified Expert of QTP.

Exciting new articles for October:

1) QTP Tip:Deselect all Radio Buttons

2) HP QTP Crypt Object

3)Adding Hyperlinks in Excel Spreadsheet

Best of Luck Friends ! ! !

Expert QTP

All Articles are Copyright Protected. These are Free for Reading & Personal Use. Reproduction in Any Form without the Permission is Illegal & Strictly Prohibited.

Copyright © 2009 ExpertQTP

Google Search

Tuesday, September 30, 2008

QTP - Interview Question Bank : Part 7

Q. 61: How can we perform Merge Operations among various object repositories?======================================================
The Object Repository Merge Tool enables you to merge test objects from the local object repository of one or more actions to a shared object repository using the Update from Local Repository option in the Object Repository Manager.

For example, you may have learned test objects locally in a specific action in your test and want to add them to the shared object repository so they are available to all actions in different tests that use that object repository. You can also use the Object Repository Merge Tool to merge two shared object repositories into a single shared object repository.

You open the Object Repository Merge Tool by choosing Tools > Object Repository Merge Tool in the Object Repository Manager.

Q. 62: How can we perform Import & Export Operations among various object repositories?

You can import and export object repositories from and to XML files. XML provides a structured, accessible format that enables you to make changes to object repositories using the XML editor of your choice and then import them back into QTP.

You can import and export files either from and to the file system or a Quality Center project.

You can import an XML file as an object repository. The XML file can either be an object repository that you exported to XML format using the Object Repository Manager, or an XML file created using a tool such as QTP Siebel Test Express or a custom built utility. You must adhere to the XML structure and format.

Q. 63: How can we Integrate QuickTest with Quality Center?===============================================

You integrate QTP with Quality Center using the Quality Center Connectivity Add-in. This add-in is installed on your QTP computer automatically when you connect QTP to Quality Center using the Quality Center Connection dialog box. You can also install it manually from the Quality Center Add-ins page (available from the Quality Center main screen) by choosing Quality Center Connectivity.

integrating QTP with Quality Center enables you to store and access QTP tests and function libraries in a Quality Center project, when QTP is connected to Quality Center.

Q. 64: What is the use of Template Tests in QTP?=======================================
Template tests serve as the basis for all QTP tests created in Quality Center. A template test is a QTP test that contains default test settings. For example, a template test might specify the QTP add-ins, associated function libraries, and recovery scenarios that are associated with a test. You can modify these test settings in the Test Settings dialog box (File > Settings) in QuickTest.

In addition to default test settings, a template test can also contain any comments or steps you want to include with all new QTP tests created in Quality Center. For example, you may want to add a comment notifying users which add-ins are associated with the template test, or you may want to add a step that opens a specific Web page or application at the beginning of every test. Any steps or comments you add to a template test are included in all new tests created in Quality Center that are based on that template test.

Q. 65: How can we create a QTP Test in Quality Center?============================================

In Quality Center, you create QuickTest tests in the Test Plan module. When you create a QuickTest test, you apply a template test to it. You can choose either the default template test stored on your QuickTest client, or a template test that is saved in your Quality Center project.
If you do not have any template tests saved in your Quality Center project, or if you choose in the Template box, Quality Center uses the settings defined in the template test that was installed with the QTP Add-in for Quality Center on your Quality Center client.

Q. 66: What is Business Process Testing model?======================================

The Business Process Testing model is role-based, allowing non-technical Experts working in Quality Center to collaborate effectively with Automation Engineers working in QTP.

Non-technical Subject Matter Experts define and document business processes, business components, and business process tests, while Automation Engineers define the required resources and settings, such as shared object repositories, function libraries, and recovery scenarios. Together, they can build, data-drive, document, and run business process tests, without requiring programming knowledge on the part of the Non-technical Subject Matter Expert.

Q. 67: What is the role of Subject Matter Expert in the Business Process Testing model?

The Subject Matter Expert has specific knowledge of the application logic, a high-level understanding of the entire system, and a detailed understanding of the individual elements and tasks that are fundamental to the application being tested.

This enables the Subject Matter Expert to determine the operating scenarios or business processes that must be tested and identify the key business activities that are common to multiple business processes.

During the design phase, the Subject Matter Expert works with the Automation Engineer to identify the resources and settings needed to automate the components, enabling the Automation Engineer to prepare them.

The Subject Matter Expert configures the values used for business process tests, runs them in test sets, and reviews the results. The Subject Matter Expert is also responsible for maintaining the testing steps for each of the individual business components.

While defining components, Subject Matter Experts continue collaborating with the Automation Engineer.

Q. 68: What is the role of Automation Engineer in the Business Process Testing model?

The Automation Engineer is an expert in using an automated testing tool, such as QTP. The Automation Engineer works with the Subject Matter Expert to identify the resources that are needed for the various business process tests.

The Automation Engineer then prepares the resources and settings required for testing the features associated with each specific component, and stores them in an application area within the same Quality Center project used by the Subject Matter Experts who create and run the business process tests for the specific application.

The Automation Engineer uses QTP features and functionality to create these resources from within QTP.

Q. 69: What are the Differences Between Components and Tests?===================================================
# A component is a single entity. It cannot contain multiple actions or have calls to other actions or to other components.

# When working with components, all external files are stored in the Quality Center project to which you are currently connected.

# The name of the component node in the Keyword View is the same as the saved component. You cannot rename the node.

# Business components are created in the Keyword View, not the Expert View.

# You add resources via the component’s application area, and not directly to the component.

# Components use custom keywords created in function libraries to perform operations, such as verifying property values and opening the application you are testing.

Q. 70: How can we compare objects among two object repositories?======================================================

In QTP, we can compare existing assets from two object repositories using the Object Repository Comparison Tool.

The tool is accessible from the Object Repository Manager, and enables you to compare different object repository resources, or different versions of the same object repository resource, and identify similarities, variations, or changes.

Differences between objects in the two object repository files, named the First and Second files, are identified according to default rules. During the comparison process, the object repository files remain unchanged.

After the compare process, the Comparison Tool provides a graphic presentation of the objects in the object repositories, which are shown as nodes in a hierarchy.

Keyword: QTP Interview Questions, FAQ QTP


QTP - Interview Question Bank : Part 6

Q. 51: What is the use of mapping Repository Parameter Values in QTP

You can map repository parameters that are used in shared object repositories that are associated with your action. Mapping a repository parameter to a value or parameter specifies the property values used toidentify the test object during a run session. You can specify that the property value is taken from a constant value, or parameterize it using a Data Table, random number, environment, or test parameter.

You can map each repository parameter as required in each test that has an associated object repository containing repository parameters.

If you do not map a repository parameter, the default value that was defined with the parameter, if any, is used during the action run. If the parameter is unmapped, meaning no default value was specified for it, the test run may fail if a test object cannot be identified because it has an unmapped parameter value.

Q. 52: What are the various Object Properties in QTP?===========================================
QTP has a predefined set of properties that it learns for each test object. If these mandatory property values are not sufficient to uniquely identify a learned object, QTP can add some assistive properties and/or an ordinal identifier to create a unique description.

Mandatory properties are properties that QTP always learns for a particular test object class.

Assistive properties are properties that QTP learns only if the mandatory properties that QTP learns for a particular object in your application are not sufficient to create a unique description. If several assistive properties are defined for an object class, then QTP learns one assistive property at a time, and stops as soon as it creates a unique description for the object. If QTP does learn assistive properties, those properties are added to the test object description.

Q. 53: What are the various types of ordinal identifiers used by QTP to identify an object?

1) Index Property: Indicates the order in which the object appears in the application code relative to other objects with an otherwise identical description.

2) Location Property: Indicates the order in which the object appears within the parent window, frame, or dialog box relative to other objects with an otherwise identical description.

3) CreationTime Property: (For Browser object only.) Indicates the order in which the browser was opened relative to other open browsers with an otherwise identical description.

Q. 54: What is Index Property for identifying the objects in QTP?===================================================

While learning an object, QTP can assign a value to the test object’s Index property to uniquely identify the object. The value is based on the order in which the object appears within the source code. The first occurrence is 0.

Index property values are object-specific. Therefore, if you use Index:=3 to describe a WebEdit test object, QTP searches for the fourth WebEdit object in the page.

However, if you use Index:=3 to describe a WebElement object, QTPt searches for the fourth Web object on the page—regardless of the type—because the WebElement object applies to all Web objects.

Q. 55: What is Location Property for identifying the objects in QTP?=====================================================

While learning an object, QTP can assign a value to the test object’s Location property to uniquely identify the object. The value is based on the order in which the object appears within the window, frame, or dialog box, in relation to other objects with identical properties. The first occurrence of the object is 0. Values are assigned in columns from top to bottom, and left to right.

Location property values are object-specific. Therefore, if you use Location:=3 to describe a WinButton test object, QTP searches from top to bottom, and left to right for the fourth WinButton object in the page. However, if you use Location:=3 to describe a WinObject object, QuickTest searches from top to bottom, and left to right for the fourth standard object on the page— regardless of the type—because the WinObject object applies to all standard objects.

Q. 56: What is Creation Time Property for identifying the objects in QTP?

While learning a browser object, if QTP is unable to uniquely identify the object according to its test object description, it assigns a value to the CreationTime test object property. This value indicates the order in which the browser was opened relative to other open browsers with an otherwise identical description. The first browser that opens receives the value CreationTime = 0.

During the run session, if QTP is unable to identify a browser object based solely on its test object description, it examines the order in which the browsers were opened, and then uses the CreationTime property to identify the correct one.

For example, if you record a test on three otherwise identical browsers that are opened at 9:01 pm, 9:03 pm, and 9:05 pm, QuickTest assigns the CreationTime values, as follows: CreationTime = 0 to the 9:01 am browser, CreationTime = 1 to the 9:03 am browser, and CreationTime = 2 to the 9:06 am browser.

At 10:30 pm, when you run your test, suppose the browsers are opened at 10:31 pm, 10:33 pm, and 10:34 pm. QTP identifies the browsers, as follows: the 10:31 pm browser is identified with the browser test object with CreationTime = 0, 10:33 pm browser is identified with the test object with CreationTime = 1, 10:34 pm browser is identified with the test object with CreationTime = 2.

Q. 57: What is the Smart Identification Process of QTP
If QTP activates the Smart Identification mechanism during a run session, it follows the following process to identify the object:

1) QTP “forgets” the learned test object description and creates a new object candidate list containing the objects (within the object’s parent object) that match all of the properties defined in the Base Filter Properties list.

2) QTP filters out any object in the object candidate list that does not match the first property listed in the Optional Filter Properties list. The remaining objects become the new object candidate list.

3) QTP evaluates the new object candidate list:
# If the new object candidate list still has more than one object, QTP uses the new (smaller) object candidate list to repeat step 2 for the next optional filter property in the list.

# If the new object candidate list is empty, QTP ignores this optional filter property, returns to the previous object candidate list, and repeats step 2 for the next optional filter property in the list.

# If the object candidate list contains exactly one object, then QTP concludes that it has identified the object and performs the statement containing the object.

4) QTP continues the process described in steps 2 and 3 until it either identifies one object, or runs out of optional filter properties to use. If, after completing the Smart Identification elimination process, QTP still cannot identify the object, then QTP uses the learned description plus the ordinal identifier to identify the object. If the combined learned description and ordinal identifier are not sufficientto identify the object, then QuickTest stops the run session and displays aRun Error message.

Q. 58: What happens in case Smart Identification fails to identify the object in QTP?
If the Smart Identification mechanism cannot successfully identify the object, QTP uses the learned description plus the ordinal identifier to identify the object.
If the object is still not identified, the test fails and a normal failed step is displayed in the results.

Q. 59: What is the use of Repository Parameters in QTP?=============================================
Repository parameters enable you to specify that certain property values should be parameterized, but leave the actual parameterization to be defined in each test that is associated with the object repository that contains the parameterized test object property values.

Repository parameters are useful when you want to create and run tests on an object that changes dynamically. An object may change dynamically if it is frequently updated in the application, or if its property values are set using dynamic content, for example, from a database.

Q. 60: How can we locate test objects in an object repository?=================================================

You can search for a specific test object in your object repository in many ways.
You can search for a test object according to its type. For example, you can search for a specific edit box, or you can point to an object in your application to automatically highlight that same object in your repository.

You can replace specific property values with other property values. For example, you can replace a property value userName with the value user name.

You can also select an object in your object repository and highlight it in your application to check which object it is.

After making sure that your shared object repository is the active window, you locate an object in a shared object repository in the same way as you locate it in a local object repository. If you want to replace property values, you must also make sure that the object repository is editable.

Keyword: QTP Interview Questions, FAQ QTP


Saturday, September 27, 2008

QTP - Interview Question Bank : Part 5

Q. 41: What are the various utilities and tools available in QTP?
Tools Menu contains the following utilities and tools which are helpful in the testing process:

# Action Conversion Tool: Enables you to convert test actions that were created using QTP to scripted components for use in business process testing.

# Additional Installation Requirements: Opens the Additional Installation Requirements dialog box, which displays any prerequisite software that you must install or configure to work with QTP.

# Business Component Upgrade Tool: Opens the Business Component Upgrade Tool. If you are connected to a Quality Center project, this tool enables you to upgrade all of the business components in a Quality Center project, from an earlier component version to the format required by the current version.

# HP Micro Player: Opens the HP Micro Player, which enables you to view captured movies of a run session without opening QuickTest.

# License Validation Utility: Opens the License Validation utility, which enables you to retrieve and validate license information.

# Password Encoder: Opens the Password Encoder dialog box, which enables you to encode passwords. You can use the resulting strings as method arguments or Data Table parameter values (tests only).

# QTP Script Editor: Opens the QTP Script Editor, which enables you to open and modify the scripts of multiple tests and function libraries, simultaneously.

# Register New Browser Control: Opens the Register Browser Control Utility, which enables you to register your browser control application so that QTP recognizes your Web object when recording or running tests.

# Remote Agent: Activates the QuickTest Remote Agent, which enables you to configure how QuickTest behaves when a test is run by a remote application such as Quality Center.

# Save and Restore Settings: Opens the Save and Restore Settings dialog box, which enables you to save your existing configurations before uninstalling an old version, and then restore them after installing a new version.

# Silent Test Runner: Opens the Silent Test Runner dialog box, which enables you to run a QTP test the way it is run from LoadRunner and Business Availability Center.

# Test Batch Runner: Opens the Test Batch Runner dialog box, which enables you to set up QTP to run several tests in succession.

# Test Results Deletion Tool. Opens the Test Results Deletion Tool dialog box, which enables you to delete unwanted or obsolete results from your system according to specific criteria that you define.

Q. 42: What is the concept of Test Object Model in QTP?============================================
QTP tests your dynamically changing application by learning and identifying test objects and their expected properties and values. To do this, QTP analyzes each object in your application in much the same way that a person would look at a photograph and remember its details.

The test object model is a large set of object types or classes that QTP uses to represent the objects in your application. Each test object class has a list of properties that can uniquely identify objects of that class and a set of relevant methods that QuickTest can learn about it.
A test object is an object that QTP creates in the test to represent the actual object in your application. QTP stores information on the object that will help it identify and check the object during the run session.

A run-time object is the actual object in your application on which methods are performed during the run session.

Q.43: Please explain some real world scenario explaining Object Learning process of QTP?
QTP learns objects just as you would. For example, suppose as part of an experiment, Alex is told that he will be shown a photograph of a picnic scene for a few seconds during which someone will point out one item in the picture. Alex is told that he will be expected to identify that item again in identical or similar pictures one week from today.

Before he is shown the photograph, Alex begins preparing himself for the test by thinking about which characteristics he wants to learn about the item that the tester indicates. Obviously, he will automatically note whether it is a person, inanimate object, animal, or plant. Then, if it is a person, he will try to commit to memory the gender, skin color, and age. If it is an animal, he will try to remember the type of animal, its color, and so forth.

The tester shows the scene to Alex and points out one of three children sitting on a picnic blanket. Alex notes that it is a Caucasian girl about 8 years old. In looking at the rest of the picture, however, he realizes that one of the other children in the picture could also fit that description. In addition to learning his planned list of characteristics, he also notes that the girl he is supposed to identify has long, brown hair.

Now that only one person in the picture fits the characteristics he learned, he is fairly sure that he will be able to identify the girl again, even if the scene the tester shows him next week is slightly different.

Since he still has a few moments left to look at the picture, he attempts to notice other, more subtle differences between the child he is supposed to remember and the others in the picture—just in case.

If the two similar children in the picture appeared to be identical twins, Alex might also take note of some less permanent feature of the child, such as the child’s position on the picnic blanket. That would enable him to identify the child if he were shown another picture in which the children were sitting on the blanket in the same order.

Q. 44: What is the method used by QTP to learn objects?=============================================

QTP “looks” at the object being learned and stores it as a test object, determining in which test object class it fits. In the same way, Alex immediately checked whether the item was a person, animal, plant, or inanimate object. QTP might classify the test object as a standard Windows dialog box (Dialog), a Web button (WebButton), or a Visual Basic scroll bar object (VbScrollBar), for example.

Then, for each test object class, QTP has a list of mandatory properties that it always learns; similar to the list of characteristics that Alex planned to learn before seeing the picture. When QTP learns an object, it always learns these default property values, and then “looks” at the rest of the objects on the page, dialog box, or other parent object to check whether this description is enough to uniquely identify the object. If it is not, QTP adds assistive properties, one by one, to the description, until it has compiled a unique description; similar to when Alex added the hair length and color characteristics to his list. If no assistive properties are available, or if those available are not sufficient to create a unique description, QTP adds a special ordinal identifier, such as the object’s location on the page or in the source code, to create a unique description.

Q. 45: What is Test Object Methodin QTP?
It is a method that QTP recognizes as applicable to a particular test object. For example, the Click method is applicable to a WebButton test object. As you add steps to your test, you specify which method to perform on each test object. If you record steps, QTP records the relevant method as it is performed on an object.

During a run session, QTP performs the specified test object method on the run-time object. Run-time object methods are the methods of the object in your application as defined by the object creator. You can access and perform run-time object methods using the Object property.

Q. 46: What are the Test object propertiesin QTP?=======================================
Test object properties are the properties whose values are captured from the objects in your application when QTP learns the object. QTP uses the values of these properties to identify run-time objects in your application during a run session.

Property values of objects in your application may change dynamically each time your application opens, or based on certain conditions. You may need to modify the test object property values to match the run-time object property values. You can modify test object properties manually while designing your test, or use SetTOProperty statements during a run session.

Q. 47: How to decide on whether to save the objects in Local or Shared Object Repositories?
Local object repository is easiest to use when you are creating simple tests, especially under the following conditions:
# You have only one, or very few, tests that correspond to a given application, interface, or set of objects.
# You do not expect to frequently modify object properties.
# You generally create single-action tests.

Shared object repository is the preferred option when:
# You are creating tests using keyword-driven methodologies (not by recording).
# You have several tests that test elements of the same application, interface, or set of objects.
# You expect the object properties in your application to change from time to time and/or you regularly need to update or modify object properties.
# You often work with multi-action tests and regularly use the Insert Copy of Action and Insert Call to Action options.

Q. 48: What are the possibilities of Exporting the data among various Object Repositories?
When QTP learns a test object, it adds it to the local object repository & not to the shared object repository — unless the same test object already exists in an associated shared object repository. (In this case, QTP uses the existing information in the shared object repository.)

You can export objects from the local object repository to a shared object repository. You can also export the local object repository and replace it with a shared object repository. This enables you to make the local objects accessible to other actions.

You can also merge objects from the local object repository directly to a shared object repository that is associated with the same action. This can help reduce maintenance since you can maintain the objects in a single shared location, instead of multiple locations.

Q. 49: What is the effect of restoring Default Properties for a Test Object in QTP?===================================================
When you restore the default properties, it restores the mandatory property set defined for the selected object class in the Object Identification dialog box.

Any changes that you have made to the description property set for the test object will be overwritten. However, if property values were defined for any of the mandatory properties they are not modified.

Q. 50: What is the use of Ordinal Identifiers in QTP
An ordinal identifier assigns a numerical value to a test object that indicates its order or location relative to other objects with an otherwise identical description (objects that have the same values for all properties).

This ordered value provides a backup mechanism that enables QTP to create a unique description to recognize an object when the defined properties are not sufficient to do so. You can specify the ordinal identifier for test objects in the local object repository using the Object Repository window or Object Properties dialog box, and for test objects in the shared object repository using the Object Repository Manager.

Keyword: QTP Interview Questions, FAQ QTP


QTP - Interview Question Bank : Part 4

Q. 31: What are the Environment Variables?

Environment variables are global variables available to all Actions
# They can be used to run a test case on different environment
# To add a new Environment variable go to Test -> Settings…->Environment (Tab)
# Environment variables are of two type:

1. Built in environment variables: Provide information about the system and the current test
2. User-Defined environment variables: are added in the Environment tab of Test Settings. These are Read-only during the test run

Q. 32: How many types of Parameters are there in QTP?============================================
There are two types of parameters:
1. Test parameters:
# These can be set in Test->Settings…->Parameters (Tab)
# Test parameters value can be provided when replaying the test
# Test arguments can be accessed in the test using TestArgs("")

2. Action parameters :
# Used to pass parameters to Action
# Output parameters can only be used when Action is being called for a single iteration
# Ex - RunAction "Login", oneIteration, "TestUser", "TestPass", out
# A parameter can be accessed using Parameter("ParamName")

Q. 33: What is Descriptive Programming?
Descriptive Programming is an alternate way of writing test cases without having objects in object repository

Descriptive programming can be done in two ways
1. Using Object description
2. Using String description

In Descriptive programming objects are identified by describing all the identification properties

Q. 34: After creating the test, what is the purpose of runing them?===================================================
1) To check your application: The test starts running from the first line in your test and stops at the end of the test. While running, QTP connects to your application and performs each operation in your test, including any checkpoints, such as checking any text strings, objects, tables, and so forth. If you parameterized your test with Data Table parameters, QTP repeats the test (or specific actions in your test) for each set of data values you defined.

2) To debug your application: You can control your run session to help you identify and eliminate defects in your test. You can use the Step Into, Step Over, and Step Out commands to run your test step by step. You can begin your run session from a specific step in your test, or run the test until a specific step is reached. You can also set breakpoints to pause your test at predetermined points. You can view the value of variables in your test each time it stops at a breakpoint in the Debug Viewer.

3) To update your application: You can run your test using Update Run Mode to update the property sets used for test object descriptions, the expected checkpoint values, the data available to retrieve in output values, and/or the Active Screen images and values.

You can run your test using Maintenance Run Mode when you know that your application has changed, and you therefore expect that QTP will not be able to identify the objects in your test. When you run tests in Maintenance Run Mode, a wizard opens for steps that fail because an object could not be found in the application. The wizard then guides you through the steps of resolving the issue, and, after you resolve the issue, the run continues.

Q. 35: What are the main stages of Testing with QTP?==========================================
Testing with QuickTest involves the following main stages:
1) Planning
2) Creating Tests
3) Running Tests
4) Analysing Results

Q. 36 : How can we do the Analysis of Results in QTP?===========================================
After you run your test, you can view the results.

# View the results in the Test Results window: After you run your test, you can view the results of the run in the Test Results window. You can view a summary of your results as well as a detailed report. If you captured still images or movies of your application during therun, you can view these from the Test Results window.

# Report defects detected during a run session: If you have access to Quality Center, the HP centralized quality solution, you can report the defects you discover to the project database. You can instruct QTP to automatically report each failed step in your test, oryou can report them manually from the Test Results window.

Q. 37: What is Business Process Testing?
# Business Process Testing is a role-based testing model that enables Subject Matter Experts—who understand the various parts of the application being tested—to create business process tests in Quality Center. Automation Engineers—who are experts in QTP and automated testing—use QTP to define all of the resources and settings required to create business process tests.

# Business Process Testing uses a keyword-driven methodology for testing, based on the creation and implementation of business components and business process tests. A business component is an easily-maintained, reusable unit comprising one or more steps that perform a specific task within an application.

Q. 38: What are Permissions Required to Run QuickTest Professional?============================================
You must have the following file system permissions:

1) Full read and write permissions for all the files and folders under the folder in which QTP is installed

2) Full read and write permissions to the Temp folder

3) Read permissions to the Windows folder and to the System folder

You must have the following registry key permissions:
1) Full read and write permissions to all the keys under HKEY_CURRENT_USER\Software\Mercury Interactive

2) Read and Query Value permissions to all the HKEY_LOCAL_MACHINE and HKEY_CLASSES_ROOT keys

Q. 39: What is the role of Keyword view in QTP?======================================
The Keyword View enables you to create and view the steps of your test in a keyword-driven, modular, table format. The Keyword View is comprised of a table-like view, in which each step is a separate row in the table, and each column represents different parts of the steps. You can modify the columns displayed to suit your requirements.

You create and modify tests by selecting items and operations in the Keyword View and entering information as required. Each step is automatically documented as you complete it, enabling you to view a description of your test steps in understandable English.

Each operation performed on your application during a recording session is recorded as a row in the Keyword View.

Q. 40: What is the role of Expert view in QTP?====================================
In the Expert View, QTP displays each operation performed on your application in the form of a script, comprised of VBScript statements. The Expert View is a script editor with many script editing capabilities. For each object and method in an Expert View statement, a corresponding row exists in the Keyword View.

Keyword: QTP Interview Questions, FAQ QTP


QTP - Interview Question Bank : Part 3

Q. 21: Where can we use a Function or an Action? ========================================
It all depends on the scenario.

If you want to use the OR feature then you have to go for Action only. If the functionality is not about any automation script i.e. a function like getting a string between to specific characters, now this is something not specific to QTP and can be done on pure VB Script, so this should be done in a function and not an action. Code specific to QTP can also be put into an function using DP. Decision of using function/action depends on what any one would be comfortable using in a given situation.

Q. 22: What is the difference between an Action and a Function? ===================================================
Action is a activity specific to QTP while functions are a generic thing which is a feature of VB Scripting. Action can have a object repository associated with it while a function can't. A function is just lines of code with some / none parameters and a single return value while an action can have more than one output parameters.

Q. 23: What are the various events available in the Recovery Scenario Manager? ================================================
1) Application Crash:
This event is useful in handling crashed applications at runtime.

2) Pop Up Window:
This event is useful in managing various unwanted application windows, which get built-up at runtime.

3) Test Run Error:
This event is useful in handling VBScript statement errors at runtime.

4) Object State:
This event is useful in handling object related errors at runtime.

Q. 24: What are the Elements of Recovery Scenario?=========================================
Steps to handle the exceptions are
1) Trigger Event: Is an unexpected event like appearance of a Pop-up window, object state, test run error causing application crash or interruption in our running session.

2) Recovery Steps: Constitutes a series of steps required to be performed to enable QTP to proceed further with the process of test after some trigger event has interrupted the run session. Examples of a recovery operation can be 1) A keyboard or mouse Operation like a Click over the "OK" button in the Pop-up window 2) Close Application Process 3) Function Call 4) Restarting the OS etc.

3) Post-Recovery Test Run:
Are a set of instructions designed to be provided to QTP on proceeding further with the test after some recovery operation has been carried out. Examples of Post Recovery actions can be repeating the complete test from the beginning or some steps may be skipped altogether & continuing with the remaining steps in the test.

Q. 25: When to use a Recovery Scenario and When to use "on error resume next"?=====================================================
Recovery scenarios are useful when it is difficult to predict at which step the errors can come or when we are confident that the error will not come in the QTP script, whereas it can be anywhere outside the QTP Script. For illustration; Pop-up message of "out of paper", as caused by the printer device driver. "On error resume next" is preferred when we sure that the error is expected one and wish to perform some other actions.

Q. 26: What are the key features of QTP at a glance:
# Ease of use:
QTP allows even novice testers to become productive in minutes. You can create a test script by simply pressing a Record button and using an application to perform a typical business process. Each step in the business process is automated documented with a plain-English sentence and screen shot. Users can easily modify, remove, or rearrange test steps in the Keyword View.

# Simple interface: QTP is much simpler to understand. It presents a test case as a simple business workflow to the tester.

# Simple Language: QTP uses Microsoft's VBScript for its test procedures, and to manipulate the objects and controls of the application under test. VBScript is a real programming language where several existing functions & resources are easily available for implementation these days.

# Use of zero-configuration Technology: QTP uses next-generation "zero-configuration" Keyword Driven testing technology. This helps in faster test creation, easier maintenance, and provides more powerful data-driving capability.

# Automatic insertion of checkpoints: QTP enables thorough validation of applications through a full complement of checkpoints. QTP can automatically introduce checkpoints to verify application properties and functionality, for example to validate output or check link validity.

# Marvelous interface with Data-tables: QTP allows entry of test data into the Data Table, an integrated spreadsheet with the full functionality of Excel, to manipulate data sets and create multiple test iterations, without programming, to expand test case coverage. Data can be typed in or imported from databases, spreadsheets, or text files. QTP has better and easier to use Data table integration compared to WinRunner.

# Better object identification mechanism: QTP Identifies objects with Unique Smart Object Recognition, even if objects change from build to build, thereby enabling reliable unattended script execution.

# Support of variety of environment: QTP supports functional testing of all popular environments, like Windows, Web, .Net, Visual Basic, ActiveX, Java, SAP, Siebel, Oracle, PeopleSoft, terminal emulators, and Web services.

# Easy adaptability of Microsoft Object Models: QTP can easily create and implement Microsoft Object Model like: Outlook objects, ADO objects, FileSystem objects, supports DOM, WSH, etc.

# Auto-documentation technology: QTP renders test documentation and test creation to a single step with the help of its auto-documentation technology

Q. 27: What are various types of properties when using object identification in QTP?
QTP uses three types of properties when identifying a object
1. Mandatory Properties - Always learn these properties for the object

2. Assistive Properties
- Learn in case Mandatory properties are not enough to identify the object uniquely

3. Ordinal identifiers
- Learn in case both mandatory and assistive properties are not able to recognize the objects correctly

Q. 28: What are the various ways to insert a Action in a test in QTP?=====================================================
There are three ways to insert a Action in a test
1. Insert Call to New…
2. Insert Call to Copy…
3. Insert Call to Existing…

Q. 29: What is the use of Parameterization in QTP?========================================
Parameterization is helpful in following aspects.# Parameterization allows us to pick different values at run time.
# Reduces Time and Effort.

# Usage of data drivers allows us to use the same data for various input boxes.

# Parameterization can also be done for checkpoints.

Q. 30: What are Data Tables in QTP?
Data Table is MS Excel like spreadsheet which can be used for parameterizing a test case
DataTable are of two types:
1. Global Data Table - Data table for Test flow

2. Local data table - Data table for every action

Keyword: QTP Interview Questions, FAQ QTP


QTP - Interview Question Bank : Part 2

Q. 11: What is a Virtual Object in QTP?

Since sometimes complex objects are not recognized & recorded properly by QTP. Hence an experienced user can define that object as a personal virtual object and build a virtual object repository. This way by the concept of Virtual Object, the user can add some sort of support for such complex objects.

If it is possible to extract the desired information from the object, we can do successful record and playback against that object.

Q. 12: How results are generated in QTP?

At the end of the test, QTP generates a result file for the test cases, which is in the form of a XML tree.

This results file provides detail regarding 'Pass' or 'Fail' counts, error messages, and all supporting information which allows the user to diagnose the main cause of a failure.
Q. 13: How many types of main views of a script are available in QTP?===================================================

QTP provides two main views of a script. These are

1) Keyword View: is the default test procedure interface of QTP & is most useful for the beginners. It displays the automation steps of a test procedure as a descriptive tree of Actions and functions. The tree contains columns listing the Action or function name, any parameters, and comments.

2) Expert View: is most suitable for the advanced users, enabling them to customize the test, like writing user-defined functions. It is meant for displaying and editing of the source code of the test. Except for the root Global action, all other test actions can be edited here. Expert View acts as an IDE for the test. It includes most standard IDE features, such as breakpoints.

Both Keyword View & the Expert View can be selected from tabs available at the bottom of the QTP window.
Q. 14: What is a Checkpoint?
In QTP, Checkpoint is used to verify the application under test. It can introduce a checkpoint to verify as to whether a particular object, text or a bitmap is present in the automation run.
During a test execution, a checkpoint verifies that the behavior or state of the actual application is consistent with the expected application or not.

Q. 15: How many types of Checkpoints are available in QTP
1) Standard Checkpoint
- for checking the properties of an object.
2) Table Checkpoint - for checking the properties of a table.
3) Image Checkpoint - for checking the properties of an image.
4) Bitmap Checkpoint - for comparing an area of the application under test pixel-by-pixel with the screen as seen at record-time.
5) Database Checkpoint - for automating the back-end testing.
6) Text Checkpoint - for checking that a section of text is found between two other sections of text.
7) Text Area Checkpoint
8) Page Checkpoint - for checking the properties of a web page.
9) Accessibility Checkpoint - for checking the accessibility of an application.
10) XML Checkpoint

Q. 16: What is the use of Text output value in QTP? ========================================

Text Output values enable us to view the values which are taken by the application during the run time. If parameterized, the values change for every iteration. Hence by creating output values, we can capture the values which are taken by the application during the run time and output them to the data table.

Q. 17: What's the difference between a Checkpoint and Output Value?=================================================
Checkpoint only checks for the specific attribute of an object in AUT while Output value can output those attributes value to a column in data table.

Q. 18: How can we Disable Smart Identification During the Run Session?==================================================
Selection of the option "Disable Smart Identification during the run session", Instructs QTP not to use the Smart Identification mechanism during the run session.

When we select this option, the Enable Smart Identification check boxes in the Object Properties and Object Repository dialog boxes get disabled, although the settings are saved. However when you clear this option, the Enable Smart Identification check boxes return to their previous on or off setting.

Q. 19: What are the Properties used by Smart Identification Feature of QTP?=====================================================
1) Base filter properties:
Are the most fundamental properties of a particular test object class. Her we can not change their values without changing the essence of the original object.

2) Optional filter properties: Are other properties, which help us in identifying the objects of a particular class since these are not likely to get changed frequently. These properties can be ignored in case these are not applicable any more.

Q. 20: How can we check if an environment variable exists or not? ====================================================
When we use Environment("Param1").value then QTP expects the environment variable to be already defined. But when we use Environment.value("Param1") then QTP will create a new internal environment variable if it does not exists already. So to be sure that variable exist in the environment try using Environment("Param1").value.

Keyword: QTP Interview Questions, FAQ QTP


QTP - Interview Question Bank : Part 1

Q. 1: What is Automation Object Model in QTP?======================================
Like we use QTP for automating the testing of our applications, we can use the automation object model of QTP to automate its own operations as well. With the help of objects, methods, and properties exposed by the automation object model of QTP along with standard programming elements like loops and conditional statements, we can write programs which can configure QTP options and run tests or components instead of performing these operations manually using the QTP interface.

Automation programs are especially useful for performing the same tasks several times or on multiple tests or components, or quickly configuring QTP according to the needs for a particular environment or application.

Most of the dialog boxes in QTP have a corresponding automation object. Most of the options in dialog boxes can be set retrieved using the corresponding object property, and most of the menu commands and other operations have corresponding automation methods.
Q. 2: What is a Recovery Scenario?

Recovery scenario gives you an option to take some action for recovering from a fatal error in the test. Such problems are quite frequent especially when the tests are made to run unattended. In such a case the test process halts until the user perform some desired recovery operation.

Recovery scenarios are useful when it is difficult to predict at which step the errors can come or when we are confident that the error will not come in the QTP script, whereas it can be anywhere outside the QTP Script. For illustration; Pop-up message of "out of paper", as caused by the printer device driver. "On error resume next" is preferred when we sure that the error is expected one and wish to perform some other actions.
Q. 3: What is Smart Identification in QTP?
QTP has a unique feature by the name Smart Object Identification or recognition which is used for identifying the objects smartly, whenever the normal identification fails due to the dynamic changes in the properties of the objects.

Smart Identification is nothing but an algorithm used by the QTP when it is not able to recognize an object.
Q. 4: How QTP identifies various Objects?
During recording QTP identifies various objects and stores them as test objects. For each test object QTP learns a set of default properties called mandatory properties. Simultaneously QTP looks at rest of the objects to check whether these properties are sufficient to uniquely identify the object or not. During the test run, QTP searches for the run time objects, which match with the test objects which, have been captured by it during recording.

Q. 5: What are Object Repositories in QTP? ==================================
When planning and creation of tests is done, we firstly consider how we would like to store the objects in our tests. In QTP, the test objects can be stored in two types of object repositories

a) Shared object repository: It stores test objects in a file that can be accessed by multiple tests (in read-only mode). If someone is new to QTP, he can prefer to use local object repositories. This way he can record and run the tests without creating, choosing, or modifying shared object repositories because all objects are automatically getting saved in a local object repository which can be accessed by its corresponding action.

b) Local object repository: It stores objects in a file that is associated with one specific action, so that only that action can access the stored objects. If someone is familiar with QTP testing, he can find that it is quite efficient to save the objects in a shared object repository. This way, he can use the same shared object repository for multiple actions - if the actions include the same objects. Test object information that applies to many actions is kept in one centralized location. When the objects in the application change, we can update them in one location for all the actions that use this shared object repository.

Q. 6: How QTP recognizes objects in Object Repositories? ==============================================
Object Repository displays a tree of all the objects in the current component or in the current action or in the entire test , depending on the object repository mode selected by the user. We can view or modify the test object description of any test object in the repository or to add new objects to the repository.

QTP remembers the default property values and determines in which test object class it fits. If it is not found enough it automatically adds assistive properties, one by one to the description until it successfully compiles the unique description. If no assistive properties are available, then it adds a special Ordinal identifier such as object location on the page or in the source code.

Q. 7: How many types of Actions are there in QTP? ========================================
QTP uses following three kinds of actions:
a) Non-reusable action - can be called only in the test with which it is stored, and can be called only once.

b) Reusable action - can be called multiple times by the test with which it is stored (the local test) as well as by other tests.

c) External action - is a reusable action which is stored with another test. External actions are read-only in the calling test, but we can choose to use a local, editable copy of the Data Table information for the external action.

By default, all new actions are non-reusable. We can mark every action created by us in the test as reusable or non-reusable.
Q. 8: Is there any built-in function for scripting in QTP? ===========================================

QTP uses an in-built functionality called "Step Generator" to create scripts while appropriate steps are entered into it. Step Generator utility enables us to add steps by selecting from a range of context-sensitive options and entering the required values.

You can open the Step Generator from the Keyword View or Expert View while recording or editing your test. You can also open the Step Generator from the Active Screen while editing.
Method to open the Step Generator from a function library is as under

a) In the function library, click the location in which you want to insert the new step.

b) Choose Insert > Step Generator, or right-click and choose Step Generator. Alternatively, press F7.

Q. 9: What is a Run-Time Data Table in QTP? ====================================
During the run session, QTP creates a Runtime Data Table, which is live version of the Data Table associated with our test. During the run session, QTP displays the run-time data in the Data Table pane so that we can see the changes taking place in the Data Table.

When the run session ends, the Runtime Data Table closes, and the Data Table pane again displays the stored design-time Data Table. Data entered in the run-time Data Table during the run session does not get saved along with the test. The final data from the run-time Data Table gets displayed in the Run-Time Data Table in the Test Results window.

Runtime Data Table is an excel file, which gets stored in the folder of the test created, its name is Default.xls by default.
Q. 10: What is the Object Spy feature in QTP? ====================================
Using the Object Spy pointing hand mechanism, you can view the supported properties and methods of any object in an open application. As you move the pointing hand over the objects in the application, their details are displayed in the Object Spy. These details may include the test object’s hierarchy tree, its properties and values, and the methods associated with the object. For methods, the syntax is also displayed.

Keyword: QTP Interview Questions, FAQ QTP


Wednesday, September 3, 2008

Guidelines to select an Appropriate Automation Tool

If your organization is currently using manual means to test your software applications & is believing that it can derive tangible benefits by automating its software testing process, then simply jumping to a conclusion of buying some tool simply because it is popular among many, may not be wise. What should be done now is to take a judicious decision through a scientific process to find out as to which tool will best be suited to your needs. Since this is an capital intensive move aimed at taking your company to the world of Automated Testing, needs careful examination.

When you are shopping for a proper automation tool, you will come across several people ambitiously marketing their products, which may provide solution to variety of automated testing needs. Now the question arises as to whether a particular tool is really suitable to your needs or not. Are you not inclining your choice for a particular tool by making lot many compromises in features. Think that in times to come, your testing needs may become more complicated by the variety of applications coming across for testing & that too under variety of operating systems.

Thus following guidelines shall be helpful in evaluating & zeroing down your choice of an appropriate tool for the job at hand, out of a bunch of many testing tools sold by different vendors.

Guideline – 1: Understand your True Requirement

First of all don’t look at & form any type of opinion about any XYZ tool available in the market. This is high time for doing deep introspection of your real needs. It is wise to prepare a comprehensive list of your requirements of software testing at the present moment. Identify the time consuming problems, which you want to solve with the new tool. Identify the technical capabilities your prospective tool should have to be compatible with the environment of your application.

Following checklist can be helpful in a judicious compilation of your requirements:

a) List down the Compatibility issues: Remember that the tool selected by you has to be compatible with:
# The operating systems supported by your application to be tested

# The development environments under which the application shall be created

# Third party software if any with whom your application needs to be integrated at some stage

b) List down the Users of the Tool
# List down the people who will be actually using the prospective tool. Keep the skill levels of the available persons at the back of your mind.

# Remember that more powerful tools are bound to be more complex as well. If the skill level of the available manpower (who will be expected to use the prospective tool everyday), does not match the complexity level of the tool, believe me, you are likely to land into many problems in smooth implementation of the tool in your organization.

# Think as to whether there is enough time for training your staff within the prevailing time & budgetary constraints, if any.

c) List down the Testing requirements
Technical requirements like the following needs to be listed down before zeroing down your choice on a particular automation tool.
# Identify the types of your own testing problems you wish that your new tool should solve for you.

# Identify the problems faced by you during manual testing.

# Identify the time constraints coming across while making minor changes to your system.

# Identify the shorter regression testing time frames.

# Identify the Test data setup requirements.

# Identify the Defect tracking requirements you are aiming at.

# Identify the Increased test coverage you are looking for.

# Identify the Increase in efficiency of the testing process you are looking for.

Guideline – 2: Understand the constraints you have

You need to understand various factors, which may compel you to drop down some of the tools from your initial selection list. Such crucial factors need to be identified during the early stages of your tool selection process.

a) Environmental constraints

# Environmental constraints can be either related to hardware or the software itself.

# The prospective tool must be able to work on the desired operating systems

# The prospective tool must not dictate the terms of having some specialized hardware for its working.

# Up-gradation of existing hardware like providing more hard disk / More Ram etc. to cope with the requirements of additional scripts and test data likely to be added.

# Consider your likely objections to your new tool running under some specific environment, while the software application might be required to run under different environment or operating system. This issue may gain importance from the consideration of the future use of the new tool.

b) Credentials of the Vendors & their Clientele
It is certain that you won’t desire to hang on with problems with your new testing tool. Certainly anyone would like to have a quick, competent & professional solution to the tool related problems arising may be occasionally.

Following checklist may come handy in such a situation.
# The tool supplier must represent a genuine company.

# The tool as a product & its supplying company must be matured enough.

# The tool may not be worthwhile at all unless there is enough technical support available.

# Find out the clientele of the prospective tool & try to obtain the feedback from such organizations if possible.

# Find out the past history of the prospective tool?

c) Understand the Quality related characteristics
Following quality related constraints of the prospective tool should be helpful
# Identify the skill level required for using the prospective tool

# Verify as to whether it is possible to have multiple user access

# Identify the support and help documentation required.

# Verify as to whether it is possible to integrate the prospective tool with other tools.

# Ensure that there should not be any possibility of getting your data corrupted by the tool.

# Frequency of failure during realistic use

# Identify the budgetary constraints if any. Such financial constraints can restrict your choice of buying a particular tool.

Remember that it is not the question of just purchasing a particular tool by spending some money. In fact it has been seen that in many cases, the cost of fully implementing the tool can be much higher than the cost of the tool itself. Budgetary constraints shall be applicable not only to the tool purchase cost, but shall cover costs of licensing / AMC’s, costs of training and cost of tool implementation etc.

We can be in a position to evaluate various tools available in the market after compiling a comprehensive list of our requirements and various constraints.

Guideline – 3: Shortlist the most likely suitable tools

This is the stage when an extensive research is needed to identify various types of tools available in the market. WWW can be a good place to explore the tool. Preliminary study of the technical brochure of every tool shall reveal the capabilities of the tool fitting your requirements & constraints.

We can identify various features of every tool by classifying them like a) Essential features b) Desirable features c) Less relevant features etc.

a) Essential features: are the ones, which are extremely necessary to meet your requirements within the defined constraints.

b) Desirable features: are the ones, which will make a particular tool standout among many of its competitors. Based upon the presence of variety desirable features, your decision can be favor of a particular tool among many more.

c) Irrelevant features: are the ones, which are not of any great significance & may not be able to provide some tangible benefit to you in your present requirements.

Evaluation of the above types of features is the next exhaustive & iterative exercise. At this stage you should evaluate as much number of tools as possible and try to zero down your focus on around 5-6 tools any one of which could qualify to be the final tool fitting your ultimate choice.

The next step in the process should be establishing a contact with the tool suppliers & organizing a practical demonstration. If possible you can ask for an evaluation or trial version of the tool for refining your decision. At this stage you should clearly explain all your requirements of testing along with set of constraints to the tool supplier, who shall be in a better position to clarify many points left out by you during your short-listing process.

Guideline – 4: Making a Final Choice

Having gone through the above-defined rigorous process of evaluation, the time has come for you to take a decision in favor of one particular tool, which suits best into your slot of requirements & constraints.

a) Final Comparison of Features:
# With the help of all available data now you should be able to draw a clear comparison of the performance related features of the tools as desired by you vis-a-vis features claimed to be present in the technical literature provided by the persons marketing the tool.

# This is stage to go on for verification of the credential of the particular tool from the present users by visiting their web sites or making contact through other channels. This shall help you in refining your choice of a particular tool.

b) Practical demonstration at your site:
If a particular tool has already caught your attention, you can ask the supplier to organize a live demonstration of the tool under your actual working environment. This way you will be able to judge the technical capability of the supplier as well in providing support later-on.

c) Maintenance of Test Script
Proper maintenance of automation scripts & ease of handling them is very important aspect of the tool under evaluation. Although we may not be able to make an on the spot judgement about this capability, but this aspect gets confirmed during the second or third release of testing after implementing the new tool.

d) Final Comparative Trial
Now this is the time for conducting same test on one particular application time & again on each & every short-listed tool independently. This way you shall be in a position to make a final decision in favor of a particular tool out of a box of many.

Key Word : Automation Tool, Tool Selection


Tuesday, September 2, 2008

Introduction to Test Automation Framework

Judiciously testing all possible permutations of such components creates a highly complex testing situation with hundreds or thousands of testing scenarios. Under such situations there comes a need for automating the testing process with the help of automation framework approach, which can help in achieving detailed testing with great reduction in testing time.

It can never be a workable idea to automate all the test cases. Hence it is important to scientifically understand the areas which can be automated. Remember that an ad-hoc approach to test automation can in fact, lead to longer testing time and poor quality irrespective of the name & fame of the testing tool selected by you.

Now let us understand what is ‘Test Automation Framework’?

Test Automation Framework is a set of assumptions, concepts and practices which provide necessary support for the automated software testing.

The main advantage of such a framework is the low cost for maintenance. If there is change to any test case then only the test case file needs to be updated and the Driver Script and Startup script will remain the same. There's no need to update the scripts in case of changes to the application.

Types of Automation Framework:

1) Modularity driven framework:
It requires the creation of small, independent scripts that represent modules, sections, and functions of the application-under-test. These small scripts are then used in a hierarchical fashion to construct larger tests, realizing a particular test case. It applies the principle of abstraction or encapsulation in order to improve the maintainability and scalability of automated test suites.

2) Data driven framework: It involves bunch of several interacting test scripts clubbed with their related data results. In this framework, variables are used for both input values and output verification values: navigation through the program, reading of the data sources, and logging of test status and information are all coded in the test script. It is quite suitable framework for use in RFT using Data-pools. This approach reduces coding effort to a great extent in case of large test cases, which otherwise could be quite time-consuming & cumbersome.

3) Keyword driven framework: It involves automated tests, which have inherent reusability and therefore ease of maintenance of tests that have been created at a high level of abstraction. It divides test creation into two stages like

a) Planning Stage: Involving analysis of the requirements for the application to determine which operations and objects have to be tested. E.g. an application having web based questionnaire will require a large amount of text entries.

b) Implementation Stage: It differs according to the tool or framework used. Generally automation engineers implement a framework that provides keywords like "check" and "enter". Testing engineers (who don’t have to know the coding) write the test cases based on the keywords defined in the planning stage that have been implemented by the engineers. The test is executed using a driver who reads the keywords and executes the corresponding code.

Keyword Driven Framework methodology requires more planning and a longer initial time-investment than going directly to the test creation stage and recording a test, it does make the test creation and test maintenance stages more efficient and keeps the structure of individual tests more readable and easier to modify.

4) Hybrid framework: Is a combination of three frameworks. This type of frameworks evolve over a passage of time and across multiple projects. It is the most successful automation frameworks, which generally accommodates both Keyword-driven testing as well as Data-driven testing. This allows data driven scripts to take advantage of the powerful libraries and utilities that usually accompany a keyword driven architecture.

In this case, the framework utilities can make the data driven scripts more compact and less prone to failure. The utilities can also facilitate the gradual and manageable conversion of existing scripts to keyword driven scripts as & when required. On the other hand, the framework can use scripts to perform some tasks that might be too difficult to re-implement in a pure keyword driven approach, or where the keyword driven capabilities are not yet in place.

Ten Steps for Test Automation Framework Methodology:

1) Identification of the Scope of Testing: Company oriented, Product oriented, Project Oriented.

2) Identification of the Needs of Testing: Identify Types of testing e.g. FT, Web Services etc. and application / modules to be tested.}

3) Identification of the Requirements of Testing:
Find out the nature of requirements, identify type of actions for each requirement & identify high priority requirements.

4) Evaluation of the Test Automation Tool: Evaluation checklist, Identify the candidate tools available in the market, Sample run, rate & select the tools, Implementation & Training

5) Identification of the Actions to be automated: Actions, Validations & requirements supported by the Tool

6) Design of the Test Automation Framework: Framework guidelines, validations, Actions Involved, Systems involved, Tool Extensibility Support, Customs messages & UML Documentation.

7) Design of the Input Data Bank: Types of Input file. Input files – Categorization & Design of file prototypes.

8) Development of the Automation Framework: Development of script based upon framework design, Driver scripts, Worker Scripts, Record / Playback, Screen / Window / Transaction, Action / Keyword & Data Driven.

9) Population of Input Data Bank: Different Types of data Input, Populate data from different data sources, Manual input of data and Parent – Child data hierarchy.

10) Configuration of the Schedulers: Identify scheduler requirements & configure the schedulers.

Benefits of Test Automation Framework Approach:
Test Automation Framework built with systematic approach yields following benefits:

# Ensures consistency
# Significant reduction in the amount of code to develop & maintain thereby reducing the testing cycle time.
# Comprehensive coverage against requirements.
# Use of a "Common Standard" across the organization / Product team / Project team
# Maximizes reusability of test scripts ( Utility Functions)
# Provides a structured for test library having systematic maintenance of automation scripts
# Data Pooling
# Protects non-technical testers from the code

Key Word: QTP, Automation, Automation Framework,


Copyright © 2009 ExpertQTP