SlideShare a Scribd company logo
1 of 24
Download to read offline
AMIR BARYLKO
                      QUALITY DRIVEN
                      WEB ACCEPTANCE
                         TESTING

                             MVC CONFERENCE
                                 FEB 2011


Amir Barylko - MvcConf                        MavenThought Inc.
Tuesday, February 8, 2011
WHO AM I?

    • Architect

    • Developer

    • Mentor

    • Great             cook

    • The           one who’s entertaining you for the next hour!


Amir Barylko - MvcConf                                              MavenThought Inc.
Tuesday, February 8, 2011
BDD




Amir Barylko - MvcConf            MavenThought Inc.
Tuesday, February 8, 2011
WHY TRADITIONAL
                               PROJECTS FAIL?

    • Delivering               late or over budget

    • Delivering               the wrong thing

    • Unstable                in production

    • Costly                to maintain


Amir Barylko - MvcConf                               MavenThought Inc.
Tuesday, February 8, 2011
BDD PRINCIPLES

    • Behaviour    Driven development is about implementing an
        application by describing its behaviour from the perspective of
        the stakeholder

         • Enough           is Enough

         • Deliver          stakeholder value

         • It’s      all behaviour


Amir Barylko - MvcConf                                       MavenThought Inc.
Tuesday, February 8, 2011
OUTSIDE IN APPROACH




Amir Barylko - MvcConf                MavenThought Inc.
Tuesday, February 8, 2011
GHERKIN DSL

    • Business              readable DSL

    • Flush           out requirements

    • Documentation

    • Automated               testing

    • Used   by Cucumber,
        SpecFlow, jBehave

Amir Barylko - BDD                              MavenThought Inc.
Tuesday, February 8, 2011
CUCUMBER




Amir Barylko - MvcConf                 MavenThought Inc.
Tuesday, February 8, 2011
WHAT DO I NEED?

    • The           following folder structure

              features: Folder for all the .feature files

                   step_definitions: all your step implementations (.rb)

                   support: setup environment, capybara, etc (.rb)




Amir Barylko - MvcConf                                               MavenThought Inc.
Tuesday, February 8, 2011
SETUP
                             features/support/paths.rb



         module NavigationHelpers
        # Maps a name to a path. Used by the
        #
        #   When /^I go to (.+)$/ do |page_name|
        #
        # step definition in web_steps.rb
        #
        def path_to(page_name)
          case page_name

             when /home/
               '/'

             when /Movies/
               '/Movies'

        ...


Amir Barylko - MvcConf                                   MavenThought Inc.
Tuesday, February 8, 2011
FEATURES
        Feature: Addition
        In order to make my library grow
        As a registered user
        I want to add movies to the library

        Scenario:           Add a movie
          Given I           have no movies
          And   I           am on "home"
          When I            follow "create"
          And   I           fill in "movie_title" with "Young Frankenstein"
          And   I           press "Submit"
          Then I            should see "Young Frankenstein"




Amir Barylko - MvcConf                                                  MavenThought Inc.
Tuesday, February 8, 2011
STEPS
      Given /^I have the following movies:$/ do |table|
      db = SQLite3::Database.new( "C:/temp/movielib.db" )
      db.execute( "delete from Movie" )
      ...
    end

    Given /^I have no movies$/ do
      clear_database
    end




Amir Barylko - MvcConf                                      MavenThought Inc.
Tuesday, February 8, 2011
HOW DOES IT WORK?
    •   Read scenario step

             Given I have no movies

    •   Match regular expression

             Given /^I have no movies$/

    •   Run the code associated to the regular expression

             clear_database




Amir Barylko - MvcConf                                      MavenThought Inc.
Tuesday, February 8, 2011
CAPYBARA




Amir Barylko - MvcConf                 MavenThought Inc.
Tuesday, February 8, 2011
WHAT

    • Gem              to simplify integration tests

    • Inspired              by Webrat

    • Can           be used with Cucumber steps or in any other test

    • Easy           to install: gem install capybara




Amir Barylko - MvcConf                                           MavenThought Inc.
Tuesday, February 8, 2011
WHY

    • Support               for different web browsers (ie, firefox, chrome)

    • Provides              driver to run headless (virtual browser)

    • Can           tag scenarios to be run with a browser

    • Supports              remote web application (not rack)

    • Supports              asynchronous calls (AJAX)


