Tuesday, 4 March 2014

QTP Frame Works BPT

What is Business Process Testing framework in QTP? How to implement Business Process testing framework? Business Process Testing enables Sub... thumbnail 1 summary

What is Business Process Testing framework in QTP?


How to implement Business Process testing framework?
Business Process Testing enables Subject Matter Experts to design quality Assurance tests for an application early in the development cycle and in a Script-free environment.
--This means without knowledge of Programming Business Analysts/un programming departments also can prepare set up of BPT
Business Process Testing uses a new methodology for testing, and in conjunction with testing tools such as Quick Test Professional/win runner

Note: The Business Components module is available only if your Quality Center license includes Business Process Testing.


Advantages of Business Process Testing:

·                     Cost reduction
·                     BPT can be prepared in Script free Environment by the Business Analysts
·                      Business Process Testing is not dependent on the completion of detailed testing scripts.
·                      test automation and automatically generated,
·                     Easy-to-understand, plain-language test documentation.
·                     Applications can be tested manually before automated tests are ready.
·                     Use modular, reusable business component units in multiple business process tests.
·                     Ongoing test maintenance time and costs are reduced
·                     QA can take advantage of the sophisticated automated testing capabilities in QTP object hierarchies and application-specific functions that can be packaged as building blocks for use in BPT
·                     So, here the working partners are SME team and QA team
·                     Everything about functionalities are documented

Business Process Testing Model:


BPT is based on the creation and implementation of business components using Quality center Business Components module and Test Plan module.

How to create Business components in BPT:


Business components are easily-maintained, reusable units that perform a specific task, and are the building blocks of BPT  

For example, a Normal login Web page.  , 

login component’s are
Step 1: open the application.
Step 2: enter a user name.
Step 3: enter a password
Step 4: click the Submit button
Based on above steps, for Login web page Create business components in the Business Components module. You can use these components to build business process tests even before the application is ready for testing.

Before automated testing resources are available, you can add manual steps in the Design Steps tab of each component and you can run these steps using the Manual Runner.
After automated testing resources are ready, you can convert your manual components to automated components and begin implementing the automated steps for each component .Here observe the below snaps About Flight Reservation As sample App in QTP 



How to Create and Execute The Business process Tests
 Business Process Testing Framework creation and Execution in detail:

Here In Automation  process only two roles are presented one is Subject Matter Expert and second one is Automation Tester .this depends on companies .but sometime Automation Tester only will do both work.

The top-down methodology presented here for working with Business Process Testing comprises:

1.Design low level components :(identify the components)
Role: done by the SME
The top-down methodology presented here for working with Business Process Testing comprises 

2. High level design : Create structure for Business Process Tests
Role: done by both Subject Matter Expert (SME) and Automation Test Engineers (ATE)

3. The mid-level design
-- Creation of flows (sets of business components in a logical order that can be executed).
-- Creation of business components (reusable units that perform specific tasks in a business process).
--Specifying criteria for more granular test coverage (requirements) as necessary.
 --Specifying different test configurations for testing different use-cases and for more "true-to-life" test coverage (requirements).
Role: done by the SME

4.The low-level design :
The low-level implementation of business component content by creating component steps, setting up iterations (for business process tests, flows, and components), parameter zing  and when necessary,
Automating.
Role: The SME, the Automation Engineer, or both together, depend on available skills and resources.

The Execution of the business process tests:


The Business Process Tests contains >> business component flows or business components >>
Business components Contains steps




Test Plan Module :

     1. The SME first creates a business process test or flow in the Test Plan module. (Flow is a collection of business components in a fixed sequence that can be used as a unit in multiple business process tests. Flows Are available only in HP ALM / Quality Center.)

-- To populate the business process test or flow, the Subject Matter Expert then selects (drags and drops) the relevant components and configures their run settings.

2.  Each component can be used differently by different business process test configurations or flows.  For example, for each test configuration, the component can use different input parameter values or run a different number of iterations.

Business Components Module:

1.  Before automated testing resources are available, SME can define manual steps using the Business Components module. They can add these manual components to a business process test and run the steps manually using the HP ALM / Quality Center Manual Runner.

2. SME can add comments in the Business Components module. This enables them to enter any additional information or remarks that they want to communicate to you, the Automation Engineer, such as requests for new operations, future changes planned for the component, or alternative tests in which the component can be used.

3. Create individual Application Areas (Means A collection of resources and settings that are used for the creation and implementation of business components) for the various parts of your application based on real testing needs.

4. After creating the Application Areas and define its settings and resource files, the SME can incorporate these automated testing resources in business component steps, convert any existing manual components to automated components, and create new automated components.

Take a Look on the below image to understand the concepts

key elements:


1. Details:Provides a general summary of the component’s purpose or goals, and the condition of the application before and after a component is run (its pre-conditions and post-conditions). You can specify details and implementation requirements for the currently selected business component.

 2. Snapshot: Displays an image that provides a visual cue or description of the component’s purpose or operations. You can capture a snapshot image from the application and attach it to the currently selected business component.

3. Component Steps: Enables you to create or view the manual steps of your business component, and to automate it if required.

