Skip to main content

Posts

Showing posts from June, 2012

How to Read or Select Context Menu or Right Click Menu using QTP.

Select The Item in Right Click Menu or Context Menu: Window("sampleWindow").WinMenu("MenuObjType:=1).Select"File;New" Here MenuObjtype can be 1 r 2 r 3 .......n Check wether the Item is Exist or Not: If Window("sampleWindow").WinMenu("MenuObjType:=1).GetItemProperty("1","Exist") Then   Msgbox"Exist" Else  Msgbox"Does Not Exist" End If                                         Or If Window("sampleWindow").WinMenu("MenuObjType:=1).GetItemProperty("File","Exist") Then   Msgbox"Exist" Else  Msgbox"Does Not Exist" End If Get the Items in Context Menu: For i = 1 to 10 Print  Window("sampleWindow").WinMenu("MenuObjType:=" & i).GetItemProperty("1","Label") Then Next

Broad comparison among QTP and Selenum

# Selenium QTP 1 Open source Paid tool 2 Works on all OS Works on Windows 3 Tests only Web applications Tests web and desktop applications 4 Works on almost all browsers Works on IE ,Firefox and Chrome(Partially) 5 Code can be made in any one of languages such as Java, C#, Ruby, Python, pearl, php etc Uses Vb Script 6 No object repository Has got an object repository 7 IDE sometimes does not record some events Recording is a little reliable events 8 Core engine is java script and is very strong Core engine is not java script based

Broad comparison among QTP and Selenium

Sr. What HP QTP has What Selenium has 1 QTP is ideally suited for browser based testing Selenium too can very well do browser based testing 2 QTP is licensed software & requires license costs that are quite a bit. Selenium is an open source tool that doesn’t cost anything 3 QTP is quite easy to use. It is quite easy to edit the script, parameterize, navigate, playback & validate the results. For using Selenium one needs to have programming skills. 4 QTP is quite easy to learn in a short time. Selenium needs quite a bit of expertise compared to QTP. 5 QTP offers great benefit of the support for Business Process Testing. Selenium users don’t enjoy such benefits 6 QTP comes powered with several add-ins by which user can comfortably work with Web, Windows,

Selenium useful Links

For Documentation : http://seleniumhq.org/docs/01_introducing_selenium.html http://www.seleniumwiki.com/   Sample Script using Testng-eclipse: http://www.seleniumwiki.com/selenium-rc/sample-selenium-rc-script-using-testng-eclipse/