Amir Barylko - MvcConf                                                 MavenThought Inc.
Tuesday, February 8, 2011
SETUP
                             features/support/capybara.rb



    require 'capybara/cucumber'
    require 'selenium-webdriver'

    #Capybara.default_driver = :culerity
    Capybara.default_driver = :selenium

    Capybara.app_host = "http://localhost:1591"
    Capybara.run_server = false
    Capybara.default_wait_time = 5
    Capybara.default_selector = :css

    Capybara.register_driver :selenium do |app|
      #Capybara::Driver::Selenium.new(app, :browser => :ie)
      Capybara::Driver::Selenium.new(app, :browser => :chrome)
    end




Amir Barylko - MvcConf                                           MavenThought Inc.
Tuesday, February 8, 2011
STEPS

    • Given                 I am on the Home page

    • When                  I go to the Projects page

    • When                  I press “login”

    • When                  I follow “help” within “support”




Amir Barylko - MvcConf                                         MavenThought Inc.
Tuesday, February 8, 2011
STEPS II

    • When                  I fill “username” with “mel”

    • When                  I select “Winnipeg” from “cities”

    • When                  I check “remember_me”

    • When                  I uncheck “remember_me”

    • When                  I choose “Option”


Amir Barylko - MvcConf                                          MavenThought Inc.
Tuesday, February 8, 2011
STEPS III

    • Then             I should see “Welcome”

    • Then             I should not see “Welcome”

    • Then             the field “user” should contain “Mel”

    • Then             show me the page




Amir Barylko - MvcConf                                        MavenThought Inc.
Tuesday, February 8, 2011
DEMO




Amir Barylko - MvcConf             MavenThought Inc.
Tuesday, February 8, 2011
QUESTIONS?




Amir Barylko - MvcConf                   MavenThought Inc.
Tuesday, February 8, 2011
RESOURCES

    • Email: amir@barylko.com

    • Twitter: @abarylko

    • Materials: http://www.orthocoders.com/presentations




Amir Barylko - MvcConf                                  MavenThought Inc.
Tuesday, February 8, 2011
RESOURCES II

    • Capybara: https://github.com/jnicklas/capybara

    • Cucumber: https://github.com/aslakhellesoy/cucumber/wiki

    • Culerity: https://github.com/langalex/culerity

    • Celerity: http://celerity.rubyforge.org

    • Selenium: http://seleniumhq.org



Amir Barylko - MvcConf                                  MavenThought Inc.
Tuesday, February 8, 2011

More Related Content

What's hot

every-day-automation
every-day-automationevery-day-automation
every-day-automationAmir Barylko
 
CodeCamp 2012-mvc-vs-ror-2
CodeCamp 2012-mvc-vs-ror-2CodeCamp 2012-mvc-vs-ror-2
CodeCamp 2012-mvc-vs-ror-2Amir Barylko
 
PRDC-ror-trilogy-part1
PRDC-ror-trilogy-part1PRDC-ror-trilogy-part1
PRDC-ror-trilogy-part1Amir Barylko
 
CPL12-Agile-planning
CPL12-Agile-planningCPL12-Agile-planning
CPL12-Agile-planningAmir Barylko
 
Cpl12 continuous integration
Cpl12 continuous integrationCpl12 continuous integration
Cpl12 continuous integrationAmir Barylko
 
Agile requirements
Agile requirementsAgile requirements
Agile requirementsAmir Barylko
 
PRDCW-avent-aggregator
PRDCW-avent-aggregatorPRDCW-avent-aggregator
PRDCW-avent-aggregatorAmir Barylko
 
Aki Salmi - Refactoring legacy code: a true story @ I T.A.K.E. Unconference 2...
Aki Salmi - Refactoring legacy code: a true story @ I T.A.K.E. Unconference 2...Aki Salmi - Refactoring legacy code: a true story @ I T.A.K.E. Unconference 2...
Aki Salmi - Refactoring legacy code: a true story @ I T.A.K.E. Unconference 2...Mozaic Works
 
Social dev camp_2011
Social dev camp_2011Social dev camp_2011
Social dev camp_2011Craig Ulliott
 
Android java fx-jme@jug-lugano
Android java fx-jme@jug-luganoAndroid java fx-jme@jug-lugano
Android java fx-jme@jug-luganoFabrizio Giudici
 
