I was attempting to use text.include? like: 

$ie.text_field(:name, "MyText").text.include? “My text to verify”

 

And I get this message:  “warning: parenthesize argument(s) for future version

 

Am I getting this because I am using “text.include?” incorrectly or something else?

 

Thanks,

 

--Mark

 


From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Bret Pettichord
Sent: Monday, June 26, 2006 3:53 PM
To: [email protected]
Subject: Re: [Wtr-general] Did the implementation for contains_text change?

 

Looks like a bug. Please go ahead and enter this in Jira. http://jira.openqa.org/browse/WTR


In general, i have been thinking of deprecating contains_text and instead encouraging people to use "text.include?" (or regexps).

  ie.frame(:index, 2)text.include? "DimensionManager"

But that's not why it's missing in 1.5.


Bret

On 6/23/06, George Flaherty <[EMAIL PROTECTED] > wrote:

I am now on the latest watir gem (1.5.1.1037). When I had 1.4.1 installed the following functionality did work...but now I am seeing the following error? I tried both from irb and a unit test script and I got the same error message.

*****WATIR: 1.5.1 (1037gem) -Error

irb(main):002:0> ie = Watir::IE.attach(:title, /Merch/)
irb(main):003:0> ie.frame(:index, 2).contains_text('DimensionManager')
NoMethodError: undefined method `contains_text' for #<Watir::Frame:0x2dc9468>
        from (irb):3

I also just confirmed that this did work with the 1.4.1 implementation:

****WATIR: 1.4.1 (single click) - Working

irb(main):004:0> ie = Watir::IE.attach(:title, /Merch/)
irb(main):006:0> ie.frame(:index,2).contains_text('DimensionManager')
=> nil
irb(main):007:0>

Thanks
-george
_______________________________________________
Wtr-general mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/wtr-general

 

_______________________________________________
Wtr-general mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/wtr-general

Reply via email to