[Wtr-development] [JIRA] Commented: (WTR-235) Xpath.exist returns different results in Watir and Firewatir.
Shaivya Mahajan (JIRA)
watirjira at gmail.com
Wed Oct 6 17:35:30 EDT 2010
[ http://jira.openqa.org/browse/WTR-235?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=19898#action_19898 ]
Shaivya Mahajan commented on WTR-235:
-------------------------------------
I was having some trouble with firewatir and xpath giving unexpected results.
Found this page when searching for answer, and I was able to reproduce this issue with the following code (running waiter 1.6.5):
------------
require "watir"
site = "http://cukes.info"
ie = Watir::IE.new
ff = FireWatir::Firefox.new
ie.goto site
ff.goto site
puts "IE: ",ie.div(:xpath, "//div[@class='inner']/").exists?
puts "FF: ",ff.div(:xpath, "//div[@class='inner']/").exists?
------------
output i get is:
IE: true
FF: false
> Xpath.exist returns different results in Watir and Firewatir.
> -------------------------------------------------------------
>
> Key: WTR-235
> URL: http://jira.openqa.org/browse/WTR-235
> Project: Watir
> Issue Type: Bug
> Components: FireWatir
> Environment: WinXP Prof SP2, Ruby 1.8, Watir 1.5.6 and Firewatir 1.2.0
> Reporter: Manish Harkut
> Priority: Major
> Fix For: 1.6.0
>
>
> iIndex = 1
> $ie.div(:xpath,'/html/body/div[18]/div[3]/div[2]/div[7]/div/div/div[' + iIndex.to_s + ']').exists?
> The Watir and FireWatir returns different values for the above statement.
> If FireWatir it retuen true which is right and test aare executed properly However in Watir even if when the objects exists it returns false and test fails.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.openqa.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the Wtr-development
mailing list