SlideShare a Scribd company logo
AUTOMATED WEB TESTING
使用SELENIUM
劉昱劭
什麼是SELENIUM
 http://docs.seleniumhq.org/
 簡言之就是瀏覽器自動化工具
 用來測試 web-based applications
 目前最popular的Web自動化測試工具, google、facebook…
 Developed by Jason Huggins in 2004
 Open source software under Apache 2.0 license
SELENIUM特點(1)
 可針對多種瀏覽器進行測試
 GoogleChrome
 Internet Explorer 6, 7, 8, 9, 10 - 32 and 64-bit where applicable
 Firefox: latest ESR, previous ESR, current release, one previous release
 Safari
 Opera
 HtmlUnit
 phantomjs
 Android (with Selendroid or appium)
 iOS (with ios-driver or appium)
SELENIUM特點(2)
 支援多種語言
 Java
 C#
 Python
 Ruby
 PHP
 Javascript
 跨平台
 Windows、Linux、iOS、Android
 Open Source 免費
 簡單、易用、可維護
SELENIUM的組成
 Selenium 1.0
 Selenium RC(remote control)
 ClientAPI 1.0 ( Java,C#, Ruby and Python …)
 RC is a server writing in Java
 Selenium IDE
 Firefox plugin
 Selenium 2.0
 SeleniumWebdriver
 ClientAPI 2.0
 Selenium Grid
SELENIUM IDE(1)
 Firefox
 http://docs.seleniumhq.org/download/
SELENIUM IDE(2)
SELENIUM IDE(3)
 錄制->轉換成動作
 搭配Firebug
 Xpath
 Css Path
 SaveTest Case
 Example
 Login
 AddEDM
 AddSMS
 CheckStatus
SELENIUM IDE(4)
SELENIUM RC
 selenium-server-standalone-2.39.0.jar
 java -jar selenium-server-standalone-2.39.0.jar -htmlSuite "*firefox"
"https://crm2.hisales.hinet.net" "S.html" "result.html"
SELENIUMWEBDRIVER
PYTHON WEBDRIVER (API 2.0)
PYTHON RC (API 1.0)
用途
 UnitTest(PG)
 版本基本功能驗證(PM、SA)
 用各種不同資料進行重複測試(QA)
 上線系統監控測試
參考資料
 python - 撰寫 selenium 自動化測試流程 (一)
 http://www.dotblogs.com.tw/chhuang/archive/2012/09/13/74760.aspx
 Selenium自動化測試指南
 Web UI 測試的好幫手 - Selenium
 http://www.jaceju.net/blog/archives/1293/
 http://docs.seleniumhq.org/docs/
 http://en.wikipedia.org/wiki/Selenium_(software)

More Related Content

Viewers also liked

Victor Dyptan.Using Selenium IDE for automated testing.Drupal Camp Kyiv 2011
Victor Dyptan.Using Selenium IDE for automated testing.Drupal Camp Kyiv 2011Victor Dyptan.Using Selenium IDE for automated testing.Drupal Camp Kyiv 2011
Victor Dyptan.Using Selenium IDE for automated testing.Drupal Camp Kyiv 2011
camp_drupal_ua
 
Automation Testing
Automation TestingAutomation Testing
Automation Testing
Vladimir Soghoyan
 
Automation Testing using Selenium
Automation Testing using SeleniumAutomation Testing using Selenium
Automation Testing using Selenium
Fizah Ali
 
Selenium
SeleniumSelenium
Selenium
傑倫 鍾
 
Automated Testing for Websites With Selenium IDE
Automated Testing for Websites With Selenium IDEAutomated Testing for Websites With Selenium IDE
Automated Testing for Websites With Selenium IDE
Robert Greiner
 
Test Automation and Selenium
Test Automation and SeleniumTest Automation and Selenium
Test Automation and Selenium
Karapet Sarkisyan
 
Selenium IDE
Selenium IDESelenium IDE
Selenium IDE
jaguardesignstudio
 
Selenium (1)
Selenium (1)Selenium (1)
Selenium (1)
onlinemindq
 
Smarter ways to do selenium automation @ work, Selenium, automation
Smarter ways to do selenium automation @ work, Selenium, automationSmarter ways to do selenium automation @ work, Selenium, automation
Smarter ways to do selenium automation @ work, Selenium, automation
RIA RUI Society
 
Fin fest 2014 - Internet of Things and APIs
Fin fest 2014 - Internet of Things and APIsFin fest 2014 - Internet of Things and APIs
Fin fest 2014 - Internet of Things and APIs
Robert Greiner
 
Web Test Automation with Selenium
Web Test Automation with SeleniumWeb Test Automation with Selenium
Web Test Automation with Selenium
vivek_prahlad
 
Automation Testing using Selenium
Automation Testing using SeleniumAutomation Testing using Selenium
Automation Testing using Selenium
Naresh Chintalcheru
 

Viewers also liked (12)

Victor Dyptan.Using Selenium IDE for automated testing.Drupal Camp Kyiv 2011
Victor Dyptan.Using Selenium IDE for automated testing.Drupal Camp Kyiv 2011Victor Dyptan.Using Selenium IDE for automated testing.Drupal Camp Kyiv 2011
Victor Dyptan.Using Selenium IDE for automated testing.Drupal Camp Kyiv 2011
 
Automation Testing
Automation TestingAutomation Testing
Automation Testing
 
Automation Testing using Selenium
Automation Testing using SeleniumAutomation Testing using Selenium
Automation Testing using Selenium
 
Selenium
SeleniumSelenium
Selenium
 
Automated Testing for Websites With Selenium IDE
Automated Testing for Websites With Selenium IDEAutomated Testing for Websites With Selenium IDE
Automated Testing for Websites With Selenium IDE
 
Test Automation and Selenium
Test Automation and SeleniumTest Automation and Selenium
Test Automation and Selenium
 
Selenium IDE
Selenium IDESelenium IDE
Selenium IDE
 
Selenium (1)
Selenium (1)Selenium (1)
Selenium (1)
 
Smarter ways to do selenium automation @ work, Selenium, automation
Smarter ways to do selenium automation @ work, Selenium, automationSmarter ways to do selenium automation @ work, Selenium, automation
Smarter ways to do selenium automation @ work, Selenium, automation
 
Fin fest 2014 - Internet of Things and APIs
Fin fest 2014 - Internet of Things and APIsFin fest 2014 - Internet of Things and APIs
Fin fest 2014 - Internet of Things and APIs
 
Web Test Automation with Selenium
Web Test Automation with SeleniumWeb Test Automation with Selenium
Web Test Automation with Selenium
 
Automation Testing using Selenium
Automation Testing using SeleniumAutomation Testing using Selenium
Automation Testing using Selenium
 

Similar to Automated Web Testing Using Selenium

Windows 8.1 app 研習營三小時
Windows 8.1 app 研習營三小時Windows 8.1 app 研習營三小時
Windows 8.1 app 研習營三小時
Meng-Ru (Raymond) Tsai
 
第一次 Mobile App 就上手
第一次 Mobile App 就上手第一次 Mobile App 就上手
第一次 Mobile App 就上手Ying-Hsiang Liao
 
Appium手机自动化测试 testerhome_bqcon版本
Appium手机自动化测试 testerhome_bqcon版本Appium手机自动化测试 testerhome_bqcon版本
Appium手机自动化测试 testerhome_bqcon版本
延胜 黄
 
Web development overview
Web development overviewWeb development overview
Web development overviewWei Sun
 
Creating an Open Source Project: 0-100k Users - China Mobile Summit 2015 - CN
Creating an Open Source Project: 0-100k Users - China Mobile Summit 2015 - CNCreating an Open Source Project: 0-100k Users - China Mobile Summit 2015 - CN
Creating an Open Source Project: 0-100k Users - China Mobile Summit 2015 - CN
Dan Cuellar
 
Selenium私房菜(新手入门教程)
Selenium私房菜(新手入门教程)Selenium私房菜(新手入门教程)
Selenium私房菜(新手入门教程)liqiang xu
 
Selenium私房菜(新手入门教程)
Selenium私房菜(新手入门教程)Selenium私房菜(新手入门教程)
Selenium私房菜(新手入门教程)bwgang
 
闲话浏览器兼容
闲话浏览器兼容闲话浏览器兼容
闲话浏览器兼容
癸鑫 张
 
Android JNI
Android JNIAndroid JNI
Android JNI
艾鍗科技
 
開放原始碼作為新事業: 台灣本土經驗談 (COSCUP 2011)
開放原始碼作為新事業: 台灣本土經驗談 (COSCUP 2011)開放原始碼作為新事業: 台灣本土經驗談 (COSCUP 2011)
開放原始碼作為新事業: 台灣本土經驗談 (COSCUP 2011)
National Cheng Kung University
 
Web前端开发工具介绍
Web前端开发工具介绍Web前端开发工具介绍
Web前端开发工具介绍solorez fer
 
常用开发工具介绍
常用开发工具介绍常用开发工具介绍
常用开发工具介绍
haozes
 
Software Engineer Talk
Software Engineer TalkSoftware Engineer Talk
Software Engineer Talk
Larry Cai
 
用 Drone 打造 輕量級容器持續交付平台
用 Drone 打造輕量級容器持續交付平台用 Drone 打造輕量級容器持續交付平台
用 Drone 打造 輕量級容器持續交付平台
Bo-Yi Wu
 
豆瓣I os自动化测试实践和经验
豆瓣I os自动化测试实践和经验豆瓣I os自动化测试实践和经验
豆瓣I os自动化测试实践和经验drewz lin
 
開放原始碼 Ch2.1 app - oss - oss ide (ver1.2)
開放原始碼 Ch2.1   app - oss - oss ide (ver1.2)開放原始碼 Ch2.1   app - oss - oss ide (ver1.2)
開放原始碼 Ch2.1 app - oss - oss ide (ver1.2)My own sweet home!
 
Appcan移动应用开发平台介绍120409
Appcan移动应用开发平台介绍120409Appcan移动应用开发平台介绍120409
Appcan移动应用开发平台介绍120409zhengyiwuxian
 
PHPUnit slide formal
PHPUnit slide formalPHPUnit slide formal
PHPUnit slide formaljameslabs
 
HTML5 生态系统和应用架构模型
HTML5 生态系统和应用架构模型HTML5 生态系统和应用架构模型
HTML5 生态系统和应用架构模型Tom Fan
 
開放原始碼 Ch3.1 mobile - oss - oss行動領域-1 (ver1.0)
開放原始碼 Ch3.1  mobile - oss - oss行動領域-1 (ver1.0) 開放原始碼 Ch3.1  mobile - oss - oss行動領域-1 (ver1.0)
開放原始碼 Ch3.1 mobile - oss - oss行動領域-1 (ver1.0) My own sweet home!
 

Similar to Automated Web Testing Using Selenium (20)

Windows 8.1 app 研習營三小時
Windows 8.1 app 研習營三小時Windows 8.1 app 研習營三小時
Windows 8.1 app 研習營三小時
 
第一次 Mobile App 就上手
第一次 Mobile App 就上手第一次 Mobile App 就上手
第一次 Mobile App 就上手
 
Appium手机自动化测试 testerhome_bqcon版本
Appium手机自动化测试 testerhome_bqcon版本Appium手机自动化测试 testerhome_bqcon版本
Appium手机自动化测试 testerhome_bqcon版本
 
Web development overview
Web development overviewWeb development overview
Web development overview
 
Creating an Open Source Project: 0-100k Users - China Mobile Summit 2015 - CN
Creating an Open Source Project: 0-100k Users - China Mobile Summit 2015 - CNCreating an Open Source Project: 0-100k Users - China Mobile Summit 2015 - CN
Creating an Open Source Project: 0-100k Users - China Mobile Summit 2015 - CN
 
Selenium私房菜(新手入门教程)
Selenium私房菜(新手入门教程)Selenium私房菜(新手入门教程)
Selenium私房菜(新手入门教程)
 
Selenium私房菜(新手入门教程)
Selenium私房菜(新手入门教程)Selenium私房菜(新手入门教程)
Selenium私房菜(新手入门教程)
 
闲话浏览器兼容
闲话浏览器兼容闲话浏览器兼容
闲话浏览器兼容
 
Android JNI
Android JNIAndroid JNI
Android JNI
 
開放原始碼作為新事業: 台灣本土經驗談 (COSCUP 2011)
開放原始碼作為新事業: 台灣本土經驗談 (COSCUP 2011)開放原始碼作為新事業: 台灣本土經驗談 (COSCUP 2011)
開放原始碼作為新事業: 台灣本土經驗談 (COSCUP 2011)
 
Web前端开发工具介绍
Web前端开发工具介绍Web前端开发工具介绍
Web前端开发工具介绍
 
常用开发工具介绍
常用开发工具介绍常用开发工具介绍
常用开发工具介绍
 
Software Engineer Talk
Software Engineer TalkSoftware Engineer Talk
Software Engineer Talk
 
用 Drone 打造 輕量級容器持續交付平台
用 Drone 打造輕量級容器持續交付平台用 Drone 打造輕量級容器持續交付平台
用 Drone 打造 輕量級容器持續交付平台
 
豆瓣I os自动化测试实践和经验
豆瓣I os自动化测试实践和经验豆瓣I os自动化测试实践和经验
豆瓣I os自动化测试实践和经验
 
開放原始碼 Ch2.1 app - oss - oss ide (ver1.2)
開放原始碼 Ch2.1   app - oss - oss ide (ver1.2)開放原始碼 Ch2.1   app - oss - oss ide (ver1.2)
開放原始碼 Ch2.1 app - oss - oss ide (ver1.2)
 
Appcan移动应用开发平台介绍120409
Appcan移动应用开发平台介绍120409Appcan移动应用开发平台介绍120409
Appcan移动应用开发平台介绍120409
 
PHPUnit slide formal
PHPUnit slide formalPHPUnit slide formal
PHPUnit slide formal
 
HTML5 生态系统和应用架构模型
HTML5 生态系统和应用架构模型HTML5 生态系统和应用架构模型
HTML5 生态系统和应用架构模型
 
開放原始碼 Ch3.1 mobile - oss - oss行動領域-1 (ver1.0)
開放原始碼 Ch3.1  mobile - oss - oss行動領域-1 (ver1.0) 開放原始碼 Ch3.1  mobile - oss - oss行動領域-1 (ver1.0)
開放原始碼 Ch3.1 mobile - oss - oss行動領域-1 (ver1.0)
 

More from 昱劭 劉

設計模式的解析與活用讀後心得
設計模式的解析與活用讀後心得設計模式的解析與活用讀後心得
設計模式的解析與活用讀後心得昱劭 劉
 
Python開發環境建立(使用ECLIPSE)
Python開發環境建立(使用ECLIPSE)Python開發環境建立(使用ECLIPSE)
Python開發環境建立(使用ECLIPSE)昱劭 劉
 
持續整合與單元測試
持續整合與單元測試持續整合與單元測試
持續整合與單元測試昱劭 劉
 
透過Nuget管理內部共用元件
透過Nuget管理內部共用元件透過Nuget管理內部共用元件
透過Nuget管理內部共用元件昱劭 劉
 
Restful & odata using asp.net web api
Restful & odata using asp.net web apiRestful & odata using asp.net web api
Restful & odata using asp.net web api
昱劭 劉
 
Mongo db 簡介
Mongo db 簡介Mongo db 簡介
Mongo db 簡介昱劭 劉
 

More from 昱劭 劉 (6)

設計模式的解析與活用讀後心得
設計模式的解析與活用讀後心得設計模式的解析與活用讀後心得
設計模式的解析與活用讀後心得
 
Python開發環境建立(使用ECLIPSE)
Python開發環境建立(使用ECLIPSE)Python開發環境建立(使用ECLIPSE)
Python開發環境建立(使用ECLIPSE)
 
持續整合與單元測試
持續整合與單元測試持續整合與單元測試
持續整合與單元測試
 
透過Nuget管理內部共用元件
透過Nuget管理內部共用元件透過Nuget管理內部共用元件
透過Nuget管理內部共用元件
 
Restful & odata using asp.net web api
Restful & odata using asp.net web apiRestful & odata using asp.net web api
Restful & odata using asp.net web api
 
Mongo db 簡介
Mongo db 簡介Mongo db 簡介
Mongo db 簡介
 

Automated Web Testing Using Selenium