Rise of the hybrids
Rise of the hybridsRise of the hybrids
Rise of the hybridsOron Ben Zvi
 
WebGL Camp 4 - A3 3D Engine
WebGL Camp 4 - A3 3D EngineWebGL Camp 4 - A3 3D Engine
WebGL Camp 4 - A3 3D Engineaerotwist
 
"Building a Resilient Cloud Infrastructure. From Scratch." - Cloud East, 28 J...
"Building a Resilient Cloud Infrastructure. From Scratch." - Cloud East, 28 J..."Building a Resilient Cloud Infrastructure. From Scratch." - Cloud East, 28 J...
"Building a Resilient Cloud Infrastructure. From Scratch." - Cloud East, 28 J...Jeremy Jarvis
 
Philly CocoaHeads 20160414 - Building Your App SDK With Swift
Philly CocoaHeads 20160414 - Building Your App SDK With SwiftPhilly CocoaHeads 20160414 - Building Your App SDK With Swift
Philly CocoaHeads 20160414 - Building Your App SDK With SwiftJordan Yaker
 
Becoming a more productive Rails Developer
Becoming a more productive Rails DeveloperBecoming a more productive Rails Developer
Becoming a more productive Rails DeveloperJohn McCaffrey
 

What's hot (19)

every-day-automation
every-day-automationevery-day-automation
every-day-automation
 
CodeCamp 2012-mvc-vs-ror-2
CodeCamp 2012-mvc-vs-ror-2CodeCamp 2012-mvc-vs-ror-2
CodeCamp 2012-mvc-vs-ror-2
 
PRDC-ror-trilogy-part1
PRDC-ror-trilogy-part1PRDC-ror-trilogy-part1
PRDC-ror-trilogy-part1
 
CPL12-Agile-planning
CPL12-Agile-planningCPL12-Agile-planning
CPL12-Agile-planning
 
Cpl12 continuous integration
Cpl12 continuous integrationCpl12 continuous integration
Cpl12 continuous integration
 
YEG-UG-Capybara
YEG-UG-CapybaraYEG-UG-Capybara
YEG-UG-Capybara
 
Capybara1
Capybara1Capybara1
Capybara1
 
Agile requirements
Agile requirementsAgile requirements
Agile requirements
 
PRDCW-avent-aggregator
PRDCW-avent-aggregatorPRDCW-avent-aggregator
PRDCW-avent-aggregator
 
Agile planning
Agile planningAgile planning
Agile planning
 
Aki Salmi - Refactoring legacy code: a true story @ I T.A.K.E. Unconference 2...
Aki Salmi - Refactoring legacy code: a true story @ I T.A.K.E. Unconference 2...Aki Salmi - Refactoring legacy code: a true story @ I T.A.K.E. Unconference 2...
Aki Salmi - Refactoring legacy code: a true story @ I T.A.K.E. Unconference 2...
 
Social dev camp_2011
Social dev camp_2011Social dev camp_2011
Social dev camp_2011
 
Android java fx-jme@jug-lugano
Android java fx-jme@jug-luganoAndroid java fx-jme@jug-lugano
Android java fx-jme@jug-lugano
 
Irb Tips and Tricks
Irb Tips and TricksIrb Tips and Tricks
Irb Tips and Tricks
 
Rise of the hybrids
Rise of the hybridsRise of the hybrids
Rise of the hybrids
 
WebGL Camp 4 - A3 3D Engine
WebGL Camp 4 - A3 3D EngineWebGL Camp 4 - A3 3D Engine
WebGL Camp 4 - A3 3D Engine
 
"Building a Resilient Cloud Infrastructure. From Scratch." - Cloud East, 28 J...
"Building a Resilient Cloud Infrastructure. From Scratch." - Cloud East, 28 J..."Building a Resilient Cloud Infrastructure. From Scratch." - Cloud East, 28 J...
"Building a Resilient Cloud Infrastructure. From Scratch." - Cloud East, 28 J...
 
Philly CocoaHeads 20160414 - Building Your App SDK With Swift
Philly CocoaHeads 20160414 - Building Your App SDK With SwiftPhilly CocoaHeads 20160414 - Building Your App SDK With Swift
Philly CocoaHeads 20160414 - Building Your App SDK With Swift
 
Becoming a more productive Rails Developer
Becoming a more productive Rails DeveloperBecoming a more productive Rails Developer
Becoming a more productive Rails Developer
 

