BDD and Test Automation Tech Talk - Atlogys Academy Series

16

Click here to load reader

Transcript of BDD and Test Automation Tech Talk - Atlogys Academy Series

Page 1: BDD and Test Automation Tech Talk - Atlogys Academy Series

Lleavr

Behavior Driven Development (BDD)

And Test Automation

Presented By Kishor Jyoti Sarma

QA Engineer , ATOLGYS

Copyright 2017 Automated Logical Software (P) Ltd.

Page 2: BDD and Test Automation Tech Talk - Atlogys Academy Series

Agenda

o What is Automation?

o Need for Test Automation.

o Behavior Driven Development.

o Test Automation Using BDD.

o Frameworks like JBehave .

o Demo

o Q & A

Copyright 2017 Automated Logical Software (P) Ltd.

Page 3: BDD and Test Automation Tech Talk - Atlogys Academy Series

What is Automation?

Is Manual Testing Dead? No

Is Manual Tester(Pure Black Box Tester) Dead? In future Yes

In a decade or two manual work will be taken over by machine learning, image processing algorithms, Computer vision , Deep learning algorithms, Sensor fusion AI etc.

Some Real life examples

Copyright 2017 Automated Logical Software (P) Ltd.

Page 4: BDD and Test Automation Tech Talk - Atlogys Academy Series

Applitools Eyes

https://applitools.com/about-us/

Copyright 2017 Automated Logical Software (P) Ltd.

Page 5: BDD and Test Automation Tech Talk - Atlogys Academy Series

Amazon Go

o Amazon has described Amazon Go as "a new kind of store with no checkout required". That means, when you shop at Amazon Go, you'll never have to wait in line.

o Watch the video here :

https://www.amazon.com/b?node=16008589011

Copyright 2017 Automated Logical Software (P) Ltd.

Page 6: BDD and Test Automation Tech Talk - Atlogys Academy Series

Need for Test Automation

Saves time and money.

Reduce redundant work done.

Faster regression testing.

More code coverage.

Test your software with a huge set of data as well as user.

Continuous Integration to bridge the gap between testing and development.

Copyright 2017 Automated Logical Software (P) Ltd.

Page 7: BDD and Test Automation Tech Talk - Atlogys Academy Series

There are several different types of software tests that can be automated.

Unit Testing

Integration Testing

Functional Testing

Black Box testing

Regression Testing

Smoke Testing

Copyright 2017 Automated Logical Software (P) Ltd.

Page 8: BDD and Test Automation Tech Talk - Atlogys Academy Series

Behaviour Driven Development

BDD is better than TDD.

BDD increases user interaction.

Test cases are replaced by simple story file and any one can edit , update or write new story.

A sample story :

Copyright 2017 Automated Logical Software (P) Ltd.

Page 9: BDD and Test Automation Tech Talk - Atlogys Academy Series

JBehave

JBehave is a framework for Behavior-Driven Development (BDD).

Written in Java.

Can be use as a maven dependency .

JBehave has its own grammar based on which we can create a our own common language that can be understand by Dev, BA , Testers, PM etc.

Copyright 2017 Automated Logical Software (P) Ltd.

Page 10: BDD and Test Automation Tech Talk - Atlogys Academy Series

BDD Using JBehave

Step 1 - Story:

Step 2-Mapping to POJO :

Copyright 2017 Automated Logical Software (P) Ltd.

Page 11: BDD and Test Automation Tech Talk - Atlogys Academy Series

Test Automation Using BDD

Copyright 2017 Automated Logical Software (P) Ltd.

Page 12: BDD and Test Automation Tech Talk - Atlogys Academy Series

Copyright 2017 Automated Logical Software (P) Ltd.

Step-3 Write the business logic:

Page 13: BDD and Test Automation Tech Talk - Atlogys Academy Series

Step-4 : Configure Stories

Copyright 2017 Automated Logical Software (P) Ltd.

Page 14: BDD and Test Automation Tech Talk - Atlogys Academy Series

Step-5: Run Stories

Copyright 2017 Automated Logical Software (P) Ltd.

Page 15: BDD and Test Automation Tech Talk - Atlogys Academy Series

Demo

A Sample Application

Given an empty Stack

When I push item ‘orange’

Then count should be 1

Trellis BDD Framework

Copyright 2017 Automated Logical Software (P) Ltd.

Page 16: BDD and Test Automation Tech Talk - Atlogys Academy Series

References : http://jbehave.org/

smartbear.com

http://docs.oracle.com/javase/8/

Copyright 2017 Automated Logical Software (P) Ltd.

Thank YouThank You