I am having the same trouble as this guy
is_text_present fails.
Suggestions / code samples?
--
You received this message because you are subscribed to the Google Groups "selenium-ruby" group.
To post to this group, send email to seleni...@googlegroups.com
To unsubscribe from this group, send email to selenium-rub...@googlegroups.com
For Selenium-Ruby project, visit http://seleniumhq.org/projects/ruby/
For Selenium related questions like Core, Server, and RC client in other language, please go to http://clearspace.openqa.org/community/selenium
Try this:
driver.find_element(:id=>"footer").text.include? 'About Google'
Check this blog for wait.until code examples.
http://watirmelon.com/2011/05/05/selenium-webdriver-vs-watir-webdriver-in-ruby/
On Nov 27, 8:16 pm, Jason <spit.respecta...@gmail.com> wrote:
> When I create a test case in the Selenium IDE that checks for text and
> export it to a Ruby/WebDriver script I get
>
> # ERROR: Caught exception [ERROR: Unsupported command [isTextPresent]]
>
> Here is a sample script
>
> require 'rubygems'
> require 'selenium-webdriver'
>
> server = "http://www.google.com"
> driver = Selenium::WebDriver.for :firefox
>
> driver.get server
>
> # make sure 'About Google' appears on the page
> assert driver.is_text_present "About Google"
>
> Which fails with
>
> test.rb:12:in `<main>': undefined method `is_text_present' for
> #<Selenium::WebDriver::Driver:0x..f9c83b53a browser=:firefox>
> (NoMethodError)
>
> Selenium::Client::Extensions has 'wait_for_text' -- is there an easy way to
> get to that from Selenium::WebDriver ?
>
>
>
>
>
>
>
> On Sun, Nov 27, 2011 at 7:21 PM, Jason <spit.respecta...@gmail.com> wrote:
> > I have recently switch from Selenium RC / Python (snapshot from over a
> > year ago) to Selenium2 / Ruby.
>
> > I am having the same trouble as this guy
>
> >http://stackoverflow.com/questions/7667001/how-do-you-check-the-page-...
>
> > is_text_present fails.
>
> > Suggestions / code samples?
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "selenium-ruby" group.
> > To post to this group, send email to seleni...@googlegroups.com
> > To unsubscribe from this group, send email to
> > selenium-rub...@googlegroups.com
> > For Selenium-Ruby project, visithttp://seleniumhq.org/projects/ruby/