I have a field which should be defined as
class ViewActivityPatternPage Taza::Page
field(:class) {logon_frame.span
(:id, /.*:ActivityClass$/)}
...
end
but as soon as the page object is instantiated I get
undefined method `class_field' for
Thanks, It worked - except that before_text and after_text seem to be
reversed in watir 1.6.3. I used after_text and got what I needed.
Andy
On Apr 13, 7:09 pm, orde ohil...@gmail.com wrote:
Looks like this would do it:
puts browser.link(:index, 1).before_text
On Apr 13, 2:31 pm,
I have a large tree of nested divs, and I want to get an array of just
the direct children of any particular div. I do not know ahead of time
how many divs there will be at any level. Starting from a div, what is
the Watir code for getting the divs that are direct children (and yes,
there are
How can xpath be used to return an array of divs? What would the xpath
look like?
On Apr 14, 10:30 am, Michael Hwee michael_h...@yahoo.com wrote:
Can you try xpath?
- Original Message
From: andrew.d...@lthree.com andrew.d...@lthree.com
To: Watir General
if I have some html that looks like
span id='myid'
text1
a link text/a
text 2
select.../select
text 3
/span
what is the Watir command to pull out just 'text 2'?
Andy
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Wondering if anyone ran into this and solved it. Had a machine which
has been running my tests fine for months. It was updated and rebooted
and now IE crashes about 50% of the time when closing the browser at
the end of a test. Prevents other tests from starting.
Windows XP
IE 7.0.5730.13
Watir
Here is a code snippet.
logon_page.top_frame.contains_text('some text').should_not be_nil
in logon_page.rb I have
def logon_frame
@browser.frame(:id, 'top_frame')
end
alias :top_frame :logon_frame
and I gaurantee that there is a frame with id = 'top_frame'
Fails with
I have a table cell that sometimes holds a span and sometimes holds a
select list. I was trying a begin/rescue like this;
begin
puts looking for select list
@row.cell(:index, 2).select_list(:index, 1)
rescue Exception = e
puts looking for span
1) The column def is part of a larger table def. I would have to
either repeat the column def or the entire table to handle the two
types.
2) Defining multiple columns would make it impossible for me to scan
down that column and choose a row based on a value in that column.
3) Defining multiple
What follows is a working solution and some lessons learned in
handling popups. Thanks for everyone that has helped along the way.
I needed to handle confirmation popups. After trying autoit based
solutions without success, I decided to try a solution that has worked
for me in the past -
Yea, I've tried passing it as a parm with no luck also. Everything
says it is supposed to work, but I can't get it.
On Mar 12, 12:11 pm, Andy Sipe ajs.gene...@gmail.com wrote:
Take a look at this W3 schools link, it may
help:http://www.w3schools.com/jsref/jsref_onkeypress.asp
Note how they
When I tried this I got
undefined method `Document' for #Watir::IE:0x4288648
(NoMethodError)
Is Watir::IE the correct object to be using here?
On Mar 11, 8:53 am, Andy Sipe ajs.gene...@gmail.com wrote:
You should be able to read it using xpath or some other technique.
I don't believe
Here is a sample. This code does not throw any exceptions. js1,2,3 all
result in a popup. js 4 does not - indicating that it is not finding
the element I want. I gaurantee that the html element I am looking for
is a child of top_frame. In fact, the code that calls this block
checks that the html
Just no luck. Still not seeing any popup.
roles_page.bottom_delete.click_no_wait# = no popup
displayed
but if I use
roles_page.bottom_delete.click #=== popup comes right
up
On Mar 5, 10:17 am, Jim Matthews jim_m...@swbell.net wrote:
One thing I forgot to mention:
I was basing my code on example 4. Use click_no_wait on a button I
know will cause a popup, and then call enabled_popup. The call from
enabled_popup never returns. I can post the entire exception trace if
that helps.
On Mar 4, 8:26 am, Jim Matthews jim_m...@swbell.net wrote:
From your first
Trying to execute enabled_popup and it is throwing an exception
undefined local variable or method `hwnd' for #Watir::Frame:
0x3d7b4d4
I checked the source for enabled_popup and it does seem to have an
undeclared variable. Is this working for other people. Working on
latest version of watir.
16 matches
Mail list logo