ui test automation - maximizing roi by minimizing maintenance costs

14
UI Test Automation Maximizing ROI by Minimizing Maintenance Costs JIM SIBLEY QA AUTOMATION ARCHITECT

Upload: jim-sibley

Post on 23-Jan-2018

114 views

Category:

Software


4 download

TRANSCRIPT

Page 1: UI Test Automation - Maximizing ROI by Minimizing Maintenance Costs

UI Test Automation

Maximizing ROIby

Minimizing Maintenance Costs

J IM SIBLEYQA AUTOMATION ARCHITECT

Page 2: UI Test Automation - Maximizing ROI by Minimizing Maintenance Costs

UI Test Automation Basics

What is the primary objective?

Identify relevant bugs in the application under test (AUT)

What is a relevant bug?

A bug that has the potential to affect a real user

How can UI test automation accomplish this objective?

Run tests against a release build of the AUT

Interact with the UI in the same way a real user does

Page 3: UI Test Automation - Maximizing ROI by Minimizing Maintenance Costs

Interacting with the AUT

Observe the application’s behavior

• What objects are displayed?

• What are the visible attributes of an object?

• What are the responses to user input?

Perform User Input

• UI Gestures: Click/Tap, Drag and Drop, Scroll/Swipe, Right-Click/Hold, Pinch

• Other: Keyboard (physical or on-screen), Rotate/Resize Screen, Shake

What do these all of these things have in common?

Page 4: UI Test Automation - Maximizing ROI by Minimizing Maintenance Costs

Independent Automation Framework

Shared across multiple automation projects

Includes all capabilities that are independent of the AUT

Mechanisms for consistent user-based interactions

Execution artifacts: Results, Detailed Logs, Error/Failure data

Integration with business systems: CI, Email, DB, Test Management

Reading and writing various types of data: JSON, XML, Excel

Front-end test options: Data-Driven, BDD, test categories

Test client platform: OS, Device Type, Web vs. App

Page 5: UI Test Automation - Maximizing ROI by Minimizing Maintenance Costs

Page - Step - Test Architecture

Extension of the Page-Object model

The Step layer sits between the Page and the Test layers

PageDeclares objects and methods for interacting with them

StepDefines a user focussed transaction within the AUT

Test Specifies a scenario or use case to be tested

Page 6: UI Test Automation - Maximizing ROI by Minimizing Maintenance Costs

What is a Page?

A page describes a subset of the AUT that contains a functionally-related set of objects with which the user may interact or observe.

Declares a list of objects and a unique locator for each object.

Defines methods used to observe or interact with declared objects.

Page 7: UI Test Automation - Maximizing ROI by Minimizing Maintenance Costs

Example Page …

Page 8: UI Test Automation - Maximizing ROI by Minimizing Maintenance Costs

What is a Step?

A transaction performed by the end-user while using the AUT

Will first determine if the requested transaction is needed

Will perform any required prerequisite Steps (if needed)

May include basic synchronization and validation logic

Allows for much simpler Pages and Tests

Page 9: UI Test Automation - Maximizing ROI by Minimizing Maintenance Costs

Example Steps …

LoginAs – Login to the AUT with the given credentials

If requested user is already logged in, do nothing

If a different user is already logged in, logout first

RegisterNewUser – Register a new user account

AddPaymentMethod – Add a new payment method to account

Logout – Sign out from the AUT

If no user is currently logged in, do nothing

Page 10: UI Test Automation - Maximizing ROI by Minimizing Maintenance Costs

What is a Test?

A series of Steps and Verifications

Specify only the steps relevant to each specific test case

Independent of each other… can be run individually or in any order

Can be data driven

Can often be shared across different AUTs

Can be easily grouped or categorized to run in different suites

Page 11: UI Test Automation - Maximizing ROI by Minimizing Maintenance Costs

Example Tests …

Page 12: UI Test Automation - Maximizing ROI by Minimizing Maintenance Costs

Continuous Integration

Run your test automatically against each new build or deployment

Use CI to regularly test the automation itself

Spot trends or problematic areas

Track down intermittent failures

Identify differences between test environments

Page 13: UI Test Automation - Maximizing ROI by Minimizing Maintenance Costs

Test Execution Artifacts

Create test results that are easy to interpret

Create artifacts that allow for quick and easy debugging of any errors or failures

Store/Archive result (automatically) from any 'official' test execution

Track and analyze results from ALL executions of automation

Test execution artifacts...

Create and organize artifacts to convey varying levels of details

Allow different audiences to easily see the information they care about

Flag known issues to reduce duplication of efforts when analyzing results

Page 14: UI Test Automation - Maximizing ROI by Minimizing Maintenance Costs

Maximizing the Value of Automated Tests

• Tests continue to run from build to build, and release to release

• Robust tests that produce Repeatable and Accurate test results

• Continuously work towards reducing execution times

• Event-driven synchronization

• Minimize duplicate actions across test cases

• Create intelligent test steps