4. Parameters: Specifies the input and output component parameters and parameter values for the business component. This allows the component to receive data from an external source and to pass data to other components or flows.

5. Dependencies tab: displays a list of assets that are linked to the currently selected business component, enabling you to view the dependency relationships between components, tests, flows, and resources (including application areas).

6. History tab: Displays a log of changes made to the component.

7. Live Analysis tab: When a folder is selected, this tab is available for creating a graphical representation of data related to business components.

Example: use the Flight Reservation VB Application for implement the BPT framework


For Conduct Business Process Testing for above FA we need to create Business Components as shown below:
Each of these business components can be set up to receive specific elements of data from the test at the time of running the tests. (For ex: login name, password, no. of passengers, and credit card details).
The Same business process test can be used to run with the different set of data:
·                     Testing the Flight booking process for users with Different login permissions, such as new users, VIP customers, and so on.
·                     Testing the flight booking process for one itinerary, or for several itineraries.
·                     Testing the flight booking process for one passenger, or for several Passengers.
·                     Additionally, due to the modular structure of these business components and the ability to control components with external data, you can use the same components in other business process tests.
·                     For example, the login and logout components could be used in most other tests on the same application. You might also be able to use the component for entering shipping details in other business process tests that check, for example, the business process of ordering online merchandise from the application, or in a test for subscribing to a frequent flyer program.
  

Roles:

Two basic user roles are identified in the Business Process Testing model and referred to in this guide:
1. Subject Matter Expert
2. Automation Engineer

1.Subject Matter Expert (SME):

·                     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.
·                      Using the Business Components module, the Subject Matter Expert creates business components that describe the specific tasks that can be performed in the application, and the condition or state of the application before and after those tasks
·                     The Subject Matter Expert then defines the individual steps for each business component comprising the business process in the form of manual or non-automated steps.
·                     These manual steps can later be automated by defining them as keyword driven or Win Runner components and implementing the automated steps.
·                      Using the Test Plan module, the SME combines the business components into business process tests, composed of a serial flow of the components.
·                     The SME 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.
·                     The SME configures the values used for business process tests, runs them in test sets, and reviews the results. The SME is also responsible for maintaining the testing steps for each of the individual business components.

2. Automation Engineer:
·                     The AE is an expert in QTP Automated testing.
·                     The AE prepares the resources and automated functions required for testing the features associated with each specific component.
·                     For example, the AE populates the Shared Object Repository with objects that represent the different objects in the application being tested. The SME then uses these objects to create steps in keyword-driven business components.
·                     Automation Engineers can also create, debug, and modify business components in QTP

How QC Integration with QTP for Business process testing?

·          QTP connected to a QC project with BPT the Automation Engineer define objects in the object repository and save them in Quality Center. The objects are then available for insertion into component steps by the SME in Quality Center. In addition, all business component information is visible in QTP
·          Integration between the two applications enables the Subject Matter Expert to implement the testing steps for the business components in a keyword view, and also enables the Automation Engineer to effectively maintain the set of objects in the object repository and the operations in the function libraries.
·          QTP have two types of automated components; keyword-driven components and scripted components. The automated steps of keyword-driven components can be created and edited by the SME in Quality Center. Scripted component steps can be created and maintained only in QTP
·          The AE captures the Object Information, in above login webpage the captured OR as below 

v The AE covers the all activities and create function libraries. These function libraries Define the operations (or keywords) with keyword-driven components; the Subject Matter Expert can use these operations to create the component steps in the Business Components module in Quality Center.

v The OR and Function library of all objects placed in Application area (Application area contains all of the settings and resources of App)

v All application area settings are automatically inherited by the business components that are based on that application area

What we need to set up for BPT? :


Using QTP, the Automation Engineer defines an important set of resources and settings that comprise the application area or otherwise affect the business component.
These include:
1. Object Repositories
2. Function Libraries
3. Associated Add-ins
4. Applications List
5. Recovery Scenarios



1. Object Repositories: The object repository stores all the information about the test objects that are used in each business component. By using the same shared object repository file for multiple components, the same objects can be used in multiple components

2.     Function Libraries: Function libraries contain VBScript functions, subroutines, and so on, that can be used as operations in a business component

3.     Associate Add-ins: have add-ins to support Application Environment for example if Application in java, SAP, mainframe etc, for this platforms we need external add ins
(QTP default supports Active x, web, Visual Basic)  

4.      Applications List: QTP runs components only on the set of Windows-based applications
That is specified for the component. It can also run on applications in any other environment for which the appropriate QTP Add-in is loaded.

5.     Recovery Scenarios: Recovery scenarios are activated during the running of a business Component if an unexpected event occurs, such as an application crash, and the run is suspended. Recovery scenarios define the operation(s) necessary to recover from the event and continue the run.
·         The AE covers the all activities and create function libraries. These function libraries Define the operations (or keywords) with keyword-driven components; the Subject Matter Expert can use these operations to create the component steps in the Business Components module in Quality Center.

·         The OR and Function library of all objects placed in Application area (Application area contains all of the settings and resources of App)

·          All application area settings are automatically inherited by the business components that are based on that application area


No comments

Post a Comment