SlideShare a Scribd company logo
1 of 8
Download to read offline
Regression Testing with Symfony
Tools and techniques for building your test suite
Part 2: Utilizing the tools

 Functional tests with the BehatBundle
 Components of the MinkBundle
 Selection of Browser Drivers
    Zombie JS Driver
    Sahi Driver
BDD Test Specification


    Scenario: Put item in shopping cart
    Given the case, the customer wants to buy a movie
       And his shopping cart is empty
       And there are 2 movies in stock
    When he puts the item in the shopping cart
    Then the item should show up in the shopping cart
       And the shopping cart counter should show 1
       And 1 movie should be in stock
Gherkin Language


 Formal language to define functional tests
 Entry points using defined keywords
    Feature: Set of functional test for a specific domain
    Background: Steps that will be executed for each scenario
    Scenario: Steps to test a certain behaviour
Gherkin Language


 Keywords for step definitions
      Given: Pre-condition for the scenario
      When: Action/Operation to perform
      Then: Test for expected result
      And: Chaining of step definitions
Behat + Bundle

   BehatBundle integrates Behat in Symfony
   Setup of kernel
   Access to DIC
   Mapping of Gherkin
   Located in own directory structure
     .feature file to define step definitions
     FeatureContext to match the steps
Mink + Bundle

 MinkBundle integrates Mink into Symfony
 Encapsulation of various browser drives
     GoutteDriver: headless pure-php driver
     SahiDriver: JS browser driver with GUI installer
     ZombieDriver: Bridge for Zombie.js browser emulator
     SeleniumDriver: Bridge to Selenium
 FeatureContext for common browser operations
 Setup of application kernel
Thank you for your attiontion!

More Related Content

What's hot

Planning & building scalable test infrastructure
Planning  & building scalable test infrastructurePlanning  & building scalable test infrastructure
Planning & building scalable test infrastructure
Vijayan Reddy
 
Deepak_Resume_Automation
Deepak_Resume_AutomationDeepak_Resume_Automation
Deepak_Resume_Automation
Deepak Pandey
 
Programming skills for test automation
Programming skills for test automationProgramming skills for test automation
Programming skills for test automation
Romania Testing
 
Enhanced Verification Flow with Nextop's Assertion Synthesis Technology
Enhanced Verification Flow with Nextop's Assertion Synthesis TechnologyEnhanced Verification Flow with Nextop's Assertion Synthesis Technology
Enhanced Verification Flow with Nextop's Assertion Synthesis Technology
DVClub
 
Testing Tool Evaluation Criteria
Testing Tool Evaluation CriteriaTesting Tool Evaluation Criteria
Testing Tool Evaluation Criteria
basma_iti_1984
 
Automation testing IBM RFT - Rational Functional Tester
Automation testing IBM RFT - Rational Functional TesterAutomation testing IBM RFT - Rational Functional Tester
Automation testing IBM RFT - Rational Functional Tester
VijayChowthri Nagaprakasham
 

What's hot (20)

Automated Testing vs Manual Testing
Automated Testing vs Manual TestingAutomated Testing vs Manual Testing
Automated Testing vs Manual Testing
 
Planning & building scalable test infrastructure
Planning  & building scalable test infrastructurePlanning  & building scalable test infrastructure
Planning & building scalable test infrastructure
 
Continuous Testing With Terraform
Continuous Testing With TerraformContinuous Testing With Terraform
Continuous Testing With Terraform
 
Software testing tools (free and open source)
Software testing tools (free and open source)Software testing tools (free and open source)
Software testing tools (free and open source)
 
Deepak_Resume_Automation
Deepak_Resume_AutomationDeepak_Resume_Automation
Deepak_Resume_Automation
 
Continuous Integration to Shift Left Testing Across the Enterprise Stack
Continuous Integration to Shift Left Testing Across the Enterprise StackContinuous Integration to Shift Left Testing Across the Enterprise Stack
Continuous Integration to Shift Left Testing Across the Enterprise Stack
 
Automation testing by Durgasoft in Hyderabad
Automation testing by Durgasoft in HyderabadAutomation testing by Durgasoft in Hyderabad
Automation testing by Durgasoft in Hyderabad
 
Testing
TestingTesting
Testing
 
ABAP Code Retreat Frankfurt 2016: TDD - Test Driven Development
ABAP Code Retreat Frankfurt 2016: TDD - Test Driven DevelopmentABAP Code Retreat Frankfurt 2016: TDD - Test Driven Development
ABAP Code Retreat Frankfurt 2016: TDD - Test Driven Development
 
Programming skills for test automation
Programming skills for test automationProgramming skills for test automation
Programming skills for test automation
 
Back to basics - PHPUnit
Back to basics - PHPUnitBack to basics - PHPUnit
Back to basics - PHPUnit
 
Parasoft fda software compliance part2
Parasoft fda software compliance   part2Parasoft fda software compliance   part2
Parasoft fda software compliance part2
 
Enhanced Verification Flow with Nextop's Assertion Synthesis Technology
Enhanced Verification Flow with Nextop's Assertion Synthesis TechnologyEnhanced Verification Flow with Nextop's Assertion Synthesis Technology
Enhanced Verification Flow with Nextop's Assertion Synthesis Technology
 
Testing Tool Evaluation Criteria
Testing Tool Evaluation CriteriaTesting Tool Evaluation Criteria
Testing Tool Evaluation Criteria
 
Automation testing material by Durgasoft,hyderabad
Automation testing material by Durgasoft,hyderabadAutomation testing material by Durgasoft,hyderabad
Automation testing material by Durgasoft,hyderabad
 
Building a CI/CD Pipeline for PHP apps
Building a CI/CD Pipeline for PHP appsBuilding a CI/CD Pipeline for PHP apps
Building a CI/CD Pipeline for PHP apps
 
Practical unit testing in c & c++
Practical unit testing in c & c++Practical unit testing in c & c++
Practical unit testing in c & c++
 
Integrating the compiler with unit testing
Integrating the compiler with unit testingIntegrating the compiler with unit testing
Integrating the compiler with unit testing
 
Automation testing IBM RFT - Rational Functional Tester
Automation testing IBM RFT - Rational Functional TesterAutomation testing IBM RFT - Rational Functional Tester
Automation testing IBM RFT - Rational Functional Tester
 
A new Codemodel for Codemetrics
 A new Codemodel for Codemetrics A new Codemodel for Codemetrics
A new Codemodel for Codemetrics
 

Similar to Regression Tests with Symfony - Example

Encode x ICH: Intro to Building on the IC in Motoko
Encode x ICH: Intro to Building on the IC in MotokoEncode x ICH: Intro to Building on the IC in Motoko
Encode x ICH: Intro to Building on the IC in Motoko
KlaraOrban
 
Behat Workshop at WeLovePHP
Behat Workshop at WeLovePHPBehat Workshop at WeLovePHP
Behat Workshop at WeLovePHP
Marcos Quesada
 
Skype testing overview
Skype testing overviewSkype testing overview
Skype testing overview
QA Club Kiev
 
automation framework
automation frameworkautomation framework
automation framework
ANSHU GOYAL
 

Similar to Regression Tests with Symfony - Example (20)

Behat internals for advanced usage. Symfony Camp 2016
Behat internals for advanced usage. Symfony Camp 2016Behat internals for advanced usage. Symfony Camp 2016
Behat internals for advanced usage. Symfony Camp 2016
 
Behavior Driven Development by Example
Behavior Driven Development by ExampleBehavior Driven Development by Example
Behavior Driven Development by Example
 
Introducing BDD and TDD with Cucumber
Introducing BDD and TDD with CucumberIntroducing BDD and TDD with Cucumber
Introducing BDD and TDD with Cucumber
 
PHP CE 2018 - Building Symfony application with Ports and Adapters approach a...
PHP CE 2018 - Building Symfony application with Ports and Adapters approach a...PHP CE 2018 - Building Symfony application with Ports and Adapters approach a...
PHP CE 2018 - Building Symfony application with Ports and Adapters approach a...
 