Similar to Quality web-acceptance

Page-objects-pattern
Page-objects-patternPage-objects-pattern
Page-objects-patternAmir Barylko
 
Writing an (in)secure webapp in 3 easy steps
Writing an (in)secure webapp in 3 easy stepsWriting an (in)secure webapp in 3 easy steps
Writing an (in)secure webapp in 3 easy stepsAdam Baldwin
 
20110903 candycane
20110903 candycane20110903 candycane
20110903 candycaneYusuke Ando
 
Extreme Testing with Selenium - @hugs at Jenkins User Conference 2011
Extreme Testing with Selenium - @hugs at Jenkins User Conference 2011Extreme Testing with Selenium - @hugs at Jenkins User Conference 2011
Extreme Testing with Selenium - @hugs at Jenkins User Conference 2011hugs
 
Immutable infrastructure:觀念與實作 (建議)
Immutable infrastructure:觀念與實作 (建議)Immutable infrastructure:觀念與實作 (建議)
Immutable infrastructure:觀念與實作 (建議)William Yeh
 
StackEngine Demo - Boston
StackEngine Demo - BostonStackEngine Demo - Boston
StackEngine Demo - BostonBoyd Hemphill
 
StackEngine Demo - Docker Austin
StackEngine Demo - Docker AustinStackEngine Demo - Docker Austin
StackEngine Demo - Docker AustinBoyd Hemphill
 
JavaSE - The road forward
JavaSE - The road forwardJavaSE - The road forward
JavaSE - The road forwardeug3n_cojocaru
 
Develop:BBC 2013 - Turbocharge your mobile web apps by using offline
Develop:BBC 2013 - Turbocharge your mobile web apps by using offlineDevelop:BBC 2013 - Turbocharge your mobile web apps by using offline
Develop:BBC 2013 - Turbocharge your mobile web apps by using offlineJan Jongboom
 
Rich UI with Knockout.js & Coffeescript
Rich UI with Knockout.js & CoffeescriptRich UI with Knockout.js & Coffeescript
Rich UI with Knockout.js & CoffeescriptAmir Barylko
 
Agile requirements
Agile requirementsAgile requirements
Agile requirementsAmir Barylko
 
JavaOne 2011 - Going Mobile With Java Based Technologies Today
JavaOne 2011 - Going Mobile With Java Based Technologies TodayJavaOne 2011 - Going Mobile With Java Based Technologies Today
JavaOne 2011 - Going Mobile With Java Based Technologies TodayWesley Hales
 
Puppet Camp Melbourne Nov 2014 - A Build Engineering Team’s Journey of Infras...
Puppet Camp Melbourne Nov 2014 - A Build Engineering Team’s Journey of Infras...Puppet Camp Melbourne Nov 2014 - A Build Engineering Team’s Journey of Infras...
Puppet Camp Melbourne Nov 2014 - A Build Engineering Team’s Journey of Infras...Peter Leschev
 
Codemash-iron-ruby-match-made-in-heaven
Codemash-iron-ruby-match-made-in-heavenCodemash-iron-ruby-match-made-in-heaven
Codemash-iron-ruby-match-made-in-heavenAmir Barylko
 
Using mvvm on the web using knockoutjs & ignite ui
Using mvvm on the web using knockoutjs & ignite uiUsing mvvm on the web using knockoutjs & ignite ui
Using mvvm on the web using knockoutjs & ignite uiNish Anil
 
Acceptance Testing of Web UI
Acceptance Testing of Web UIAcceptance Testing of Web UI
Acceptance Testing of Web UIVladimir Tsukur
 
BlackBerry WebWorks APIs
BlackBerry WebWorks APIsBlackBerry WebWorks APIs
BlackBerry WebWorks APIsSencha
 
An Introduction to Maven
An Introduction to MavenAn Introduction to Maven
An Introduction to MavenVadym Lotar
 

Similar to Quality web-acceptance (20)

Page-objects-pattern
Page-objects-patternPage-objects-pattern
Page-objects-pattern
 
Writing an (in)secure webapp in 3 easy steps
Writing an (in)secure webapp in 3 easy stepsWriting an (in)secure webapp in 3 easy steps
Writing an (in)secure webapp in 3 easy steps
 
20110903 candycane
20110903 candycane20110903 candycane
20110903 candycane
 
