SlideShare a Scribd company logo
Automate Test, Tools, advantages,
and disadvantages
Majid Hosseini
Scala Developer @ ModernPal
www.linkedin.com/in/majidin
Agenda
● Introduction to test and
automation
● Test Engineer & QA Role
● Introduction to some test
automation tools
● Contract Testing
A QA engineer walks into a bar, and orders a beer
Then he orders 0 beers.
Then he orders 999999999999 beers.
Then he orders an aardvark.
Then he orders nothing.
Then he orders -1 beers.
Then he orders NULL beers.
Then he orders asnwikfjsdf.
Then he orders a
"><script>give_me_your_credit_card()</script>.
Finally, the QA engineer leaves without paying, comes back,
and asks for the tab.
More and more test....
Unit Test
Integration Test
end to end Test
e-2-e Test
UI Test
Acceptance Test
WhiteBox Test
BlackBox Test
Contract Test
Performance Test
Manual Test
GUI Test
High-level Test
Smoke Test
Load Test
Stress Test
Component Test
User Acceptance Test
Layout Test
Beta Test
Installation Test
Compatibility Test
Alpha Test
Regression Test
Functional Test
Non-functional Test
Destructive Test
Accessibility Test
Security Test
Ad-hoc Test
Agile Test
API Test
Backward compatibility Test
Branch Test
Exploratory Test
Fuzz Test
GlassBox Test
Gorilla Test!
Golden path testing
Interface Test
Happy path testing
Internationalization Test
Penetration Test Sanity Test
Scalability Test
Stability Test
System Test
Soak Test
Volume Testing
Vulnerability Test
Recovery Test
Unit Test:
“A Stack” should "throw NoSuchElementException if an empty stack is
popped" in {
val emptyStack = new Stack[String]
assertThrows[NoSuchElementException] {
emptyStack.pop()
}
}
Integration Test:
"Steering repository " should "find steerings by their ID" in {
Await.result(repository.add(testSteering), Duration.Inf)
Await.result(repository.add(testSteeringDifferentId), Duration.Inf)
val steering = Await.result(repository.findByKey(testSteeringId), Duration.Inf)
assert(steering.isDefined)
assert(steering.get.id === testSteering.id)
}
Test Level
Unit Test
Integration Test
High Level Test
High level Test:
"POST /steering_points" should
"Return 400 Badrequest error if name is empty string" in {
val req = baseSteeringPoint ++ Json.obj("name" -> "")
val response = Await.result(steeringPointsUrl.post(req), 5 second)
val result = Json.parse(response.body).asOpt[ErrorDTO]
assert(response.status == 400)
assert(result.isDefined)
}
High Level Test
• Simulate real user scenarios
• Verify the entire flow of the application
• Increase test coverage
Anti Pattern: Ice-Cream
Unit Test
● Fast
● Reliable
● Isolation Failures
● Easy Maintain
Test Pyramid
Keep in mind that all testing should be done
on the lowest level possible since
every step up the pyramid
makes tests more complex
and error prone.
Test for CI and CD (Production Pipeline)
Uncertainty in Test (Martin Fowler)
●
●
●
●
●
QA and Test Roles in Companies
● Separated “QA & Tester” Role
● No individual “QA & Tester” Role but SRE, DevOps and GOOD Product &
Development teams...
● Test & QA Designer
○ Comprehensive knowledge about the product and business domain
● Test Executor/Manager
○ Good knowledge of product and business domain
○ High ability to plan and being creative
○ Strong ability in investigation
○ Strong ability in communication and reporting
● Test Engineer
○ Front-end TE
○ Backend TE
○ Mobile TE
○ Specific TE: Security, Performance , ..
● Site Reliability Engineering
1. Describe behavior in plain text (Test Scenarios)
2. Implement scenario steps in a language
3. Run the scenarios
few rules to get a good scenario
✓ Use a proper @Tag to group related scenarios & execute them together >>>
Jenkins works with @Tags.
✓ Use non-technical terms in your scenario.
✓ Use only 1 when in each scenario.
Gherkin - simple syntax:
@{Tags}
Given for preconditions/testdata
When for steps/actions
Then for expectations/checks
{Data input}
Cucumber
1. Describe behaviour (test scenario) in plain text (Gherkin)
@priceUpload
Scenario: I want to test if uploading a file works
Given a file with name “myfile.csv”
When I upload the file
Then email is received
And the status will change to “SUCCESSFUL” in “10” seconds
2. Write a step definition in a programming language
Frontend Testing (Web)
Selenium WebDriver
1. Identify an element e.g. “text field 1”
2. Perform some action e.g. type “hello!” and Submit
3. Verify
● What WebDriver is able to:
○ interactions on the page (e.g. fill, click, submit, isElementPresent)
○ interactions with web browser e.g. add parameters, refresh, navigate back
○ JavaScript execution
● What WebDriver is not designed for:
○ layout testing ("should be green/have a border/..." is possible, but not maintainable)
○ js console output
Mobile Test
Android iOS e2e
Espresso KIF
EarlGrey
Appium
Calabash
Crowd Testing
Example: www.test.io
Performance Testing
What are we looking for?
SLOs/SLAs
Example of KPIs:
• Response time
• Throughput
Several tools exist, depends on your needs:
1. JMeter
2. Gatling
3. Apache Benchmark
Contract Testing
The consumer defines what it expects from a specific request to a service
The provider and the consumer agree on this contract
The provider continuously verifies that the contract is fulfilled
Pact A Contract Testing Framework

