web application testing with selenium
DESCRIPTION
Slides from presentation at BarcampBrighton in November 2007.TRANSCRIPT
![Page 1: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/1.jpg)
Web Application Testing With Selenium
Kerry Buckley
![Page 2: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/2.jpg)
What’s Selenium?
Created by ThoughtworksUses AJAX & magic
![Page 3: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/3.jpg)
What’s Selenium?
• Web testing framework
Created by ThoughtworksUses AJAX & magic
![Page 4: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/4.jpg)
What’s Selenium?
• Web testing framework
• Runs in a browser
Created by ThoughtworksUses AJAX & magic
![Page 5: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/5.jpg)
What’s Selenium?
• Web testing framework
• Runs in a browser
• HTML & Javascript
Created by ThoughtworksUses AJAX & magic
![Page 6: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/6.jpg)
What’s Selenium?
• Web testing framework
• Runs in a browser
• HTML & Javascript
• Open source
Created by ThoughtworksUses AJAX & magic
![Page 7: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/7.jpg)
What’s Selenium?
• Web testing framework
• Runs in a browser
• HTML & Javascript
• Open source
• http://openqa.org/
Created by ThoughtworksUses AJAX & magic
![Page 8: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/8.jpg)
Four Flavours
![Page 9: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/9.jpg)
Four Flavours
• Selenium Core
![Page 10: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/10.jpg)
Four Flavours
• Selenium Core
• Selenium IDE
![Page 11: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/11.jpg)
Four Flavours
• Selenium Core
• Selenium IDE
• Selenium Remote Control (RC)
![Page 12: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/12.jpg)
Four Flavours
• Selenium Core
• Selenium IDE
• Selenium Remote Control (RC)
• Selenium on Rails
![Page 13: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/13.jpg)
Application
Selenium Core
Browser
Just HTML and Javascript, so can be installed in any web/app server.Install at any convenient path, as long as it’s onthe same server (host & port).Don’t deploy to live!
![Page 14: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/14.jpg)
Selenium Core
Application
Browser
Selenium
Just HTML and Javascript, so can be installed in any web/app server.Install at any convenient path, as long as it’s onthe same server (host & port).Don’t deploy to live!
![Page 15: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/15.jpg)
Selenium Core
Application
Browser
Selenium
Just HTML and Javascript, so can be installed in any web/app server.Install at any convenient path, as long as it’s onthe same server (host & port).Don’t deploy to live!
![Page 16: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/16.jpg)
Selenium RC
Application
Browser
No need to change application.Server launches, drives and kills browser(s).Acts as proxy to get round same-source policy.
![Page 17: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/17.jpg)
Selenium RC
Application
Browser
SeleniumServer
No need to change application.Server launches, drives and kills browser(s).Acts as proxy to get round same-source policy.
![Page 18: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/18.jpg)
Selenium RC
Application
Browser
SeleniumServer
Tests
No need to change application.Server launches, drives and kills browser(s).Acts as proxy to get round same-source policy.
![Page 19: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/19.jpg)
Selenium RC
Application
Browser
SeleniumServer
Tests
No need to change application.Server launches, drives and kills browser(s).Acts as proxy to get round same-source policy.
![Page 20: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/20.jpg)
Selenium RC
Application
Browser
SeleniumServer
Tests
No need to change application.Server launches, drives and kills browser(s).Acts as proxy to get round same-source policy.
![Page 21: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/21.jpg)
Browser
Selenium IDE
Application
Firefox plugin. Single browser, but cross-platform.Record, edit and playback.Import/export various formats (HTML tables is default, like Selenium).
![Page 22: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/22.jpg)
Selenium IDE
Application
BrowserSelenium
Firefox plugin. Single browser, but cross-platform.Record, edit and playback.Import/export various formats (HTML tables is default, like Selenium).
![Page 23: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/23.jpg)
Selenium IDE
Application
BrowserSelenium
Firefox plugin. Single browser, but cross-platform.Record, edit and playback.Import/export various formats (HTML tables is default, like Selenium).
![Page 24: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/24.jpg)
Selenium on Rails
Application
Browser
Selenium
Only runs in test mode, so you don’t need to remove it to deploy.
![Page 25: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/25.jpg)
Selenium on Rails
Application
Browser
SeleniumRails
Magic
Only runs in test mode, so you don’t need to remove it to deploy.
![Page 26: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/26.jpg)
Pros and Cons
![Page 27: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/27.jpg)
Pros and Cons
• Runs using a real browser
![Page 28: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/28.jpg)
Pros and Cons
• Runs using a real browser
• Cross-platform & cross-browser
![Page 29: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/29.jpg)
Pros and Cons
• Runs using a real browser
• Cross-platform & cross-browser
• Language-agnostic
![Page 30: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/30.jpg)
Pros and Cons
• Runs using a real browser
• Cross-platform & cross-browser
• Language-agnostic
• Hard to test across hosts or ports
![Page 31: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/31.jpg)
Pros and Cons
• Runs using a real browser
• Cross-platform & cross-browser
• Language-agnostic
• Hard to test across hosts or ports
• including SSL/non-SSL
![Page 32: Web application testing with Selenium](https://reader035.vdocuments.net/reader035/viewer/2022081412/545399b8b1af9f84228b4695/html5/thumbnails/32.jpg)
Demo