[wtr-general] Re: Is there an easy way to see if specific text exists inside a div?

2009-04-06 Thread Bret Pettichord
Chuck van der Linden wrote: > The harder part is purging all the examples that have been printed out > and pinned to walls... > > Is there any way to display some kind of readme (where we could list > things like this) when someone updates a gem? > No. The standard method is to issue a warning

[wtr-general] Re: Is there an easy way to see if specific text exists inside a div?

2009-04-05 Thread Chuck van der Linden
On Apr 4, 10:46 am, Bret Pettichord wrote: > Sure. Although the first step might simply be to purge the method from > all of the examples. The harder part is purging all the examples that have been printed out and pinned to walls... Is there any way to display some kind of readme (where we coul

[wtr-general] Re: Is there an easy way to see if specific text exists inside a div?

2009-04-04 Thread Charley Baker
good point. :) -c On Sat, Apr 4, 2009 at 11:46 AM, Bret Pettichord wrote: > > Sure. Although the first step might simply be to purge the method from > all of the examples. > > Charley Baker wrote: > > We have to be able to deprecate methods. While it's not yet a language > > feature, rubygems an

[wtr-general] Re: Is there an easy way to see if specific text exists inside a div?

2009-04-04 Thread Bret Pettichord
Sure. Although the first step might simply be to purge the method from all of the examples. Charley Baker wrote: > We have to be able to deprecate methods. While it's not yet a language > feature, rubygems and other projects are deprecating apis: > http://tenderlovemaking.com/category/rubygems

[wtr-general] Re: Is there an easy way to see if specific text exists inside a div?

2009-04-03 Thread Charley Baker
We have to be able to deprecate methods. While it's not yet a language feature, rubygems and other projects are deprecating apis: http://tenderlovemaking.com/category/rubygems/ -c On Fri, Apr 3, 2009 at 4:57 PM, Bret Pettichord wrote: > > I wish we'd never added that contains_text method. brows

[wtr-general] Re: Is there an easy way to see if specific text exists inside a div?

2009-04-03 Thread Bret Pettichord
I wish we'd never added that contains_text method. browser.text.include? does the same thing and helps you to start thinking in Ruby. Bret Chuck van der Linden wrote: > Thanks guys, great responses... > > I think the include option will work best. I was trying to use > ".contains" have to lea

[wtr-general] Re: Is there an easy way to see if specific text exists inside a div?

2009-04-03 Thread Chuck van der Linden
Thanks guys, great responses... I think the include option will work best. I was trying to use ".contains" have to learn to better find my way around the docs to see what methods are supported for things.. using the wrong method name is just full of fail. browser.div(:id, 'legend').text.includ

[wtr-general] Re: Is there an easy way to see if specific text exists inside a div?

2009-04-03 Thread Tiffany Fodor
Hey Chuck! Does this work? browser.div(:id, 'legend').value.include?('username') -Tiffany On Apr 3, 11:27 am, Chuck van der Linden wrote: > I want to make sure that the correct user has been logged in > > The user's name appears in a legend div a the top of the page, along > with some other l

[wtr-general] Re: Is there an easy way to see if specific text exists inside a div?

2009-04-03 Thread Leigh
browser.div(:id, 'legend').text.include?("text")Would that work for you? On Fri, Apr 3, 2009 at 1:27 PM, Chuck van der Linden wrote: > > I want to make sure that the correct user has been logged in > > The user's name appears in a legend div a the top of the page, along > with some other lin

[wtr-general] Re: Is there an easy way to see if specific text exists inside a div?

2009-04-03 Thread Darin Duphorn
user_name = "joe smith" puts $ie.div(:text,/#{user_name}/).exists?.to_s #or maybe puts $ie.div(:id=>'legend',:text=>/#{user_name}/).exists?.to_s -Original Message- From: watir-general@googlegroups.com [mailto:watir-gene...@googlegroups.com] On Behalf Of Chuck van der Linden Sent: