21
Automation Frameworks Don't Design, Let it Evolve Anand Ramdeo @testinggeek

W16 automation frameworks - anand ramdeo

Embed Size (px)

DESCRIPTION

EuroSTAR Software Testing Conference 2012 presentation on

Citation preview

Page 1: W16   automation frameworks - anand ramdeo

Automation Frameworks Don't Design, Let it Evolve

Anand Ramdeo

@testinggeek

Page 2: W16   automation frameworks - anand ramdeo

Problem Driven test automation framework

Page 3: W16   automation frameworks - anand ramdeo
Page 4: W16   automation frameworks - anand ramdeo

Sequential execution

Not easy to data drive

Firefox Plugin easy to install

Record & Playback

Easy execution

Help @ Hand

Export as WebDriver Script

Excellent First Step

No Basic Programming

constructs

Can not go beyond pages

Crawling is fun but we don’t crawl

anymore

Page 5: W16   automation frameworks - anand ramdeo

What happens when script is executed second time?

Page 6: W16   automation frameworks - anand ramdeo

Guaranteed Username

How would test respond to changes in GUI or business rules?

Page 7: W16   automation frameworks - anand ramdeo

Re

adab

le

Main

tainab

le

Difficult to Progress

Page 8: W16   automation frameworks - anand ramdeo

Decoupling Separatio

n o

f con

cerns

Ab

straction

Less friction, More development

Page 9: W16   automation frameworks - anand ramdeo

Page instead of elements

What if new fields are added?

Page 10: W16   automation frameworks - anand ramdeo

One place to find elements

Page Initializes everything

Functions applicable on elements are exposed by page

Page 11: W16   automation frameworks - anand ramdeo

Intelligent page objects

What if business decide to have multi page registration or multiple welcome pages?

Page 12: W16   automation frameworks - anand ramdeo

Test has no knowledge of physical implementation

What if business needs to capture more data?

Page 13: W16   automation frameworks - anand ramdeo

Domain objects & workflow

What if there are different types of users and difference channels of registration?

Page 14: W16   automation frameworks - anand ramdeo

Actor

Performs Work

Check Results

Same steps over and over again

Page 15: W16   automation frameworks - anand ramdeo

Randomization

Page 16: W16   automation frameworks - anand ramdeo

Power of Abstraction

User.registersOnSite()

- Choose a random path to reach at registration page.

- Generate random valid data based on the business rules for specific fields.

- Fill form in random order

- Choose a method to save form or send data using http

Page 17: W16   automation frameworks - anand ramdeo

Test is • Readable and maintainable. • Will not be affected by changes in the physical

implementation. • Will not be affected by changes in the business rules. • Can increase value of automation behind the scene • Was evolved by solving one problem at a time.

Page 18: W16   automation frameworks - anand ramdeo

Problem

Solved by performing work

On some interface

App solves the problem

Test proves That problem is solved

App allows actors to work

Test proves that actor can perform work

Page 19: W16   automation frameworks - anand ramdeo

Value Enhancer

Page 20: W16   automation frameworks - anand ramdeo
Page 21: W16   automation frameworks - anand ramdeo

Anand Ramdeo

@testinggeek