More Related Content

What's hot

Automation Frame works Instruction Sheet
Automation Frame works Instruction SheetAutomation Frame works Instruction Sheet
Automation Frame works Instruction Sheet
vodQA
 
An easy way to automate complex UI
An easy way to automate complex UIAn easy way to automate complex UI
An easy way to automate complex UI
Ivan Pashko
 
Behavior Driven Development (BDD) and Agile Testing
Behavior Driven Development (BDD) and Agile TestingBehavior Driven Development (BDD) and Agile Testing
Behavior Driven Development (BDD) and Agile Testingdversaci
 
Protractor: Tips & Tricks
Protractor: Tips & TricksProtractor: Tips & Tricks
Protractor: Tips & Tricks
Sergey Bolshchikov
 
Test Automation Framework with BDD and Cucumber
Test Automation Framework with BDD and CucumberTest Automation Framework with BDD and Cucumber
Test Automation Framework with BDD and Cucumber
Rhoynar Software Consulting
 
Brace yourself from automation death trap
Brace yourself from automation death trapBrace yourself from automation death trap
Brace yourself from automation death trap
Prasad Kalgutkar
 
Hp quick test professional 10
Hp quick test professional 10Hp quick test professional 10
Hp quick test professional 10
Sap Tao Bpt
 
BDD from QA side
BDD from QA sideBDD from QA side
BDD from QA side
Anton Shapin
 
Bdd – with cucumber and gherkin
Bdd – with cucumber and gherkinBdd – with cucumber and gherkin
Bdd – with cucumber and gherkin
Arati Joshi
 
Automated Testing in Angular Slides
Automated Testing in Angular SlidesAutomated Testing in Angular Slides
Automated Testing in Angular Slides
Jim Lynch
 
Introduction to Bdd and cucumber
Introduction to Bdd and cucumberIntroduction to Bdd and cucumber
Introduction to Bdd and cucumber
Nibu Baby
 
Introduction to SoapUI day 1
Introduction to SoapUI day 1Introduction to SoapUI day 1
Introduction to SoapUI day 1
Qualitest
 
Bdd and spec flow
Bdd and spec flowBdd and spec flow
Bdd and spec flow
Charles Nurse
 
What Is Cucumber?
What Is Cucumber?What Is Cucumber?
What Is Cucumber?
QATestLab
 
Principles and patterns for test driven development
Principles and patterns for test driven developmentPrinciples and patterns for test driven development
Principles and patterns for test driven development
Stephen Fuqua
 
Intro to junit
Intro to junitIntro to junit
Intro to junit
Rakesh Srivastava
 
Client-Side Performance Testing
Client-Side Performance TestingClient-Side Performance Testing
Client-Side Performance Testing
Anand Bagmar
 