Extreme Testing with Selenium - @hugs at Jenkins User Conference 2011
Extreme Testing with Selenium - @hugs at Jenkins User Conference 2011Extreme Testing with Selenium - @hugs at Jenkins User Conference 2011
Extreme Testing with Selenium - @hugs at Jenkins User Conference 2011
 
obs-tdd-intro
obs-tdd-introobs-tdd-intro
obs-tdd-intro
 
Immutable infrastructure:觀念與實作 (建議)
Immutable infrastructure:觀念與實作 (建議)Immutable infrastructure:觀念與實作 (建議)
Immutable infrastructure:觀念與實作 (建議)
 
StackEngine Demo - Boston
StackEngine Demo - BostonStackEngine Demo - Boston
StackEngine Demo - Boston
 
StackEngine Demo - Docker Austin
StackEngine Demo - Docker AustinStackEngine Demo - Docker Austin
StackEngine Demo - Docker Austin
 
JavaSE - The road forward
JavaSE - The road forwardJavaSE - The road forward
JavaSE - The road forward
 
Develop:BBC 2013 - Turbocharge your mobile web apps by using offline
Develop:BBC 2013 - Turbocharge your mobile web apps by using offlineDevelop:BBC 2013 - Turbocharge your mobile web apps by using offline
Develop:BBC 2013 - Turbocharge your mobile web apps by using offline
 
Rich UI with Knockout.js & Coffeescript
Rich UI with Knockout.js & CoffeescriptRich UI with Knockout.js & Coffeescript
Rich UI with Knockout.js & Coffeescript
 
Agile requirements
Agile requirementsAgile requirements
Agile requirements
 
JavaOne 2011 - Going Mobile With Java Based Technologies Today
JavaOne 2011 - Going Mobile With Java Based Technologies TodayJavaOne 2011 - Going Mobile With Java Based Technologies Today
JavaOne 2011 - Going Mobile With Java Based Technologies Today
 
Puppet Camp Melbourne Nov 2014 - A Build Engineering Team’s Journey of Infras...
Puppet Camp Melbourne Nov 2014 - A Build Engineering Team’s Journey of Infras...Puppet Camp Melbourne Nov 2014 - A Build Engineering Team’s Journey of Infras...
Puppet Camp Melbourne Nov 2014 - A Build Engineering Team’s Journey of Infras...
 
agile-planning
agile-planningagile-planning
agile-planning
 
Codemash-iron-ruby-match-made-in-heaven
Codemash-iron-ruby-match-made-in-heavenCodemash-iron-ruby-match-made-in-heaven
Codemash-iron-ruby-match-made-in-heaven
 
Using mvvm on the web using knockoutjs & ignite ui
Using mvvm on the web using knockoutjs & ignite uiUsing mvvm on the web using knockoutjs & ignite ui
Using mvvm on the web using knockoutjs & ignite ui
 
Acceptance Testing of Web UI
Acceptance Testing of Web UIAcceptance Testing of Web UI
Acceptance Testing of Web UI
 
BlackBerry WebWorks APIs
BlackBerry WebWorks APIsBlackBerry WebWorks APIs
BlackBerry WebWorks APIs
 
An Introduction to Maven
An Introduction to MavenAn Introduction to Maven
An Introduction to Maven
 

More from Amir Barylko

Functional converter project
Functional converter projectFunctional converter project
Functional converter projectAmir Barylko
 
Elm: delightful web development
Elm: delightful web developmentElm: delightful web development
Elm: delightful web developmentAmir Barylko
 
User stories deep dive
User stories deep diveUser stories deep dive
User stories deep diveAmir Barylko
 
Coderetreat hosting training
Coderetreat hosting trainingCoderetreat hosting training
Coderetreat hosting trainingAmir Barylko
 
There's no charge for (functional) awesomeness
There's no charge for (functional) awesomenessThere's no charge for (functional) awesomeness
There's no charge for (functional) awesomenessAmir Barylko
 
What's new in c# 6
What's new in c# 6What's new in c# 6
What's new in c# 6Amir Barylko
 
Who killed object oriented design?
Who killed object oriented design?Who killed object oriented design?
Who killed object oriented design?Amir Barylko
 
From coach to owner - What I learned from the other side
From coach to owner - What I learned from the other sideFrom coach to owner - What I learned from the other side
From coach to owner - What I learned from the other sideAmir Barylko
 
