Questions tagged [watir-webdriver]

Watir (Web Application Testing in Ruby) implementation built on WebDriver's Ruby bindings. Used for web browser automation, this tool allows you to code in Ruby using the friendly Watir API but get the cross browser support of Webdriver to automate Chrome, Firefox, IE, Opera or a 'headless' browser. Distributed as a Ruby gem named 'watir-webdriver'

For those who don’t know what Watir-WebDriver is, it’s basically a nice Watir (ruby) implementation on WebDriver, so it gives you five browsers (four real, one headless) using one neat API, out of the box.

The Watir API uses an object model that parallels the HTML element model and the browser DOM. This allows you to write very natural OOP code where you can have a button in the UI click itself. (as opposed to Selenium where the 'browser' object does everything, and takes the elements as parameters for methods like click.

See: watirwebdriver.com

1623 questions
0
votes
1 answer

Can this reflective method be written with a single parameter instead of two?

This is primarily a Ruby question but I've tagged it with watir-webdriver because the example includes watir-webdriver code in the hopes that it will improve clarity. I have a class that can both retrieve and update data found on a web page. That…
Abe Heward
  • 515
  • 3
  • 16
0
votes
1 answer

StaleElementReferenceError When Search for regex Using Watir-WebDriver

I'm encountering an error when attempting to search for regexes within a page. I used the following to actually locate the regex, but I'm receiving various errors. ... browser.script.html.include? "event49" The errors seem to be browser (and…
0
votes
1 answer

Watir-webdriver, cannot interact with a div popup

I cannot figure out a way to interact with the highlighted HTML: When I click on a link, an interactive modal appears, which has a table to allow user to buy parts. Also, the modal has links that open up new sections within the modal. I have tried…
Azher
  • 493
  • 5
  • 18
0
votes
1 answer

Click event processes but watir-webdriver / selenium-webdriver still throws a TimeoutError on faster Macs

Gems in use: watir-webdriver-0.6.2 selenium-webdriver-2.27.2 Using Firefox 16.0.2 on all systems. Situation: We have a modal window that closes after we run link(:text, 'Continue').click System 1: Hardware Overview: Model Name: MacBook…
Kris Robison
  • 698
  • 7
  • 13
0
votes
1 answer

Timeout error when using "exists" watir-webdriver method

As far as searching goes, i was unable to find an up-to-date list of supported browsers for watir. I've just upgraded firefox to version 18, and while at it, also update the watir-webdriver version to it's latest (by using gem update…
Asaf Blum
  • 27
  • 1
  • 3
0
votes
1 answer

Can we automate functional testcases using WATIR for IE in headless mode?

I want to automate a few work flows of my web application using watir-webdriver. I am using Ubuntu. I want to automate all the workflows on IE. As i am using ubuntu as my platform, need to run it in headless mode. Any suggestions?
Aashish P
  • 1,894
  • 5
  • 22
  • 36
0
votes
1 answer

How to improve performance of Watir element.present? method?

I experience IMO high delays with the Ruby script using Watir. Here's the problem description: I am testing AJAX based application and I wanted to avoid using of sleep to make sure page gets loaded: class Page attr_accessor :expected_elements …
tom
  • 123
  • 1
  • 11
0
votes
2 answers

How to set the checkbox in the first column based on the value in the second column?

I'm automating a task using Ruby and Watir. I want to set a checkbox (which is in the first column of a table) based on whether the value in the second column matches my input value. For example, in the following code snippet, the value "brett58"…
Waltz
  • 41
  • 8
0
votes
2 answers

how to open pop up window table using selenium webdriver?

there is text label on a webpage, and I am trying to click on that to open a pop-up window,but not getting opened. here is the HTML code:
CodeLover
  • 1,054
  • 6
  • 24
  • 40
0
votes
1 answer

How to measure the page loading time in yaml file by cucumber with watir-webdriver performance gem?

I want to measure the time of loading the page. I use watir-webdriver performance gem and this code: 5.times do @b.goto ("#{@host}") puts "Load Time: #{@b.performance.summary[:response_time]/1000.000} seconds." end But now I need to produce…
Kurt Russell
  • 225
  • 1
  • 3
  • 15
0
votes
1 answer

How to go back in the window with cucumber and watir web-driver?

I need to go back in the browser. How can I make it with cucumber? I use watir web-driver. And how can I close pop up in window?
Kurt Russell
  • 225
  • 1
  • 3
  • 15
0
votes
1 answer

Using xpath vs span to get elements (one works on IE and Firefox but the other one only in IE)

I am new to Watir framework and we have a code like $browser.link(:xpath, "//a[@href='/servlets/ProcessAction?identifier=createMemberAccountTypes&click1=Accounts_Open']").click . But this works well on IE but not on Firefox always. So we use…
WowBow
  • 7,137
  • 17
  • 65
  • 103
0
votes
2 answers

NameError: undefined local variable or method `desired_preferences'

I have created a module with a method module Adding_preferences def desired_preferences @preference = %w(motabilitySpecialist newCars bodyshop filter8 filter7).each do |selection| @browser.label(:for, selection…
user1875703
  • 159
  • 2
  • 5
  • 14
0
votes
3 answers

Cross browser click in watir-webdriver

I'm using Watir-Webdriver to do automation testing. But it seem not stable for cross browser. For example, it usually work fine in Firefox and Chrome but are not stable in IE. When I get an element and do a click, in ie7,8,9 it response in a…
ndh103
  • 96
  • 1
  • 6
0
votes
1 answer

Cannot get if, elsif steps to work (watir-webdriver)

I am using watir-webdriver. Here is my step def, can someone correct me what I am doing wrong here. I am trying to sign up using a set of details. If first set of details are already used I want it to use the second set of details and so forth.…
Azher
  • 493
  • 5
  • 18
1 2 3
99
100