firewatir

firefox not opening - cron, ruby, firewatir

I have written a ruby script which opens up dlink admin page in firefox and does a ADSL connection or disconnection. I could run this script in the terminal without any problem. But if I put it as cron job, it doesn't fire up firefox. This is the entry I have in crontab # connect to dataone 55 17 * * * ruby /home/raguanu/Dropbox/netti...

Is this the proper way of denying remote connections to jssh on Linux ?

I don't know if jssh has any security built-in. While testing web apps, I would only like to be able to connect to jssh from localhost. I added the following lines to iptables : iptables -A INPUT -p tcp -s 0/0 --dport 9997 -j LOG iptables -A INPUT -p tcp -s 0/0 --dport 9997 -j DROP will they provide the security I need? EDIT : this ...

Firefox JSSH Connection or very detailed compile steps on Ubuntu 64?

Hi there, I'm having a hard time getting jssh and firefox to play nice on an Ubuntu Jaunty 64-bit machine. Anyone know the specific steps needed to make this work? (or, if you're using something else to get firewatir to work, I'll take those as answers as well) Here are a few things I tried: installing the jssh extension by itself (by...

getting firewatir to run on mac osx: jssh problems

I am trying to get firewatir to run on Mac OSX Leopard. I have Firefox 3.6rc2 installed but running the most simple script does not work: require 'rubygems' require 'firewatir' ff=FireWatir::Firefox.new ff.goto("http://mail.yahoo.com") i am getting the following error /usr/local/lib/ruby/gems/1.8/gems/firewatir-1.6.5/lib/firewatir/f...

Ruby Watir: Clicking OK on JavaScript Alerts?

Seems none of the code I've tried has any affect. My intention is to close any and all JavaScript prompts that may come up by hitting the "OK" button. Problem is, my script has no affect on the prompts that come up. In other words, it does nothing. Here's what I have: fx = FireWatir::Firefox.start(somepage) fx.startClicker("OK") fx.but...

FireWatir and jQuery

Hello there, after using this excellent peace of software called FireWatir, I wonder if there is a way to integrate jQuery-selector-magic to my test. My first attempt is to use firewatir's js_eval() method like this require 'rubygems' require 'firewatir' f = FireWatir::Firefox.new f.js_eval("alert(42);") The only thing I get is a ...

How to script elements embedded within an <iFrame> tag?

Hi, I am using Firefox and i have a page which has an <iframe> Tag. The contents embedded within this tag cannot be seen from normal "View Page source" option. So i installed Firebug plugin and i can get see the contents using Firebug. My issue is, i cannot script any of these elements using FireWatir. Anybody has any ideas how to do...

Mouse movement / mouseover and JavaScript evaluation in watir

I have a JavaScript-heavy Rails app which I am testing in watir. I have two specific testing requirements: I need to be able to simulate moving the mouse to a specific area of the screen (or at least triggering the onmouseover event for a div) Evaluating a snippet of JavaScript once the above has happened to see if a flag is set correc...

How to do Basic Authentication using FireWatir on Ubuntu Linux?

Hi, I'm trying to use FireWatir (1.6.5) to access a site using Basic Authentication and I've been unable to find a solution that works on Firefox in Linux. Does FireWatir 1.6.5 support Basic Authentication on Linux? I've been searching the web for 2 days and can't get a straight answer anywhere as to how to do this. The only thread I...

Initiate Button click action using Watir Ruby library

Watir::Browser.default = "firefox" ie = Watir::Browser.start("http://cars.com") ie.select_list(:id, 'make_1').set('Chevrolet') ie.select_list(:id, 'model_1').set('Cobalt') ie.select_list(:id, 'pricehighnew').set('No Max') ie.select_list(:id, 'rdnew').set('30 miles') ie.text_field(:name, "zc").set "44109" ie.form(:method, ...

Problem between IE and FF testing a login

This is so simple that I am stunned it is failing. I am testing a very simply login sequence and essentially my code does this: require "watir" user = "[email protected]" pswd = "qwerty" br = Watir::Browser.new br.goto("http://mysite.com") br.link(:id,"login-menu").click # click the login menu br.text_field(:id,"l...

Trouble find elements with fireWatir on a JQuery created page

I am having a problem identifying a label on a jQuery generated page. This is the code of the page (as seen in firebug). I am trying to find it using this statement, assert(browser.label(:id, "acms-ws-select-label").exists?) Put it fails to find the label. Any ideas on what I am doing wrong? Update: running the same script in IE wi...

WATIR/ FireWATIR URL consistency?

We are at the start of a project to test a new web application written in jQuery and are planning to do it using WATIR and FireWATIR. During the proof of concepts test I've discovered differences in how WATIR and FireWATIR represent URLs, for example a script which passes in FireWATIR generates this error in WATIR. assert_equal(expandI...

Watir: How to access a table without an ID or NAME.

I am trying to write my watir script to grab the following data (the table body headers and the table row data, but I am having trouble trying to figure out how to access the table. (Once I get that, teh rest is a piece of cake). Can anyone come up with something that will help me access the table? It doesn't have a name or an ID... <...

watir-webdriver wait for page load

using watir-webdriver [ http://github.com/jarib/watir-webdriver ] how do i wait for a page to load after i click a link? at the moment i am doing sleep n but this is not ideal as the page response varies so much. is their a method to test whether the page is ready or whether their is a certain element in the page. I understand in t...

Firewatir: Error when installing Firewatir on Windows

I am trying to install Firewatir on my PC (its OS is Windows). I have installed the jssh and test it. It is properly installed. After that, I tried to install the firewatir gem. So I ran this command: gem install firewatir Then, I got this error: ERROR: While executing gem ... (RunTimeError) Error installing firewatir: ...

firefox and watir wouldn't work on windows due to a singularize method not found, what's wrong ?

Hi there, I just installed a fresh copy of ruby 1.8.7 on Windows XP SP3 32bits. Install watir. I used the wikipedia example : require 'rubygems' require 'watir/ie' Watir::Browser.default = 'ie' b = Watir::Browser.new b.goto("http://www.google.com") so far so good, works as expected now require 'rubygems' require 'watir/ie' ...

jssh telnet fails even after installing the add-on on Linux

Hi, I am working with ruby gem "firewatir (1.6.5)" and mozilla Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.9) Gecko/20100330 Fedora/3.5.9-1.fc11 Firefox/3.5.9.<\i> I have installed the jssh.*.xpi extension for mozilla 3.5 for Linux and it works for sometime. But the problem is that after running some scripts I get the error ...

Firewatir: firewatir returns undefined method error in eclipse

Thank you for taking your time in reading this. I am just getting started with running Watir in Eclipse. When I try to load the require 'firewatir' statement on the top of the page, I receieve this error in the Eclipse console: in inherited': undefined methoddemodulize' for "FireWatir::Pre":String (NoMethodError) Running require firewa...

Firewatir: Firewatir is not opening Firefox

FireWatir I recently started using Firewatir for testing, I followed all the required steps while installing firewatir but I am not able to run the script. Here is the information from my local machine ruby version: ruby 1.9.1p429 (2010-07-02 revision 28523) [i386-mingw32] gems installed: C:>gem list * LOCAL GEMS * activesupport (...