Creating Maintainable Automated Acceptance Tests
Creating Maintainable Automated Acceptance TestsCreating Maintainable Automated Acceptance Tests
Creating Maintainable Automated Acceptance Tests
Jez Humble
 
Level Up Your Salesforce Unit Testing
Level Up Your Salesforce Unit TestingLevel Up Your Salesforce Unit Testing
Level Up Your Salesforce Unit Testing
Gordon Bockus
 

What's hot (20)

Automation Frame works Instruction Sheet
Automation Frame works Instruction SheetAutomation Frame works Instruction Sheet
Automation Frame works Instruction Sheet
 
An easy way to automate complex UI
An easy way to automate complex UIAn easy way to automate complex UI
An easy way to automate complex UI
 
Behavior Driven Development (BDD) and Agile Testing
Behavior Driven Development (BDD) and Agile TestingBehavior Driven Development (BDD) and Agile Testing
Behavior Driven Development (BDD) and Agile Testing
 
Protractor: Tips & Tricks
Protractor: Tips & TricksProtractor: Tips & Tricks
Protractor: Tips & Tricks
 
Test Automation Framework with BDD and Cucumber
Test Automation Framework with BDD and CucumberTest Automation Framework with BDD and Cucumber
Test Automation Framework with BDD and Cucumber
 
Jbehave selenium
Jbehave seleniumJbehave selenium
Jbehave selenium
 
Brace yourself from automation death trap
Brace yourself from automation death trapBrace yourself from automation death trap
Brace yourself from automation death trap
 
Hp quick test professional 10
Hp quick test professional 10Hp quick test professional 10
Hp quick test professional 10
 
BDD from QA side
BDD from QA sideBDD from QA side
BDD from QA side
 
Bdd – with cucumber and gherkin
Bdd – with cucumber and gherkinBdd – with cucumber and gherkin
Bdd – with cucumber and gherkin
 
Automated Testing in Angular Slides
Automated Testing in Angular SlidesAutomated Testing in Angular Slides
Automated Testing in Angular Slides
 
Introduction to Bdd and cucumber
Introduction to Bdd and cucumberIntroduction to Bdd and cucumber
Introduction to Bdd and cucumber
 
Introduction to SoapUI day 1
Introduction to SoapUI day 1Introduction to SoapUI day 1
Introduction to SoapUI day 1
 
Bdd and spec flow
Bdd and spec flowBdd and spec flow
Bdd and spec flow
 
What Is Cucumber?
What Is Cucumber?What Is Cucumber?
What Is Cucumber?
 
Principles and patterns for test driven development
Principles and patterns for test driven developmentPrinciples and patterns for test driven development
Principles and patterns for test driven development
 
Intro to junit
Intro to junitIntro to junit
Intro to junit
 
Client-Side Performance Testing
Client-Side Performance TestingClient-Side Performance Testing
Client-Side Performance Testing
 
Creating Maintainable Automated Acceptance Tests
Creating Maintainable Automated Acceptance TestsCreating Maintainable Automated Acceptance Tests
Creating Maintainable Automated Acceptance Tests
 
Level Up Your Salesforce Unit Testing
Level Up Your Salesforce Unit TestingLevel Up Your Salesforce Unit Testing
Level Up Your Salesforce Unit Testing
 

Similar to Automate test, tools, advantages, and disadvantages

Automated acceptance test
Automated acceptance testAutomated acceptance test
Automated acceptance test
Bryan Liu
 
Behavior Driven Development by Example
Behavior Driven Development by ExampleBehavior Driven Development by Example
Behavior Driven Development by Example
Nalin Goonawardana
 
Software Quality and Test Strategies for Ruby and Rails Applications
Software Quality and Test Strategies for Ruby and Rails ApplicationsSoftware Quality and Test Strategies for Ruby and Rails Applications
Software Quality and Test Strategies for Ruby and Rails Applications
Bhavin Javia
 
3 Ways to test your ColdFusion API - 2017 Adobe CF Summit
3 Ways to test your ColdFusion API - 2017 Adobe CF Summit3 Ways to test your ColdFusion API - 2017 Adobe CF Summit
3 Ways to test your ColdFusion API - 2017 Adobe CF Summit
Ortus Solutions, Corp
 