Communication is the Key to Teamwork and productivity
Communication is the Key to Teamwork and productivityCommunication is the Key to Teamwork and productivity
Communication is the Key to Teamwork and productivityAmir Barylko
 
Acceptance Test Driven Development
Acceptance Test Driven DevelopmentAcceptance Test Driven Development
Acceptance Test Driven DevelopmentAmir Barylko
 
Agile teams and responsibilities
Agile teams and responsibilitiesAgile teams and responsibilities
Agile teams and responsibilitiesAmir Barylko
 
Beutiful javascript with coffeescript
Beutiful javascript with coffeescriptBeutiful javascript with coffeescript
Beutiful javascript with coffeescriptAmir Barylko
 
SDEC12 Beautiful javascript with coffeescript
SDEC12 Beautiful javascript with coffeescriptSDEC12 Beautiful javascript with coffeescript
SDEC12 Beautiful javascript with coffeescriptAmir Barylko
 
Beutiful javascript with coffeescript
Beutiful javascript with coffeescriptBeutiful javascript with coffeescript
Beutiful javascript with coffeescriptAmir Barylko
 

More from Amir Barylko (20)

Functional converter project
Functional converter projectFunctional converter project
Functional converter project
 
Elm: delightful web development
Elm: delightful web developmentElm: delightful web development
Elm: delightful web development
 
Dot Net Core
Dot Net CoreDot Net Core
Dot Net Core
 
No estimates
No estimatesNo estimates
No estimates
 
User stories deep dive
User stories deep diveUser stories deep dive
User stories deep dive
 
Coderetreat hosting training
Coderetreat hosting trainingCoderetreat hosting training
Coderetreat hosting training
 
There's no charge for (functional) awesomeness
There's no charge for (functional) awesomenessThere's no charge for (functional) awesomeness
There's no charge for (functional) awesomeness
 
What's new in c# 6
What's new in c# 6What's new in c# 6
What's new in c# 6
 
Productive teams
Productive teamsProductive teams
Productive teams
 
Who killed object oriented design?
Who killed object oriented design?Who killed object oriented design?
Who killed object oriented design?
 
From coach to owner - What I learned from the other side
From coach to owner - What I learned from the other sideFrom coach to owner - What I learned from the other side
From coach to owner - What I learned from the other side
 
Communication is the Key to Teamwork and productivity
Communication is the Key to Teamwork and productivityCommunication is the Key to Teamwork and productivity
Communication is the Key to Teamwork and productivity
 
Acceptance Test Driven Development
Acceptance Test Driven DevelopmentAcceptance Test Driven Development
Acceptance Test Driven Development
 
Refactoring
RefactoringRefactoring
Refactoring
 
Agile teams and responsibilities
Agile teams and responsibilitiesAgile teams and responsibilities
Agile teams and responsibilities
 
Refactoring
RefactoringRefactoring
Refactoring
 
Beutiful javascript with coffeescript
Beutiful javascript with coffeescriptBeutiful javascript with coffeescript
Beutiful javascript with coffeescript
 
Sass & bootstrap
Sass & bootstrapSass & bootstrap
Sass & bootstrap
 
SDEC12 Beautiful javascript with coffeescript
SDEC12 Beautiful javascript with coffeescriptSDEC12 Beautiful javascript with coffeescript
SDEC12 Beautiful javascript with coffeescript
 
Beutiful javascript with coffeescript
Beutiful javascript with coffeescriptBeutiful javascript with coffeescript
Beutiful javascript with coffeescript
 

Recently uploaded

SALESFORCE EDUCATION CLOUD | FEXLE SERVICES
SALESFORCE EDUCATION CLOUD | FEXLE SERVICESSALESFORCE EDUCATION CLOUD | FEXLE SERVICES
SALESFORCE EDUCATION CLOUD | FEXLE SERVICESmohitsingh558521
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationSlibray Presentation
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenHervé Boutemy
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupFlorian Wilhelm
 
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxLoriGlavin3
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024Stephanie Beckett
 
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxLoriGlavin3
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxLoriGlavin3
 
The State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxThe State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxLoriGlavin3
 
unit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptxunit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptxBkGupta21
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionDilum Bandara
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.Curtis Poe
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 

Recently uploaded (20)

