Hi Filipin, Watir processes the DOM too slow which causes me to over use 'sleep' and 'when_present'. I wanted to use Nokogiri to process the DOM then have watir automate that DOM without using Nokogiri syntax.
Is this possible? On Tuesday, 20 August 2013 11:38:29 UTC-6, Bashir Osman wrote: > > Hi, > > I read this post here: http://zeljkofilipin.com/watir-nokogiri/ > > Just curious does anyone know how to ONLY parse the DOM using Nokogiri > then using Watir to automate the DOM? > > This is what I'm currently doing, but its giving me SSL errors. So i'm > most likely doing something very wrong. I'm currently using Ruby 2.0 > > require 'rspec' > require 'watir' > require 'watir-webdriver' > require 'nokogiri' > require 'open-uri' > before(:each) do > url = @browser.url > puts "this is the #{url}" > doc = Nokogiri::HTML(open(url)) > puts doc.at_css("title").text > end > > This does work though: > > require 'nokogiri' > require 'open-uri' > url = 'http://www.google.com' > doc = Nokogiri::HTML(open(url)) > puts doc.at_css("title").text > -- -- Before posting, please read http://watir.com/support. In short: search before you ask, be nice. [email protected] http://groups.google.com/group/watir-general [email protected] --- You received this message because you are subscribed to the Google Groups "Watir General" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