Developers Testing - Girl Code at bloomon
Developers Testing - Girl Code at bloomonDevelopers Testing - Girl Code at bloomon
Developers Testing - Girl Code at bloomon
Ineke Scheffers
 
Good practices for debugging Selenium and Appium tests
Good practices for debugging Selenium and Appium testsGood practices for debugging Selenium and Appium tests
Good practices for debugging Selenium and Appium tests
Abhijeet Vaikar
 
Testing for fun in production Into The Box 2018
Testing for fun in production Into The Box 2018Testing for fun in production Into The Box 2018
Testing for fun in production Into The Box 2018
Ortus Solutions, Corp
 
Token Testing Slides
Token  Testing SlidesToken  Testing Slides
Token Testing Slides
ericholscher
 
Testing of React JS app
Testing of React JS appTesting of React JS app
Testing of React JS app
Aleks Zinevych
 
North Virginia Coldfusion User Group Meetup - Testbox - July 19th 2017
North Virginia Coldfusion User Group Meetup - Testbox - July 19th 2017North Virginia Coldfusion User Group Meetup - Testbox - July 19th 2017
North Virginia Coldfusion User Group Meetup - Testbox - July 19th 2017
Ortus Solutions, Corp
 
Smart acceptance GUI tests with Selenium
Smart acceptance GUI tests with SeleniumSmart acceptance GUI tests with Selenium
Smart acceptance GUI tests with SeleniumDenys Zaiats
 
Karim Fanadka
Karim FanadkaKarim Fanadka
Karim Fanadka
CodeFest
 
Lightning Talks by Globant - Automation (This app runs by itself )
Lightning Talks by Globant -  Automation (This app runs by itself ) Lightning Talks by Globant -  Automation (This app runs by itself )
Lightning Talks by Globant - Automation (This app runs by itself )
Globant
 
Escaping Test Hell - ACCU 2014
Escaping Test Hell - ACCU 2014Escaping Test Hell - ACCU 2014
Escaping Test Hell - ACCU 2014
Wojciech Seliga
 
Test Automation Frameworks Final
Test Automation Frameworks   FinalTest Automation Frameworks   Final
Test Automation Frameworks Final
Margaret_Dickman
 
Никита Галкин "Testing in Frontend World"
Никита Галкин "Testing in Frontend World"Никита Галкин "Testing in Frontend World"
Никита Галкин "Testing in Frontend World"
Fwdays
 
Selenium
SeleniumSelenium
Automation Testing on Selenium by Quontra Solutions
Automation Testing on Selenium by Quontra SolutionsAutomation Testing on Selenium by Quontra Solutions
Automation Testing on Selenium by Quontra Solutions
QUONTRASOLUTIONS
 

Similar to Automate test, tools, advantages, and disadvantages (20)

Automated acceptance test
Automated acceptance testAutomated acceptance test
Automated acceptance test
 
Behavior Driven Development by Example
Behavior Driven Development by ExampleBehavior Driven Development by Example
Behavior Driven Development by Example
 
Software Quality and Test Strategies for Ruby and Rails Applications
Software Quality and Test Strategies for Ruby and Rails ApplicationsSoftware Quality and Test Strategies for Ruby and Rails Applications
Software Quality and Test Strategies for Ruby and Rails Applications
 
3 Ways to test your ColdFusion API - 2017 Adobe CF Summit
3 Ways to test your ColdFusion API - 2017 Adobe CF Summit3 Ways to test your ColdFusion API - 2017 Adobe CF Summit
3 Ways to test your ColdFusion API - 2017 Adobe CF Summit
 
Developers Testing - Girl Code at bloomon
Developers Testing - Girl Code at bloomonDevelopers Testing - Girl Code at bloomon
Developers Testing - Girl Code at bloomon
 
MyPresentation2
MyPresentation2MyPresentation2
MyPresentation2
 
Good practices for debugging Selenium and Appium tests
Good practices for debugging Selenium and Appium testsGood practices for debugging Selenium and Appium tests
Good practices for debugging Selenium and Appium tests
 
