Hi:
We just started using Watir tool to automate one of
WebApplications. While we start using Watir too, we got few doubts which are
described below. Would be great help for us if you can clarify our doubts
mentioned below.
1. In Watir API reference
guide, what is the Top layer class(I mean Watir::FactoryMethods or Watir.IE or
Watir:Simple or
anyother)?
2. Please see the below
code:
========================================
require
'watir'
include Watir
include Watir
a =
Watir::IE.new
a.goto("http://172.16.6.74/sample/index.php")
a.text_field(:name, "user_name").set("admin")
a.text_field(:name, "user_password").set("admin")
a.text_field(:name, "user_password").set("admin")
========================================
(a). In the above code, after last line of code,
if I want use the "assert_text_in_field()" which is in
module "Watir::Simple", what should I need to do?
What I did for
the above is:(but not succeeded)
Included the
two lines of following code at the start:
========================================
require
'watir'
include Watir
include Watir
require
'Watir_simple.rb'
include
Simple
a =
Watir::IE.new
a.goto("http://172.16.6.74/sample/index.php")
a.text_field(:name,
"user_name").set("admin")
a.text_field(:name, "user_password").set("admin")
a.text_field(:name, "user_password").set("admin")
a.assert_text_in_filed("user_name", "Ramanjaneya")
===========================================
But the
above code is not working. It is throwing error message: Undefined
method assert_text_in_filed.
(b). The above (a) doubt is
specific. In general speaking if we want to use different methods of different
modules how we need to proceed?
3. Watir guide thats provided in website is not that much helpful in
providing examples. Would be great if you can provide some real time examples' code so
that
we can walk through the code to
understand how to use the watir tool. or atleast
would be great help for atleast if you can tell me
where i can find.
Thanks a lot in advance for your
valuable time in helping us out.
Thanks &
Regards,
Ramanjaneya
Reddy.
_______________________________________________ Wtr-general mailing list [email protected] http://rubyforge.org/mailman/listinfo/wtr-general
