兩個WEB自動化測試工具比較 WatiN & Selenium RC

兩個WEB自動化測試工具比較 WatiN & Selenium RC
 
Item
WatiN
Explorer Supported
Known work
Ø  IE 6 and IE 7
Known work

Ø  IE 6 and IE 7

Ø  Firefox 1.5.0 and 2.0

Ø  Opera 8.5.4 and 9.0.2

Should work

Ø  Firefox 0.8 to 2.0

Ø  Mozilla Suite 1.6+, 1.7+

Ø  Sea monkey 1.0

System supported
Known work
Ø  Windows XP and 2003
Known work
Ø  Windows XP and 2003
Ø  Windows 2000(need to install install reg.exein order to use IE)
Ø  Mac OS X
Ø  Linux
Language supported
Ø  C#
Ø  C#
Ø  Java
Ø  Perl
Ø  PHP
Ø  Python
Ø  Ruby
Test environment supported
Ø  Visual Studio 2005 Team System
Ø  Visual Studio 2005 Team System
AJAX
Supports AJAX website testing
l  Selenium Server communicates directly with the browser using AJAX (XmlHttpRequest)

l  The Selenium Server is great for testing complex AJAX-based web user interfaces under a Continuous Integration system

Get/Post requests

 

We can send commands directly to the Server using simple HTTP GET/POST requests

Https supported

 

Support for https
Javascrīpt Supported
Void Document.Runscrīpt(string)
l  We can write selenium RC tests in Javascrīpt with JsUnit.
l  it Allows a Selenium-enabled browser to run Javascrīpt on arbitrary websites.
HTML
Automates all major HTML elements and find elements by multiple attributes

 

HTML dialogs
Supports HTML dialogs (modal and modeless)

 

Frame
Supports frame (Cross domain) and iframes

 

Popup dialogs
Supports popup dialogs like alert, confirm, login etc

 

Screenshots
Support creating screenshots of web pages

 

 

 

對現有控件的兼容性不好。比如文件上傳控件和日曆控件就無法在Selenium RC中捕捉
2.
不支持https連接方式??

http://bbs.51testing.com/thread-84131-1-6.html

Developing Info

Item
WatiN
Selenium RC
Developing Language
Ø  C#
Ø  Java and so on

Methods Example

Item
WatiN Example
Selenium RC Example
Set  element
event
Document.button(Find.ById(btnG”)).click()
DefaultSelenium.Type(“q”,”hello world”)
Get element attributes
Document.button (Find.ById(btnG”)).Style. Height
DefaultSelenium.GetElementHeight(“q”)
especial methods
                             
Then we can’t hanle the time used for pages loading.
                           ===

 

 

 

Ø  Link[1].Click()
Ø  Link(Find.ByIndex(1)).Click()
We can use these two methods to click the links that the value is null.
Ø  WaitForPageToLoad(“5000”)
(if we want to go to another page and get the elements in the new page, we have to use the method, or we will in the old page.)

 

 

==    We can’t find the links that the value is null
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章