Testing for fun in production Into The Box 2018
Testing for fun in production Into The Box 2018Testing for fun in production Into The Box 2018
Testing for fun in production Into The Box 2018
 
Token Testing Slides
Token  Testing SlidesToken  Testing Slides
Token Testing Slides
 
Sanjay Sharma
Sanjay SharmaSanjay Sharma
Sanjay Sharma
 
Testing of React JS app
Testing of React JS appTesting of React JS app
Testing of React JS app
 
North Virginia Coldfusion User Group Meetup - Testbox - July 19th 2017
North Virginia Coldfusion User Group Meetup - Testbox - July 19th 2017North Virginia Coldfusion User Group Meetup - Testbox - July 19th 2017
North Virginia Coldfusion User Group Meetup - Testbox - July 19th 2017
 
Smart acceptance GUI tests with Selenium
Smart acceptance GUI tests with SeleniumSmart acceptance GUI tests with Selenium
Smart acceptance GUI tests with Selenium
 
Karim Fanadka
Karim FanadkaKarim Fanadka
Karim Fanadka
 
Lightning Talks by Globant - Automation (This app runs by itself )
Lightning Talks by Globant -  Automation (This app runs by itself ) Lightning Talks by Globant -  Automation (This app runs by itself )
Lightning Talks by Globant - Automation (This app runs by itself )
 
Escaping Test Hell - ACCU 2014
Escaping Test Hell - ACCU 2014Escaping Test Hell - ACCU 2014
Escaping Test Hell - ACCU 2014
 
Test Automation Frameworks Final
Test Automation Frameworks   FinalTest Automation Frameworks   Final
Test Automation Frameworks Final
 
Никита Галкин "Testing in Frontend World"
Никита Галкин "Testing in Frontend World"Никита Галкин "Testing in Frontend World"
Никита Галкин "Testing in Frontend World"
 
Selenium
SeleniumSelenium
Selenium
 
Automation Testing on Selenium by Quontra Solutions
Automation Testing on Selenium by Quontra SolutionsAutomation Testing on Selenium by Quontra Solutions
Automation Testing on Selenium by Quontra Solutions
 

Recently uploaded

Understanding Globus Data Transfers with NetSage
Understanding Globus Data Transfers with NetSageUnderstanding Globus Data Transfers with NetSage
Understanding Globus Data Transfers with NetSage
Globus
 
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.ILBeyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
Natan Silnitsky
 
Corporate Management | Session 3 of 3 | Tendenci AMS
Corporate Management | Session 3 of 3 | Tendenci AMSCorporate Management | Session 3 of 3 | Tendenci AMS
Corporate Management | Session 3 of 3 | Tendenci AMS
Tendenci - The Open Source AMS (Association Management Software)
 
Developing Distributed High-performance Computing Capabilities of an Open Sci...
Developing Distributed High-performance Computing Capabilities of an Open Sci...Developing Distributed High-performance Computing Capabilities of an Open Sci...
Developing Distributed High-performance Computing Capabilities of an Open Sci...
Globus
 
Cyaniclab : Software Development Agency Portfolio.pdf
Cyaniclab : Software Development Agency Portfolio.pdfCyaniclab : Software Development Agency Portfolio.pdf
Cyaniclab : Software Development Agency Portfolio.pdf
Cyanic lab
 
May Marketo Masterclass, London MUG May 22 2024.pdf
May Marketo Masterclass, London MUG May 22 2024.pdfMay Marketo Masterclass, London MUG May 22 2024.pdf
May Marketo Masterclass, London MUG May 22 2024.pdf
Adele Miller
 
How Recreation Management Software Can Streamline Your Operations.pptx
How Recreation Management Software Can Streamline Your Operations.pptxHow Recreation Management Software Can Streamline Your Operations.pptx
How Recreation Management Software Can Streamline Your Operations.pptx
wottaspaceseo
 
Enhancing Project Management Efficiency_ Leveraging AI Tools like ChatGPT.pdf
Enhancing Project Management Efficiency_ Leveraging AI Tools like ChatGPT.pdfEnhancing Project Management Efficiency_ Leveraging AI Tools like ChatGPT.pdf
Enhancing Project Management Efficiency_ Leveraging AI Tools like ChatGPT.pdf
Jay Das
 
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptx
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptxTop Features to Include in Your Winzo Clone App for Business Growth (4).pptx
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptx
rickgrimesss22
 
Quarkus Hidden and Forbidden Extensions
Quarkus Hidden and Forbidden ExtensionsQuarkus Hidden and Forbidden Extensions
Quarkus Hidden and Forbidden Extensions
Max Andersen
 
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...
Juraj Vysvader
 
Orion Context Broker introduction 20240604
Orion Context Broker introduction 20240604Orion Context Broker introduction 20240604
Orion Context Broker introduction 20240604
Fermin Galan
 
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERRORTROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
Tier1 app
 
How to Position Your Globus Data Portal for Success Ten Good Practices
How to Position Your Globus Data Portal for Success Ten Good PracticesHow to Position Your Globus Data Portal for Success Ten Good Practices
How to Position Your Globus Data Portal for Success Ten Good Practices
Globus
 
Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...
Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...
Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...
Globus
 
A Sighting of filterA in Typelevel Rite of Passage
A Sighting of filterA in Typelevel Rite of PassageA Sighting of filterA in Typelevel Rite of Passage
A Sighting of filterA in Typelevel Rite of Passage
Philip Schwarz
 
Climate Science Flows: Enabling Petabyte-Scale Climate Analysis with the Eart...
Climate Science Flows: Enabling Petabyte-Scale Climate Analysis with the Eart...Climate Science Flows: Enabling Petabyte-Scale Climate Analysis with the Eart...
Climate Science Flows: Enabling Petabyte-Scale Climate Analysis with the Eart...
Globus
 
Navigating the Metaverse: A Journey into Virtual Evolution"
Navigating the Metaverse: A Journey into Virtual Evolution"Navigating the Metaverse: A Journey into Virtual Evolution"
Navigating the Metaverse: A Journey into Virtual Evolution"
Donna Lenk
 
Into the Box 2024 - Keynote Day 2 Slides.pdf
Into the Box 2024 - Keynote Day 2 Slides.pdfInto the Box 2024 - Keynote Day 2 Slides.pdf
Into the Box 2024 - Keynote Day 2 Slides.pdf
Ortus Solutions, Corp
 
Prosigns: Transforming Business with Tailored Technology Solutions
Prosigns: Transforming Business with Tailored Technology SolutionsProsigns: Transforming Business with Tailored Technology Solutions
Prosigns: Transforming Business with Tailored Technology Solutions
Prosigns
 

Recently uploaded (20)

Understanding Globus Data Transfers with NetSage
Understanding Globus Data Transfers with NetSageUnderstanding Globus Data Transfers with NetSage
Understanding Globus Data Transfers with NetSage
 
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.ILBeyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
Beyond Event Sourcing - Embracing CRUD for Wix Platform - Java.IL
 
Corporate Management | Session 3 of 3 | Tendenci AMS
Corporate Management | Session 3 of 3 | Tendenci AMSCorporate Management | Session 3 of 3 | Tendenci AMS
Corporate Management | Session 3 of 3 | Tendenci AMS
 
Developing Distributed High-performance Computing Capabilities of an Open Sci...
Developing Distributed High-performance Computing Capabilities of an Open Sci...Developing Distributed High-performance Computing Capabilities of an Open Sci...
Developing Distributed High-performance Computing Capabilities of an Open Sci...
 
Cyaniclab : Software Development Agency Portfolio.pdf
Cyaniclab : Software Development Agency Portfolio.pdfCyaniclab : Software Development Agency Portfolio.pdf
Cyaniclab : Software Development Agency Portfolio.pdf
 
May Marketo Masterclass, London MUG May 22 2024.pdf
May Marketo Masterclass, London MUG May 22 2024.pdfMay Marketo Masterclass, London MUG May 22 2024.pdf
May Marketo Masterclass, London MUG May 22 2024.pdf
 
How Recreation Management Software Can Streamline Your Operations.pptx
How Recreation Management Software Can Streamline Your Operations.pptxHow Recreation Management Software Can Streamline Your Operations.pptx
How Recreation Management Software Can Streamline Your Operations.pptx
 
Enhancing Project Management Efficiency_ Leveraging AI Tools like ChatGPT.pdf
Enhancing Project Management Efficiency_ Leveraging AI Tools like ChatGPT.pdfEnhancing Project Management Efficiency_ Leveraging AI Tools like ChatGPT.pdf
Enhancing Project Management Efficiency_ Leveraging AI Tools like ChatGPT.pdf
 
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptx
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptxTop Features to Include in Your Winzo Clone App for Business Growth (4).pptx
Top Features to Include in Your Winzo Clone App for Business Growth (4).pptx
 
Quarkus Hidden and Forbidden Extensions
Quarkus Hidden and Forbidden ExtensionsQuarkus Hidden and Forbidden Extensions
Quarkus Hidden and Forbidden Extensions
 
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...
In 2015, I used to write extensions for Joomla, WordPress, phpBB3, etc and I ...
 
Orion Context Broker introduction 20240604
Orion Context Broker introduction 20240604Orion Context Broker introduction 20240604
Orion Context Broker introduction 20240604
 
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERRORTROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
 
How to Position Your Globus Data Portal for Success Ten Good Practices
How to Position Your Globus Data Portal for Success Ten Good PracticesHow to Position Your Globus Data Portal for Success Ten Good Practices
How to Position Your Globus Data Portal for Success Ten Good Practices
 
Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...
Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...
Exploring Innovations in Data Repository Solutions - Insights from the U.S. G...
 
A Sighting of filterA in Typelevel Rite of Passage
A Sighting of filterA in Typelevel Rite of PassageA Sighting of filterA in Typelevel Rite of Passage
A Sighting of filterA in Typelevel Rite of Passage
 
Climate Science Flows: Enabling Petabyte-Scale Climate Analysis with the Eart...
Climate Science Flows: Enabling Petabyte-Scale Climate Analysis with the Eart...Climate Science Flows: Enabling Petabyte-Scale Climate Analysis with the Eart...
Climate Science Flows: Enabling Petabyte-Scale Climate Analysis with the Eart...
 
Navigating the Metaverse: A Journey into Virtual Evolution"
Navigating the Metaverse: A Journey into Virtual Evolution"Navigating the Metaverse: A Journey into Virtual Evolution"
Navigating the Metaverse: A Journey into Virtual Evolution"
 
Into the Box 2024 - Keynote Day 2 Slides.pdf
Into the Box 2024 - Keynote Day 2 Slides.pdfInto the Box 2024 - Keynote Day 2 Slides.pdf
Into the Box 2024 - Keynote Day 2 Slides.pdf
 
Prosigns: Transforming Business with Tailored Technology Solutions
Prosigns: Transforming Business with Tailored Technology SolutionsProsigns: Transforming Business with Tailored Technology Solutions
Prosigns: Transforming Business with Tailored Technology Solutions
 

