SlideShare une entreprise Scribd logo
1  sur  47
Télécharger pour lire hors ligne
Selenium and
Sauce Labs
Jason Huggins
twitter: @hugs
email: hugs@saucelabs.com
Agenda
• Overview of Selenium
• Selenium IDE, RC, Grid
• Sauce Labs and Sauce OnDemand
• Demo
• Selenium IDE, Sauce OnDemand
• Tips and Tricks
• Selenium 2
• Q&A
The Problem
Automated
Source: - F.O.X.: http://www.flickr.com/photos/kv/499219/
Ajax
Workflows
What is Selenium?
Selenium IDE for Firefox
“Selenese”
10
!"#$%"&'$(%)$*
+%%,-..///01*234)03$#.,+$%$5.23"6$(".789:;8<=:
Example Selenium RC Test - Java
Example Selenium RC Test - C#
Python, Ruby,
Java, C#, or Perl
Test Script
HTTP
Your Awesome
Web App
Selenium RC Server
HTTP HTTP
Selenium Remote Control
Time
Servers
Unit of Work
Time
Servers
Unit of Work
!"#$
%&&'())***+,-#./"+.01)'%0&02)$345)678
Selenium Grid
Sauce Labs
What Sauce Labs Does
• Cloud-hosted Selenium for:
• Speed—run tests in parallel
• Pain-free infrastructure (test infrastructure is notoriously fussy, fiddly
due to accelerating Browser numbers and version pace, security
patches etc.)
• Higher availability, repeatability
• Value-added (enhanced, certified) distros:
• Sauce RC (Selenium RC (remote control))
• Sauce IDE (Selenium IDE)
• Commercial Support for Selenium
!"#$
%&&'())***+,-#./"+.01)'%0&02)$345)678
Sauce OnDemand (just like Grid)
Demo!
How to Avoid
Selenium Poisoning
Intent Action
Action
• open 'www.example.com'
• clickAndWait 'link=Log in'
• type 'User Id', 'hugs@saucelabs.com'
• type 'password', '12345678'
• clickAndWait 'Log In'
Intent
• Log in
• Change password
• Modify profile
• Log out
1.Write intent.
2. Map to actions.
Seek higher level
abstractions
Hudson
Ant/NAnt
xUnit
Selenium
Hudson
Ant/NAnt
xUnit
Business Specific Library
Selenium
Page Object Model
Google:“Selenium Page Objects”
Start small
It’ll get big anyway
What to start with?
• Smoke tests
• “Money path”
• New features
Benefits of Short Tests
• Easier to read
• Easier to write
• Easier to debug/maintain
• Easier to parallelize
Selenium 2?
• Native Keyboard & Mouse Events
• Same Origin Policy / XSS / HTTP(S)
• Pop-ups, dialogs
– Basic Authentication
– Self-signed certificates
– File upload/download
Better Control
• WebDriver Object
• WebElement Objects
Cleaner API
Python, Ruby,
Java, C#, or Perl
Test Script
HTTP
Your Awesome
Web App
Selenium RC Server
HTTP HTTP
Selenium Remote Control
Python, Ruby,
Java, C#, or Perl
Test Script
HTTP
Your Awesome
Web App
Selenium RC Server
HTTP HTTP
Selenium 2
Python, Ruby,
Java, C#, or Perl
Test Script
Your Awesome
Web App
HTTP HTTP
Python, Ruby,
Java, C#, or Perl
Test Script
Your Awesome
Web App
C/C++ HTTP
But... Java... Is... Still... In...There...
Python, Ruby,
Java, C#, or Perl
Test Script
HTTP
Your Awesome
Web App
Selenium Grid
HTTP HTTP
But... Java... Is... Still... In...There...
Python, Ruby,
Java, C#, or Perl
Test Script
HTTP
Selenium Remote
Server
HTTP HTTP
Ye Ol' Internet
(Sauce Labs)
... but now only when you need it.
Q&A

Contenu connexe

Tendances

Tendances (20)

Beyond the Release: CI That Transforms Organizations
Beyond the Release: CI That Transforms OrganizationsBeyond the Release: CI That Transforms Organizations
Beyond the Release: CI That Transforms Organizations
 
Selenium and Appium Training from Sauce Labs
Selenium and Appium Training from Sauce LabsSelenium and Appium Training from Sauce Labs
Selenium and Appium Training from Sauce Labs
 
Scaling your Automated Tests: Docker and Kubernetes
Scaling your Automated Tests: Docker and KubernetesScaling your Automated Tests: Docker and Kubernetes
Scaling your Automated Tests: Docker and Kubernetes
 
