Watir attracts Ruby Newbies

B

Bret Pettichord

Watir is rapidly attracting users. (We pronounce it 'water'.)

Many of our users are new to Ruby and even new to object-oriented languages.

In fact, they can't tell where Watir ends and Ruby begins. Thus, they end
up asking lots of questions to the Watir mailing list
([email protected]) that are really just Ruby questions.

I gave a presentation of Watir's precursor at the Ruby Conference 2003 in
Austin. At that time, i said that we were using Ruby as our scripting
language because it was intuitive and easy to learn for non-programmers.

But now they are wanting to read data from spreadsheets or csv files or
initialization files. Or they want to create libraries. Or they want help
with Test::Unit.

I consider myself middling in my Ruby skills. I've heard meta-classes
explained at least three times and still don't understand them. But i'm one
of the more knowledgable people on the list.

We could use your help. If you are interested in helping new users learn
how to use Ruby, please consider joining our mailing list. (Or you could
just help Brian with his book.)

Oh, and BTW, we now have a gem for Watir ('gem install watir'). It has unit
tests and rdoc. And yes, Watir only works on Windows and only with Internet
Explorer. I offer apologies to the OSS gods.

http://wtr.rubyforge.org/

Bret


_____________________
Bret Pettichord
www.pettichord.com
 
J

James Britt

Bret said:
Watir is rapidly attracting users. (We pronounce it 'water'.)

Many of our users are new to Ruby and even new to object-oriented
languages.

In fact, they can't tell where Watir ends and Ruby begins. Thus, they
end up asking lots of questions to the Watir mailing list
([email protected]) that are really just Ruby questions.

I gave a presentation of Watir's precursor at the Ruby Conference 2003
in Austin. At that time, i said that we were using Ruby as our scripting
language because it was intuitive and easy to learn for non-programmers.

But now they are wanting to read data from spreadsheets or csv files or
initialization files. Or they want to create libraries. Or they want
help with Test::Unit.

I've some Watir tools that I've been meaning to clean up and package
nicely Real Soon Now, but have suspicions that it will never happen.

I wanted to have non-Rubyists run some tests, but didn't want to have to
coax them into installing Ruby. Or learning Ruby, for that matter. I
sort of built up a DSL syntax as well, so that the test scripts were
simpler than straight Ruby, too.

I wrote an app that kicks off an instance of WEBrick, which looks into
a /scripts dir for user-defined test scripts, and creates a default home
page listing the available scripts, rendered by automagically launching
the default browser. Clicking on a script link would run that script.
Error/info messages would then be displayed on another page as scripts
ran.

The code was bundled up using rubyscript2exe and packaged into a a zip
file so that one could just drop it someplace on a target machine, unzip
it to get a set of permanent directories (where one could store new test
scripts), and double-click the exe to run the script server.

It never gained any traction at the contract place I was working at the
time, but I use it all the time myself (though I don't bother bundling
it with rubyscript2exe for myself).

I don't think I really have time to follow another mailing list, but I'd
like to turn this code over to someone on the Watir team if they think
it useful.

Suggestions?

James Britt

--

http://www.ruby-doc.org - The Ruby Documentation Site
http://www.rubyxml.com - News, Articles, and Listings for Ruby & XML
http://www.rubystuff.com - The Ruby Store for Ruby Stuff
http://www.jamesbritt.com - Playing with Better Toys
 
B

Bret Pettichord

I don't think I really have time to follow another mailing list, but I'd
like to turn this code over to someone on the Watir team if they think it
useful.

Sounds cool! I would be interested to take a look at your code and see if i
can find an owner for it.

Bret


_____________________
Bret Pettichord
www.pettichord.com
 
J

James Britt

Bret said:
Sounds cool! I would be interested to take a look at your code and see
if i can find an owner for it.

Very good. I'll make some time to bundle up what I have, with some sort
of documentation, and send it off to you in the next few days.


James


--

http://www.ruby-doc.org - The Ruby Documentation Site
http://www.rubyxml.com - News, Articles, and Listings for Ruby & XML
http://www.rubystuff.com - The Ruby Store for Ruby Stuff
http://www.jamesbritt.com - Playing with Better Toys
 
P

Phil Tomson

Watir is rapidly attracting users. (We pronounce it 'water'.)

Many of our users are new to Ruby and even new to object-oriented languages.

In fact, they can't tell where Watir ends and Ruby begins. Thus, they end
up asking lots of questions to the Watir mailing list
([email protected]) that are really just Ruby questions.

I gave a presentation of Watir's precursor at the Ruby Conference 2003 in
Austin. At that time, i said that we were using Ruby as our scripting
language because it was intuitive and easy to learn for non-programmers.

But now they are wanting to read data from spreadsheets or csv files or
initialization files. Or they want to create libraries. Or they want help
with Test::Unit.

I consider myself middling in my Ruby skills. I've heard meta-classes
explained at least three times and still don't understand them. But i'm one
of the more knowledgable people on the list.

We could use your help. If you are interested in helping new users learn
how to use Ruby, please consider joining our mailing list. (Or you could
just help Brian with his book.)

Oh, and BTW, we now have a gem for Watir ('gem install watir'). It has unit
tests and rdoc. And yes, Watir only works on Windows and only with Internet
Explorer. I offer apologies to the OSS gods.

http://wtr.rubyforge.org/

Bret,

I guess this is a good problem to have ;-)

Why not point people to this list when they have general Ruby questions?

Also: my understanding is that Watir works only on IE because it uses
Win32OLE. Any thoughts about creating a cross-browser solution (maybe
kind of like Selenium)? I also wonder if maybe something like the new
MouseHole proxy could be used to capture communication between browser and
server and then 'play back' the interactions somehow.

Phil
 
T

Tanner Burson

------=_Part_7966_32145255.1125434026940
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

=20
=20
Bret,
=20
I guess this is a good problem to have ;-)
=20
I also wonder if maybe something like the new
MouseHole proxy could be used to capture communication between browser an= d
server and then 'play back' the interactions somehow.
=20
Phil
=20
Phil, I've actually started, restarted, unwritten, and am writing again,=
=20
what I'm calling HTTPRecorder, which is extremely similar to what you're=20
describing. It's a WEBrick proxy server that records all the HTTP requests,=
=20
and will hopefully generate either HTTP::Mechanize scripts, or somethign=20
extremely similar for playback.

--=20
=3D=3D=3DTanner Burson=3D=3D=3D
(e-mail address removed)
http://tannerburson.com <---Might even work one day...

------=_Part_7966_32145255.1125434026940--
 
B

Bret Pettichord

Why not point people to this list when they have general Ruby questions?

Well, part of the problem is that they don't know what part of their
question is Ruby and what part is Watir. Often they are mixed up, even
though the solution is just learning more about Ruby or some other Ruby
library other than Watir.

Please let me know whether you want these kinds of mixed up questions on
this list. Remember, testers are used to being beat up by developers, and
will be reticent. I know this is a polite list, but i guess i want more
reassurance that this kind of thing would be welcome here.
Also: my understanding is that Watir works only on IE because it uses
Win32OLE. Any thoughts about creating a cross-browser solution (maybe
kind of like Selenium)?

We've given some thought to eventually being able to generate Selenium
scripts from Watir scripts, thus allowing for the cross-browser solution.
This would amount to the moral equivalent of a cross-compiler. You'd
develop on Windows, but then could create a script that would run on other
browsers and platforms.

Several people have looked at using Mozilla's XCOM, but not much is really
hooked up to on Mozilla's side yet, so that is a big project.



_____________________
Bret Pettichord
www.pettichord.com
 
B

Bret Pettichord

Yes, this would be useful, but IMO this kind of tool would best be used in
conjuction with a browser runner like Watir (assuming that the application
is going to be used by IE users).

This problem with this approach is that Watir is in-browser and
specifically can trigger events that will only hit javascript and not
trigger server calls. Or the the javascript will be turned into a
completely unrelated server call (as happens with ajax). Watir is good for
testing java-script intensive apps. These are exactly the apps that
proxy-based recording will fail on.

There is a project to create a recorder for Watir (called WatirMaker) that
is actually trapping javascript events. I think this will be a more
promising approach.

Bret


_____________________
Bret Pettichord
www.pettichord.com
 
D

Dave Burt

Bret said:
Please let me know whether you want these kinds of mixed up questions on
this list. Remember, testers are used to being beat up by developers, and
will be reticent. I know this is a polite list, but i guess i want more
reassurance that this kind of thing would be welcome here.

(and to wtr-general:)
...
Ruby is a general purpose scripting language and there are a lot more
people available to answer such general questions on the
(e-mail address removed) mailing list.

Such questions are also welcome here, but if your question is not getting
answered you may want to ask on the other list.
...

This list loves ruby nubies. You've done well in your message to direct them
here.
We've given some thought to eventually being able to generate Selenium
scripts from Watir scripts, thus allowing for the cross-browser solution.
This would amount to the moral equivalent of a cross-compiler. You'd
develop on Windows, but then could create a script that would run on other
browsers and platforms.

Sounds like fun.

Cheers,
Dave
 
D

David Brady

Dave said:
This list loves ruby nubies.
...They're DELICIOUS!

Seriously, this list and the #ruby-lang channel on freenode are
wonderful. I've been programming for 20 years and picked up Ruby this
Spring. There are a lot of stupid questions you have to ask to get out
of the "baby-talk" phase in any language, and the main advantage of my
20 years' experience is that I generally know a question is stupid
before I have to ask it. :) I have found this list and the IRC
channel to be profoundly lacking in "elitist snobbery".

So, yes. Bring them on. Some will be content to stay close to the
watir documentation, but others will grow into Ruby from there.

"You mean there's a whole programming language based on Watir?!?" ;-)

-dB
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,982
Messages
2,570,190
Members
46,736
Latest member
zacharyharris

Latest Threads

Top