Automate test, tools, advantages, and disadvantages

  • 1. Automate Test, Tools, advantages, and disadvantages Majid Hosseini Scala Developer @ ModernPal www.linkedin.com/in/majidin
  • 2. Agenda ● Introduction to test and automation ● Test Engineer & QA Role ● Introduction to some test automation tools ● Contract Testing A QA engineer walks into a bar, and orders a beer Then he orders 0 beers. Then he orders 999999999999 beers. Then he orders an aardvark. Then he orders nothing. Then he orders -1 beers. Then he orders NULL beers. Then he orders asnwikfjsdf. Then he orders a "><script>give_me_your_credit_card()</script>. Finally, the QA engineer leaves without paying, comes back, and asks for the tab.
  • 3. More and more test.... Unit Test Integration Test end to end Test e-2-e Test UI Test Acceptance Test WhiteBox Test BlackBox Test Contract Test Performance Test Manual Test GUI Test High-level Test Smoke Test Load Test Stress Test Component Test User Acceptance Test Layout Test Beta Test Installation Test Compatibility Test Alpha Test Regression Test Functional Test Non-functional Test Destructive Test Accessibility Test Security Test Ad-hoc Test Agile Test API Test Backward compatibility Test Branch Test Exploratory Test Fuzz Test GlassBox Test Gorilla Test! Golden path testing Interface Test Happy path testing Internationalization Test Penetration Test Sanity Test Scalability Test Stability Test System Test Soak Test Volume Testing Vulnerability Test Recovery Test
  • 4. Unit Test: “A Stack” should "throw NoSuchElementException if an empty stack is popped" in { val emptyStack = new Stack[String] assertThrows[NoSuchElementException] { emptyStack.pop() } } Integration Test: "Steering repository " should "find steerings by their ID" in { Await.result(repository.add(testSteering), Duration.Inf) Await.result(repository.add(testSteeringDifferentId), Duration.Inf) val steering = Await.result(repository.findByKey(testSteeringId), Duration.Inf) assert(steering.isDefined) assert(steering.get.id === testSteering.id) } Test Level Unit Test Integration Test High Level Test High level Test: "POST /steering_points" should "Return 400 Badrequest error if name is empty string" in { val req = baseSteeringPoint ++ Json.obj("name" -> "") val response = Await.result(steeringPointsUrl.post(req), 5 second) val result = Json.parse(response.body).asOpt[ErrorDTO] assert(response.status == 400) assert(result.isDefined) }
  • 5. High Level Test • Simulate real user scenarios • Verify the entire flow of the application • Increase test coverage
  • 7. Unit Test ● Fast ● Reliable ● Isolation Failures ● Easy Maintain
  • 8. Test Pyramid Keep in mind that all testing should be done on the lowest level possible since every step up the pyramid makes tests more complex and error prone.
  • 9. Test for CI and CD (Production Pipeline)
  • 10. Uncertainty in Test (Martin Fowler) ● ● ● ● ●
  • 11. QA and Test Roles in Companies ● Separated “QA & Tester” Role ● No individual “QA & Tester” Role but SRE, DevOps and GOOD Product & Development teams...
  • 12. ● Test & QA Designer ○ Comprehensive knowledge about the product and business domain ● Test Executor/Manager ○ Good knowledge of product and business domain ○ High ability to plan and being creative ○ Strong ability in investigation ○ Strong ability in communication and reporting ● Test Engineer ○ Front-end TE ○ Backend TE ○ Mobile TE ○ Specific TE: Security, Performance , .. ● Site Reliability Engineering
  • 13. 1. Describe behavior in plain text (Test Scenarios) 2. Implement scenario steps in a language 3. Run the scenarios
  • 14. few rules to get a good scenario ✓ Use a proper @Tag to group related scenarios & execute them together >>> Jenkins works with @Tags. ✓ Use non-technical terms in your scenario. ✓ Use only 1 when in each scenario. Gherkin - simple syntax: @{Tags} Given for preconditions/testdata When for steps/actions Then for expectations/checks {Data input}
  • 15. Cucumber 1. Describe behaviour (test scenario) in plain text (Gherkin) @priceUpload Scenario: I want to test if uploading a file works Given a file with name “myfile.csv” When I upload the file Then email is received And the status will change to “SUCCESSFUL” in “10” seconds 2. Write a step definition in a programming language
  • 16. Frontend Testing (Web) Selenium WebDriver 1. Identify an element e.g. “text field 1” 2. Perform some action e.g. type “hello!” and Submit 3. Verify ● What WebDriver is able to: ○ interactions on the page (e.g. fill, click, submit, isElementPresent) ○ interactions with web browser e.g. add parameters, refresh, navigate back ○ JavaScript execution ● What WebDriver is not designed for: ○ layout testing ("should be green/have a border/..." is possible, but not maintainable) ○ js console output
  • 17. Mobile Test Android iOS e2e Espresso KIF EarlGrey Appium Calabash
  • 19. Performance Testing What are we looking for? SLOs/SLAs Example of KPIs: • Response time • Throughput Several tools exist, depends on your needs: 1. JMeter 2. Gatling 3. Apache Benchmark
  • 20. Contract Testing The consumer defines what it expects from a specific request to a service The provider and the consumer agree on this contract The provider continuously verifies that the contract is fulfilled
  • 21. Pact A Contract Testing Framework