Easy Continuous Deployment You Can Trust (Webinar)
Easy Continuous Deployment You Can Trust (Webinar)Easy Continuous Deployment You Can Trust (Webinar)
Easy Continuous Deployment You Can Trust (Webinar)
 
Controlling the browser through python and selenium
Controlling the browser through python and seleniumControlling the browser through python and selenium
Controlling the browser through python and selenium
 
Cross browser Testing JavaScript
Cross browser Testing JavaScriptCross browser Testing JavaScript
Cross browser Testing JavaScript
 
Testing Code.org's Interactive CS Curriculum
Testing Code.org's Interactive CS CurriculumTesting Code.org's Interactive CS Curriculum
Testing Code.org's Interactive CS Curriculum
 
How to Use Selenium, Successfully
How to Use Selenium, SuccessfullyHow to Use Selenium, Successfully
How to Use Selenium, Successfully
 
Selenium
SeleniumSelenium
Selenium
 
Selenium for Jobseekers
Selenium for JobseekersSelenium for Jobseekers
Selenium for Jobseekers
 
Helpful Automation Techniques - Selenium Camp 2014
Helpful Automation Techniques - Selenium Camp 2014Helpful Automation Techniques - Selenium Camp 2014
Helpful Automation Techniques - Selenium Camp 2014
 
Decapitating Selenium with JavaScript
Decapitating Selenium with JavaScriptDecapitating Selenium with JavaScript
Decapitating Selenium with JavaScript
 
Advanced Appium
Advanced AppiumAdvanced Appium
Advanced Appium
 
Automated testing with Cypress
Automated testing with CypressAutomated testing with Cypress
Automated testing with Cypress
 
Continuous Testing in the Cloud
Continuous Testing in the CloudContinuous Testing in the Cloud
Continuous Testing in the Cloud
 
Selenium Testing on Chrome - Google DevFest Armenia 2015
Selenium Testing on Chrome - Google DevFest Armenia 2015Selenium Testing on Chrome - Google DevFest Armenia 2015
Selenium Testing on Chrome - Google DevFest Armenia 2015
 
End to end test automation with cypress
End to end test automation with cypressEnd to end test automation with cypress
End to end test automation with cypress
 
Selenium Tips & Tricks
Selenium Tips & TricksSelenium Tips & Tricks
Selenium Tips & Tricks
 
Testing on Mobile Devices with Location Services
Testing on Mobile Devices with Location ServicesTesting on Mobile Devices with Location Services
Testing on Mobile Devices with Location Services
 
Selenium Conference 2015 - Mobile Selenium Grid Setup
Selenium Conference 2015 - Mobile Selenium Grid SetupSelenium Conference 2015 - Mobile Selenium Grid Setup
Selenium Conference 2015 - Mobile Selenium Grid Setup
 

Similaire à Selenium and Sauce Labs

Selenium at STPCon - Dallas 2011
Selenium at STPCon - Dallas 2011Selenium at STPCon - Dallas 2011
Selenium at STPCon - Dallas 2011
hugs
 
Boston selenium meetup: Selenium 2
Boston selenium meetup: Selenium 2Boston selenium meetup: Selenium 2
Boston selenium meetup: Selenium 2
epall
 
Integration Test Cucumber + Webrat + Selenium
Integration Test Cucumber + Webrat + SeleniumIntegration Test Cucumber + Webrat + Selenium
Integration Test Cucumber + Webrat + Selenium
tka
 
Selenium Tutorial For Beginners | Selenium Automation Testing Tutorial | Sele...
Selenium Tutorial For Beginners | Selenium Automation Testing Tutorial | Sele...Selenium Tutorial For Beginners | Selenium Automation Testing Tutorial | Sele...
Selenium Tutorial For Beginners | Selenium Automation Testing Tutorial | Sele...
Simplilearn
 

Similaire à Selenium and Sauce Labs (20)

Selenium at STPCon - Dallas 2011
Selenium at STPCon - Dallas 2011Selenium at STPCon - Dallas 2011
Selenium at STPCon - Dallas 2011
 
Selenium 2 - PyCon 2011
Selenium 2 - PyCon 2011Selenium 2 - PyCon 2011
Selenium 2 - PyCon 2011
 
Selenium Best Practices with Jason Huggins
Selenium Best Practices with Jason HugginsSelenium Best Practices with Jason Huggins
Selenium Best Practices with Jason Huggins
 
Boston selenium meetup: Selenium 2
Boston selenium meetup: Selenium 2Boston selenium meetup: Selenium 2
Boston selenium meetup: Selenium 2
 
Getting started with Selenium 2
Getting started with Selenium 2Getting started with Selenium 2
Getting started with Selenium 2
 
前端網頁自動測試
前端網頁自動測試 前端網頁自動測試
前端網頁自動測試
 
