Automated Web Testing Using Selenium

390 views
283 views

Published on

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
390
On SlideShare
0
From Embeds
0
Number of Embeds
12
Actions
Shares
0
Downloads
6
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Automated Web Testing Using Selenium

  1. 1. AUTOMATED WEB TESTING 使用SELENIUM 劉昱劭
  2. 2. 什麼是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
  3. 3. 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)
  4. 4. SELENIUM特點(2)  支援多種語言  Java  C#  Python  Ruby  PHP  Javascript  跨平台  Windows、Linux、iOS、Android  Open Source 免費  簡單、易用、可維護
  5. 5. 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
  6. 6. SELENIUM IDE(1)  Firefox  http://docs.seleniumhq.org/download/
  7. 7. SELENIUM IDE(2)
  8. 8. SELENIUM IDE(3)  錄制->轉換成動作  搭配Firebug  Xpath  Css Path  SaveTest Case  Example  Login  AddEDM  AddSMS  CheckStatus
  9. 9. SELENIUM IDE(4)
  10. 10. 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"
  11. 11. SELENIUMWEBDRIVER
  12. 12. PYTHON WEBDRIVER (API 2.0)
  13. 13. PYTHON RC (API 1.0)
  14. 14. 用途  UnitTest(PG)  版本基本功能驗證(PM、SA)  用各種不同資料進行重複測試(QA)  上線系統監控測試
  15. 15. 參考資料  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)

×