Cucumber & gherkin language
Cucumber & gherkin languageCucumber & gherkin language
Cucumber & gherkin language
 
Behat sauce
Behat sauceBehat sauce
Behat sauce
 
Encode x ICH: Intro to Building on the IC in Motoko
Encode x ICH: Intro to Building on the IC in MotokoEncode x ICH: Intro to Building on the IC in Motoko
Encode x ICH: Intro to Building on the IC in Motoko
 
Behat Workshop at WeLovePHP
Behat Workshop at WeLovePHPBehat Workshop at WeLovePHP
Behat Workshop at WeLovePHP
 
Guides To Analyzing WebKit Performance
Guides To Analyzing WebKit PerformanceGuides To Analyzing WebKit Performance
Guides To Analyzing WebKit Performance
 
Cucumber
Cucumber Cucumber
Cucumber
 
BinProxy: New Paradigm of Binary Analysis With Your Favorite Web Proxy
BinProxy: New Paradigm of Binary Analysis With Your Favorite Web ProxyBinProxy: New Paradigm of Binary Analysis With Your Favorite Web Proxy
BinProxy: New Paradigm of Binary Analysis With Your Favorite Web Proxy
 
Gherkin /BDD intro
Gherkin /BDD introGherkin /BDD intro
Gherkin /BDD intro
 
Jenkins auto configureforbranch-php
Jenkins auto configureforbranch-phpJenkins auto configureforbranch-php
Jenkins auto configureforbranch-php
 
Skype testing overview
Skype testing overviewSkype testing overview
Skype testing overview
 
Skype testing overview
Skype testing overviewSkype testing overview
Skype testing overview
 
Automation With Frank
Automation With FrankAutomation With Frank
Automation With Frank
 
automation framework
automation frameworkautomation framework
automation framework
 
Spec(ing) Out Your Workflow with SpecFlow
Spec(ing) Out Your Workflow with SpecFlowSpec(ing) Out Your Workflow with SpecFlow
Spec(ing) Out Your Workflow with SpecFlow
 
Sikuli
SikuliSikuli
Sikuli
 
Challenges in Debugging Bootstraps of Reflective Kernels
Challenges in Debugging Bootstraps of Reflective KernelsChallenges in Debugging Bootstraps of Reflective Kernels
Challenges in Debugging Bootstraps of Reflective Kernels
 

Recently uploaded

Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
 

Recently uploaded (20)

Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
Deploy with confidence: VMware Cloud Foundation 5.1 on next gen Dell PowerEdg...
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 

Regression Tests with Symfony - Example

  • 1. Regression Testing with Symfony Tools and techniques for building your test suite
  • 2. Part 2: Utilizing the tools  Functional tests with the BehatBundle  Components of the MinkBundle  Selection of Browser Drivers  Zombie JS Driver  Sahi Driver
  • 3. BDD Test Specification Scenario: Put item in shopping cart Given the case, the customer wants to buy a movie And his shopping cart is empty And there are 2 movies in stock When he puts the item in the shopping cart Then the item should show up in the shopping cart And the shopping cart counter should show 1 And 1 movie should be in stock
  • 4. Gherkin Language  Formal language to define functional tests  Entry points using defined keywords  Feature: Set of functional test for a specific domain  Background: Steps that will be executed for each scenario  Scenario: Steps to test a certain behaviour
  • 5. Gherkin Language  Keywords for step definitions  Given: Pre-condition for the scenario  When: Action/Operation to perform  Then: Test for expected result  And: Chaining of step definitions
  • 6. Behat + Bundle  BehatBundle integrates Behat in Symfony  Setup of kernel  Access to DIC  Mapping of Gherkin  Located in own directory structure  .feature file to define step definitions  FeatureContext to match the steps
  • 7. Mink + Bundle  MinkBundle integrates Mink into Symfony  Encapsulation of various browser drives  GoutteDriver: headless pure-php driver  SahiDriver: JS browser driver with GUI installer  ZombieDriver: Bridge for Zombie.js browser emulator  SeleniumDriver: Bridge to Selenium  FeatureContext for common browser operations  Setup of application kernel
  • 8. Thank you for your attiontion!