[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

Runtime debugging tools needed?!!

sunkids

6/5/2006 1:36:00 PM

Hi All:
Thanks everyone so activating in ruby community. I am newbi to
ruby. This is all because WATIR, a web testing tool.
I know some people post before saying there is no need for ruby
have a runtime debugging tool, because ruby is simple enough or so easy

to find where the error is, which I totally agree with. However, my
company deside to try WATIR/Ruby in our product functional testing(Web
application testing), and ask me to give a full demo to the automation
board.
The challenges of swithing from our existing automation tool to
Ruby/WATIR tool are fast development and less maintenance effort.
First, I am strongly believe fast development can be achieved by strait

forward coding and pure OO language advantage. Second, less maintenance

effort has to be achieved with propret tool. However, because of our
large size of web application, our testing framework is also very large

and complex, and it is still grow fast. In order to maintain the
testing framework release to release we are at boundary equal effort
between manual testing and recalibrate existing automation. That's also

why we can looking for better tools.
The current WATIR/Ruby debugging flow is all based on exception,
fix and rerun the program. However, with frequent source code
change(our product), we have to face the ugly truth, our automation
scripts have to be constantly change. Even worse, our automation
scripts can't be just simply rerun, due to all the testing senario data

is half way send to server. We have to restore the database at server
and rerun the script, which is VERY TIME CONSUMING, maybe more than our

code creation.
Which makes me thinking about a tool, that will allow me running
Ruby/WATIR code under it, show me the exception, pause the code and
resumed the code after I saved my fix to the code. If this is doable
(which I believe, because ruby is interpreted language), that will be
ideal solution for our maintaining such large testing framework.
Thanks in advance for all your commens.

Regards,
Jonathan Ni

47 Answers

aidy

6/5/2006 2:16:00 PM

0

Hi,

I am using Watir and Ruby myself. Having tried emacs,vi etc - I went
back to Eclipse.

There is a Ruby plugin for Eclipse here:
http://sourceforge.net/projects/r...

Just extract your zip into the *Eclipse* folder.

This article gives you some much needed info:
www.ibm.com/developerworks/opensource/library/os-rubyeclipse

Debug info can be read over a port, and you should be able to de-bug in
the IDE just like Java.

The above article, explains it all, but I have not got it to work. The
way I see it, if there is an article on it on an IBM site, written by a
guy from ThoughtWorks - it's gotta work.

Aidy

p.s. I would be interested in knowing how you are organising you
test-classes. I have created a little framework, but need some
feedback.

Andrew McDonagh

6/5/2006 6:50:00 PM

0

sunkids@gmail.com wrote:
> Hi All:
> Thanks everyone so activating in ruby community. I am newbi to
> ruby. This is all because WATIR, a web testing tool.
> I know some people post before saying there is no need for ruby
> have a runtime debugging tool, because ruby is simple enough or so easy
>
> to find where the error is, which I totally agree with. However, my
> company deside to try WATIR/Ruby in our product functional testing(Web
> application testing), and ask me to give a full demo to the automation
> board.
> The challenges of swithing from our existing automation tool to
> Ruby/WATIR tool are fast development and less maintenance effort.
> First, I am strongly believe fast development can be achieved by strait
>
> forward coding and pure OO language advantage. Second, less maintenance
>
> effort has to be achieved with propret tool. However, because of our
> large size of web application, our testing framework is also very large
>
> and complex, and it is still grow fast. In order to maintain the
> testing framework release to release we are at boundary equal effort
> between manual testing and recalibrate existing automation. That's also
>
> why we can looking for better tools.
> The current WATIR/Ruby debugging flow is all based on exception,
> fix and rerun the program. However, with frequent source code
> change(our product), we have to face the ugly truth, our automation
> scripts have to be constantly change. Even worse, our automation
> scripts can't be just simply rerun, due to all the testing senario data
>
> is half way send to server. We have to restore the database at server
> and rerun the script, which is VERY TIME CONSUMING, maybe more than our
>
> code creation.
> Which makes me thinking about a tool, that will allow me running
> Ruby/WATIR code under it, show me the exception, pause the code and
> resumed the code after I saved my fix to the code. If this is doable
> (which I believe, because ruby is interpreted language), that will be
> ideal solution for our maintaining such large testing framework.
> Thanks in advance for all your commens.
>
> Regards,
> Jonathan Ni
>

ok, so there's a few different things here that under lay your desire
for a debugger - notably that Watir tests are difficult to write/test
because they are working the system end-to-end - i.e. Web ui to DB.

Automated tests are an investment - they take time to make and need
maintaining just like the application code they exercise. However, this
investment is normally a factor lower than the time and cost of
repeatedly running manual tests.

Once a test is automated it can and should, be run as manay times as
possible - by everyone on the team including the build system if you
have one.

However, as you are seeing, your tests need to Arrange some form of
initial state, do the desired Action to test and then Assert the results.

I.e. the 3 A's

Arrange
Action
Assert

However, like I said, your tests are currently end-to-end. Which is
often not needed nor desired.

A more reliable, flexible, less maintenance approach is to partition the
tests so that very few actually go end-to-end.

For example, say we have a login screen, which accepts the users name
and password, which the web application then uses to authenticate
against an LDAP service.

Now, we could setup the test environment and the test itself so that we
use a real users name and password and the system really does connect to
the LDAP.

However, then the user name and password needs updating when ever they
change (because company policy says all passwords expire every month, or
the user leaves the company, etc).

A better, flexible, less maintenance approach would be to substitute the
LDAP look up with a fake LDAP implementation.

This way, we can create acceptance tests that test all types of
conditions without the application ever going to a real LDAP server and
the test never need updating because of a data value change, because the
values never need changing - they are fake values.

aidy

6/7/2006 2:36:00 PM

0

Hi,

Apparently the RDT debugger (Eclipse) will not work with ruby 1.8.4,
but will with ruby 1.8.2.

Aidy

Mitchell Holman

9/7/2008 3:23:00 PM

0

Klaus Schadenfreude <kschadenfreude@qwest.net> wrote in
news:qmq7c4pmsbqfg5k2gbjuqkjor26pk6kvp1@4ax.com:

> In talk.politics.guns "Poor Lil Johnny" <tits@alas.net> wrote:
>
>>
>>"r wiley" <rawiley@southslope.net> wrote in message
>>news:ga0p2h$rge$1@news.netins.net...
>>>
>>>
>>> Barack Obama supports a ban on all semiautomatic weapons,
>>> and a ban on concealed carry laws.
>>>
>>> http://www.nraila.org/media/PDFs/2008Obamaf...
>>>
>>>
>>> rw
>>
>>Yes. Take away Obama's poise, good looks, charisma, wit and concern for
>>social justice, and what have you got left? Nothing but the penetrating
>>intelligence of a constitutional law professor who belongs leading the
>>free world.
>
> His "intelligence" couldn't penetrate a bowl of jello. He's a
> wishy-washy, cowardly, terrorist-supporting politician.



No, what we need are MORE "C-average" Republican presidents.



"Will the highways on the Internet become more few?"
George W Bush, Concord, N.H., Jan. 29, 2000


Geno4321

9/7/2008 3:23:00 PM

0

And your a idiot with a sponge for a brain.

"Klaus Schadenfreude" <kschadenfreude@qwest.net> wrote in message
news:qmq7c4pmsbqfg5k2gbjuqkjor26pk6kvp1@4ax.com...
> In talk.politics.guns "Poor Lil Johnny" <tits@alas.net> wrote:
>
>>
>>"r wiley" <rawiley@southslope.net> wrote in message
>>news:ga0p2h$rge$1@news.netins.net...
>>>
>>>
>>> Barack Obama supports a ban on all semiautomatic weapons,
>>> and a ban on concealed carry laws.
>>>
>>> http://www.nraila.org/media/PDFs/2008Obamaf...
>>>
>>>
>>> rw
>>
>>Yes. Take away Obama's poise, good looks, charisma, wit and concern for
>>social justice, and what have you got left? Nothing but the penetrating
>>intelligence of a constitutional law professor who belongs leading the
>>free
>>world.
>
> His "intelligence" couldn't penetrate a bowl of jello. He's a
> wishy-washy, cowardly, terrorist-supporting politician.


Klaus Schadenfreude

9/7/2008 3:37:00 PM

0

In talk.politics.guns Mitchell Holman <Noemail@comcast.com> wrote:

>Klaus Schadenfreude <kschadenfreude@qwest.net> wrote in
>news:qmq7c4pmsbqfg5k2gbjuqkjor26pk6kvp1@4ax.com:
>
>> In talk.politics.guns "Poor Lil Johnny" <tits@alas.net> wrote:
>>
>>>
>>>"r wiley" <rawiley@southslope.net> wrote in message
>>>news:ga0p2h$rge$1@news.netins.net...
>>>>
>>>>
>>>> Barack Obama supports a ban on all semiautomatic weapons,
>>>> and a ban on concealed carry laws.
>>>>
>>>> http://www.nraila.org/media/PDFs/2008Obamaf...
>>>>
>>>>
>>>> rw
>>>
>>>Yes. Take away Obama's poise, good looks, charisma, wit and concern for
>>>social justice, and what have you got left? Nothing but the penetrating
>>>intelligence of a constitutional law professor who belongs leading the
>>>free world.
>>
>> His "intelligence" couldn't penetrate a bowl of jello. He's a
>> wishy-washy, cowardly, terrorist-supporting politician.
>
>
>
> No, what we need are MORE "C-average" Republican presidents.

Better than the alternative's Democrats offered. Why don't you losers
try fielding a decent candidate?

Illinois Boy

9/7/2008 3:45:00 PM

0

Poor Lil Johnny wrote:

> "r wiley" <rawiley@southslope.net> wrote in message
> news:ga0p2h$rge$1@news.netins.net...
>
>>
>>Barack Obama supports a ban on all semiautomatic weapons,
>>and a ban on concealed carry laws.
>>
>>http://www.nraila.org/media/PDFs/2008Obamaf...
>>
>>
>>rw
>
>
> Yes. Take away Obama's poise, good looks, charisma, wit and concern for
> social justice, and what have you got left? Nothing but the penetrating
> intelligence of a constitutional law professor who belongs leading the free
> world.
>
>


You mean an unqualified piece of crap that wants to destroy the
constitution.

Poetic Justice

9/7/2008 4:13:00 PM

0

Illinois Boy wrote:
> Poor Lil Johnny wrote:
>
>> "r wiley" <rawiley@southslope.net> wrote in message
>> news:ga0p2h$rge$1@news.netins.net...
>>
>>>
>>> Barack Obama supports a ban on all semiautomatic weapons,
>>> and a ban on concealed carry laws.
>>>
>>> http://www.nraila.org/media/PDFs/2008Obamaf...
>>>
>>>
>>> rw
>>
>>
>> Yes. Take away Obama's poise, good looks, charisma, wit and concern
>> for social justice,

Define social justice?


>> and what have you got left? Nothing but the
>> penetrating intelligence of a constitutional law professor who belongs
>> leading the free world.
>>
>>
>
>
> You mean an unqualified piece of crap that wants to destroy the
> constitution.

Klaus Schadenfreude

9/7/2008 4:22:00 PM

0

In talk.politics.guns "Geno1234" <eugenefkent@fuse.net> wrote:


>"Klaus Schadenfreude" <kschadenfreude@qwest.net> wrote in message
>news:qmq7c4pmsbqfg5k2gbjuqkjor26pk6kvp1@4ax.com...
>> In talk.politics.guns "Poor Lil Johnny" <tits@alas.net> wrote:
>>
>>>
>>>"r wiley" <rawiley@southslope.net> wrote in message
>>>news:ga0p2h$rge$1@news.netins.net...
>>>>
>>>>
>>>> Barack Obama supports a ban on all semiautomatic weapons,
>>>> and a ban on concealed carry laws.
>>>>
>>>> http://www.nraila.org/media/PDFs/2008Obamaf...
>>>>
>>>>
>>>> rw
>>>
>>>Yes. Take away Obama's poise, good looks, charisma, wit and concern for
>>>social justice, and what have you got left? Nothing but the penetrating
>>>intelligence of a constitutional law professor who belongs leading the
>>>free
>>>world.
>>
>> His "intelligence" couldn't penetrate a bowl of jello. He's a
>> wishy-washy, cowardly, terrorist-supporting politician.
>
>And your a idiot with a sponge for a brain.

Someday maybe you'll grow a brain

Bill Smith

9/7/2008 4:23:00 PM

0

On Sun, 7 Sep 2008 07:44:41 -0700, "Poor Lil Johnny" <tits@alas.net>
wrote:

>
>"r wiley" <rawiley@southslope.net> wrote in message
>news:ga0p2h$rge$1@news.netins.net...
>>
>>
>> Barack Obama supports a ban on all semiautomatic weapons,
>> and a ban on concealed carry laws.
>>
>> http://www.nraila.org/media/PDFs/2008Obamaf...
>>
>>
>> rw
>
>Yes. Take away Obama's poise, good looks, charisma, wit and concern for
>social justice, and what have you got left? Nothing but the penetrating
>intelligence of a constitutional law professor who belongs leading the free
>world.
>

I'll agree, for the sake of argument, but we also have a man who has
voted for EVERY gun control law that he has had an opportunity to vote
for, whether it made any sense or not, and, now, suddenly, supports an
individual right to keep and bear arms. You can understand why gun
owners are, shall we say, skeptical. It's duplicitous, at best.

Bill Smith