[wtr-general] Re: Watir simple field recorder

2011-05-22 Thread Abe Heward
What's the thinking behind going with the structure...

def field_name
  browser.thing(:how, what)
end

...versus simply:

field_name = browser.thing(:how, what)

?

Are there advantages/disadvantages with each?

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com


[wtr-general] Re: Watir simple field recorder

2011-04-26 Thread Babitha
I know Watir community does not like recorders - I read about it in
Wikipedia.

This script is not exactly a recorder per say. I would call it a
Object repository builder - if that appeals better to the Watir
community. It helps you get around the mundane task of using Firebug
or Developer tool bar to identify each element ids/names. Moreover, it
is written in a very object oriented way.

I have uploaded it at http://pastie.org/1837926. Thanks Darryl for
that info.

Željko, I suggest you try it. It will not solve your complex field
identification problems where you still have to use Firebug/Developer
Toolbar; but it will ease your development effort a lot; especially if
you have a form based application with lots of data entry fields.

Thanks
Babitha



On Apr 21, 1:46 am, Željko Filipin zeljko.fili...@wa-research.ch
wrote:
 On Fri, Apr 1, 2011 at 7:26 PM, Babitha babitha.augus...@gmail.com wrote:
  I could share this script if anybody was interested. But, I am not
  sure where I can upload it.

 You will find that Watir community does not like recorders. You can upload
 it on your site, github, or you can take over watir recorder project at
 openqa.org.

 Željko
 --
 watir.com - community manager
 watir.com/book - author
 watirpodcast.com - host
 viaqa.mobi conference on software testing - organizer

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com


[wtr-general] Re: Watir simple field recorder

2011-04-21 Thread Darryl Brown
I don't personally use 'recorders' but tools like this are an immense
help for getting new team members up to speed until they get a grasp
on effectively using Firebug. There are no Watir recorders per se.
However, tools such as this one and Webmetrics offer help to new
testers that don't have a programming background and I think that they
should be encouraged for the purpose of capturing objects.


Babitha - If you want to easily share your version of the tool with
the group, you can use  http://pastie.org/   just paste and
paste(post).

Here's an example  - http://pastie.textmate.org/1777913


Darryl

On Apr 20, 4:46 pm, Željko Filipin zeljko.fili...@wa-research.ch
wrote:
 On Fri, Apr 1, 2011 at 7:26 PM, Babitha babitha.augus...@gmail.com wrote:
  I could share this script if anybody was interested. But, I am not
  sure where I can upload it.

 You will find that Watir community does not like recorders. You can upload
 it on your site, github, or you can take over watir recorder project at
 openqa.org.

 Željko
 --
 watir.com - community manager
 watir.com/book - author
 watirpodcast.com - host
 viaqa.mobi conference on software testing - organizer

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com


[wtr-general] Re: Watir simple field recorder

2011-04-01 Thread Darryl Brown
Hello Babitha,

I would be interested in see your version of the Watir recorder. On a
new project, creating a GUI map is one of the first things that we do
after initial prototyping.


I will respond directly to you with my email address.

Thanks,
Darryl

On Apr 1, 1:26 pm, Babitha babitha.augus...@gmail.com wrote:
 A long time back, Scott Hanselman of microsoft had posted a ruby watir
 recorder in his blog. Like most other recorders, this had the problem
 that the code generated couldn't be reused.

 I made some small tweaking to this code so that when a user traverses
 through the page, clicking on each element that he wants to record, it
 records all the elements in the Watir format and gives back a nice
 module with properties defined for each element.

 As a sample say you have a page with two fields FirstName and
 LastName.

 The recorded output will be something like below:

 module MyPage
     def first_name
          $browser.text_field(:id, FirstName)
     end

     def last_name
         $browser.text_field(:id, LastName)
     end
 end

 Now just add this module to your test cases and use first_name,
 last_name etc directly without bothering about the identification of
 IDs.

 I could share this script if anybody was interested. But, I am not
 sure where I can upload it.

 Thanks,
 Babitha

-- 
Before posting, please read http://watir.com/support. In short: search before 
you ask, be nice.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com