Integration Test Cucumber + Webrat + Selenium
Integration Test Cucumber + Webrat + SeleniumIntegration Test Cucumber + Webrat + Selenium
Integration Test Cucumber + Webrat + Selenium
 
Browser-level testing
Browser-level testingBrowser-level testing
Browser-level testing
 
Testing Ajax Web Applications
Testing Ajax Web ApplicationsTesting Ajax Web Applications
Testing Ajax Web Applications
 
full-stack-webapp-testing-with-selenium-and-rails.pdf
full-stack-webapp-testing-with-selenium-and-rails.pdffull-stack-webapp-testing-with-selenium-and-rails.pdf
full-stack-webapp-testing-with-selenium-and-rails.pdf
 
Selenium Concepts
Selenium ConceptsSelenium Concepts
Selenium Concepts
 
How to Un-Flake Flaky Tests - A New Hire's Toolkit
How to Un-Flake Flaky Tests - A New Hire's ToolkitHow to Un-Flake Flaky Tests - A New Hire's Toolkit
How to Un-Flake Flaky Tests - A New Hire's Toolkit
 
Selenium testing - Handle Elements in WebDriver
Selenium testing - Handle Elements in WebDriver Selenium testing - Handle Elements in WebDriver
Selenium testing - Handle Elements in WebDriver
 
Selenium
SeleniumSelenium
Selenium
 
Selenium
SeleniumSelenium
Selenium
 
Selenium Tutorial For Beginners | Selenium Automation Testing Tutorial | Sele...
Selenium Tutorial For Beginners | Selenium Automation Testing Tutorial | Sele...Selenium Tutorial For Beginners | Selenium Automation Testing Tutorial | Sele...
Selenium Tutorial For Beginners | Selenium Automation Testing Tutorial | Sele...
 
Automated UI testing. Selenium. DrupalCamp Kyiv 2011
Automated UI testing. Selenium. DrupalCamp Kyiv 2011Automated UI testing. Selenium. DrupalCamp Kyiv 2011
Automated UI testing. Selenium. DrupalCamp Kyiv 2011
 
BCS Selenium Workshop
BCS Selenium WorkshopBCS Selenium Workshop
BCS Selenium Workshop
 
test-automation-selenium-160216124839.pptx
test-automation-selenium-160216124839.pptxtest-automation-selenium-160216124839.pptx
test-automation-selenium-160216124839.pptx
 
How to Un-Flake Flaky Tests - A New Hire's Toolkit
How to Un-Flake Flaky Tests - A New Hire's ToolkitHow to Un-Flake Flaky Tests - A New Hire's Toolkit
How to Un-Flake Flaky Tests - A New Hire's Toolkit
 

Plus de hugs

PinThing
PinThingPinThing
PinThing
hugs
 
The Secret Sauce in the Open Cloud
The Secret Sauce in the Open CloudThe Secret Sauce in the Open Cloud
The Secret Sauce in the Open Cloud
hugs
 

Plus de hugs (11)

Selenium, Appium, and Robots!
Selenium, Appium, and Robots!Selenium, Appium, and Robots!
Selenium, Appium, and Robots!
 
Selenium Conf - Robots
Selenium Conf - RobotsSelenium Conf - Robots
Selenium Conf - Robots
 
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
 
selenium-2-mobile-web-testing
selenium-2-mobile-web-testingselenium-2-mobile-web-testing
selenium-2-mobile-web-testing
 
PinThing
PinThingPinThing
PinThing
 
The Secret Sauce in the Open Cloud
The Secret Sauce in the Open CloudThe Secret Sauce in the Open Cloud
The Secret Sauce in the Open Cloud
 
Orbison Orb - Pycon 2010
Orbison Orb - Pycon 2010Orbison Orb - Pycon 2010
Orbison Orb - Pycon 2010
 
Node.js - JavaScript Chicago Meetup
Node.js - JavaScript Chicago MeetupNode.js - JavaScript Chicago Meetup
Node.js - JavaScript Chicago Meetup
 
WTFV is the new RTFM
WTFV is the new RTFMWTFV is the new RTFM
WTFV is the new RTFM
 
The Future Of Web App Testing and How To Stop It
The Future Of Web App Testing and How To Stop ItThe Future Of Web App Testing and How To Stop It
The Future Of Web App Testing and How To Stop It
 
Hacking Selenium @ JSConf
Hacking Selenium @ JSConfHacking Selenium @ JSConf
Hacking Selenium @ JSConf
 

Dernier

+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 

Dernier (20)

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
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.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
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live StreamsTop 5 Benefits OF Using Muvi Live Paywall For Live Streams
Top 5 Benefits OF Using Muvi Live Paywall For Live Streams
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
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
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
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
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
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
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 

Selenium and Sauce Labs