SALESFORCE EDUCATION CLOUD | FEXLE SERVICES
SALESFORCE EDUCATION CLOUD | FEXLE SERVICESSALESFORCE EDUCATION CLOUD | FEXLE SERVICES
SALESFORCE EDUCATION CLOUD | FEXLE SERVICES
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck Presentation
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache Maven
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project Setup
 
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024
 
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
 
The State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxThe State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptx
 
unit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptxunit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptx
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An Introduction
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 

Quality web-acceptance

  • 1. AMIR BARYLKO QUALITY DRIVEN WEB ACCEPTANCE TESTING MVC CONFERENCE FEB 2011 Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 2. WHO AM I? • Architect • Developer • Mentor • Great cook • The one who’s entertaining you for the next hour! Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 3. BDD Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 4. WHY TRADITIONAL PROJECTS FAIL? • Delivering late or over budget • Delivering the wrong thing • Unstable in production • Costly to maintain Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 5. BDD PRINCIPLES • Behaviour Driven development is about implementing an application by describing its behaviour from the perspective of the stakeholder • Enough is Enough • Deliver stakeholder value • It’s all behaviour Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 6. OUTSIDE IN APPROACH Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 7. GHERKIN DSL • Business readable DSL • Flush out requirements • Documentation • Automated testing • Used by Cucumber, SpecFlow, jBehave Amir Barylko - BDD MavenThought Inc. Tuesday, February 8, 2011
  • 8. CUCUMBER Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 9. WHAT DO I NEED? • The following folder structure features: Folder for all the .feature files step_definitions: all your step implementations (.rb) support: setup environment, capybara, etc (.rb) Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 10. SETUP features/support/paths.rb module NavigationHelpers # Maps a name to a path. Used by the # # When /^I go to (.+)$/ do |page_name| # # step definition in web_steps.rb # def path_to(page_name) case page_name when /home/ '/' when /Movies/ '/Movies' ... Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 11. FEATURES Feature: Addition In order to make my library grow As a registered user I want to add movies to the library Scenario: Add a movie Given I have no movies And I am on "home" When I follow "create" And I fill in "movie_title" with "Young Frankenstein" And I press "Submit" Then I should see "Young Frankenstein" Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 12. STEPS Given /^I have the following movies:$/ do |table| db = SQLite3::Database.new( "C:/temp/movielib.db" ) db.execute( "delete from Movie" ) ... end Given /^I have no movies$/ do clear_database end Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 13. HOW DOES IT WORK? • Read scenario step Given I have no movies • Match regular expression Given /^I have no movies$/ • Run the code associated to the regular expression clear_database Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 14. CAPYBARA Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 15. WHAT • Gem to simplify integration tests • Inspired by Webrat • Can be used with Cucumber steps or in any other test • Easy to install: gem install capybara Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 16. WHY • Support for different web browsers (ie, firefox, chrome) • Provides driver to run headless (virtual browser) • Can tag scenarios to be run with a browser • Supports remote web application (not rack) • Supports asynchronous calls (AJAX) Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 17. SETUP features/support/capybara.rb require 'capybara/cucumber' require 'selenium-webdriver' #Capybara.default_driver = :culerity Capybara.default_driver = :selenium Capybara.app_host = "http://localhost:1591" Capybara.run_server = false Capybara.default_wait_time = 5 Capybara.default_selector = :css Capybara.register_driver :selenium do |app| #Capybara::Driver::Selenium.new(app, :browser => :ie) Capybara::Driver::Selenium.new(app, :browser => :chrome) end Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 18. STEPS • Given I am on the Home page • When I go to the Projects page • When I press “login” • When I follow “help” within “support” Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 19. STEPS II • When I fill “username” with “mel” • When I select “Winnipeg” from “cities” • When I check “remember_me” • When I uncheck “remember_me” • When I choose “Option” Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 20. STEPS III • Then I should see “Welcome” • Then I should not see “Welcome” • Then the field “user” should contain “Mel” • Then show me the page Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 21. DEMO Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 22. QUESTIONS? Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 23. RESOURCES • Email: amir@barylko.com • Twitter: @abarylko • Materials: http://www.orthocoders.com/presentations Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011
  • 24. RESOURCES II • Capybara: https://github.com/jnicklas/capybara • Cucumber: https://github.com/aslakhellesoy/cucumber/wiki • Culerity: https://github.com/langalex/culerity • Celerity: http://celerity.rubyforge.org • Selenium: http://seleniumhq.org Amir Barylko - MvcConf MavenThought Inc. Tuesday, February 8, 2011