Re: [Wtr-general] [question] Accesing images?

2006-05-22 Thread Lonny Eachus





We can see a lot easier what is going on if you indent the HTML. Try
using TidyUI or some such, freely available for download.

Anyway, now that I have tidied the HTML, I can see that each image has
an associated ID attribute. It would help if you told us HOW you were
trying to click them. Are you using the id?

Example:

    @my_ie.image(:id, 'img2').click



Lonny Eachus
==



  

  

Subject:

Re: [Wtr-general] [question] Accesing images?
  
  

From: 
"Rodrigo Julian Martin" <[EMAIL PROTECTED]>
  
  

Date: 
Mon, 22 May 2006 16:13:54 -0300
  
  

To: 

  

  
  

  

To: 

  

  
  
  
  
  
  
  Hello! 
   
  I’m having troubles
trying to click some images on a
modal web dialog.
  They seem to be under div
tags, but I can’t click
them…
   
  I’ve tried with divs,
images and frame sentences but
nothing works… 
   
  Here is the html code for
that section (I’ve discarded
the java functions on the beginning of the html file)
   
  
  




___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general

Re: [Wtr-general] FireWatir

2006-05-22 Thread Lonny Eachus




Please let us know when that happens. Tools for using IE have improved,
but Firefox definitely has some advantages, including being
cross-platform.
Since I have not had the time to look at it yet, please tell me: does
FireWatir qualify as being cross-platform?

Lonny Eachus


  

  

Subject:

Re: [Wtr-general] FireWatir
  
  

From: 
"Amit Garde" <[EMAIL PROTECTED]>
  
  

Date: 
Mon, 22 May 2006 21:41:17 +0530
  
  

To: 
wtr-general@rubyforge.org
  

  
  

  

To: 
wtr-general@rubyforge.org
  

  
  
 . . .
  
FireWatir is about 20X to 30X slower than the corresponding IE tests
  
on our machines; Angrez and I are looking at an alternative
  
implementation to make FireWatir faster and closer to what Watir/IE is
  
like but it's likely to take a while.
  
  
Amit
  



___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general

Re: [Wtr-general] link.to_s fails with NoMethodError

2006-05-22 Thread Bret Pettichord
Good suggestion. But i just committed a fix (revision 1012).BretOn 5/22/06, Zeljko Filipin <[EMAIL PROTECTED]
> wrote:It looks to me that you have found a bug. Method "innertext" is notdefined for Watir::Link. If you want it fixed it would be the best tosubmit it to bug database at 
http://jira.openqa.org/browse/WTROn 5/22/06, Manish Sapariya <[EMAIL PROTECTED]> wrote:> NoMethodError: undefined method `innertext' for #
___Wtr-general mailing listWtr-general@rubyforge.orghttp://rubyforge.org/mailman/listinfo/wtr-general

___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general

Re: [Wtr-general] [question] Accesing images?

2006-05-22 Thread Rodrigo Julian Martin








Hello! 

 

I’m having troubles trying to click some images on a
modal web dialog.

They seem to be under div tags, but I can’t click
them…

 

I’ve tried with divs, images and frame sentences but
nothing works… 

 

Here is the html code for that section (I’ve discarded
the java functions on the beginning of the html file)

 

[code]

 



1



Quitar2



Quitar3



Quitar4



Quitar5



Quitar6



Quitar





    

    

   


   


   


   




  











    

    

   


   


   


   




  











    

    

   


   


   


   




  











    

    

   


   


   


   




  











    

    

   


   


   


   




  











    

    

   


   


   


   




  







Tiempo
de carga estimado:__minutos con modem de
56k



 



Asegúrate que el formato de tu foto sea válido: JPG,
JPEG, PNG o GIF (sin animación) y pese menos de 2
MB





















 

[/code]

 

 

 

Thanks in Advance!

I’m really needing help with this..

 

If I’ve missed some info please let me know

 

Rodrigo Julian Martin 

 

 

 

 






___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general

[Wtr-general] [question] Accesing Images..

2006-05-22 Thread Rodrigo Julian Martin








Oh, sorry.. The snapshots are supposed to go with an earlier
post I’ve sent. But that post is still waiting moderation, because it’s
a little bigger than 40K. 

 

Sorry Again

 

Rodrigo Julian Martin

 






___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general

[Wtr-general] General XPath Question

2006-05-22 Thread John Castellucci








I’ve been crawling through xpath for the last couple of weeks, but I’ve been
unable to solve a real basic problem I am having locating desired objects.  

 

As a background, the application I am
automating makes extensive use of AJAX,
_javascript_, Dojo and DWR, so the DOM gets complex.

 

Sample XML:

 



 
 

   

 
 

   




   

  


 
 

   

 

 

Now, what I am trying to do is directly
access each ‘B’ Div – i.e. :

 

The first B in the first A

The second B in the first A

The first B in the second A

The second B in the second A

ad infinitum…

 

The XML isn’t as simple as the above
– since it’s dynamically updated via AJAX- based on context, there are potentially
an unknown amount of elements before, after or inside the above tags.  So, stuff like:

 

/DIV[1]/DIV[1]

 

won’t work for me.   Also, while the below looks like it
should work (and does on basic XML), it returns a set of *all* B elements under an A from the IE DOM:

 

//[EMAIL PROTECTED]’A’][1]/[EMAIL PROTECTED]’B’][1]

 

Any tips on cracking this nut?

 

 






___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general

[Wtr-general] [question] Accesing Images Snapshot

2006-05-22 Thread Rodrigo Julian Martin








And here is the snapshot of that 6 Images…

 

Thanks!

 

 

Rodrigo Julian Martin






<>
___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general

Re: [Wtr-general] FireWatir

2006-05-22 Thread gege qian
Thank you ALL!        Rodrigo Julian Martin <[EMAIL PROTECTED]> wrote:Hello!     I guess that the last time I¡¯ve runned mozilla_all_tests took me 2 hours more or less¡­     Cheers!     From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of gege qianSent: Lunes, 22 de Mayo de 2006 11:31 a.m.To: wtr-general@rubyforge.orgSubject: [Wtr-general] FireWatir   Hi, All could anyone tell how long does it take for running the mozilla_all_tests.rb on firefox?  Thanks a lot Gegegege qian <[EMAIL PROTECTED]> wrote:  HI: All I'm trying to use firewatir, but could not make it work. Please give me some help. 1)I have download "watir-1[1].5.0.980.gem" from 'http://wiki.openqa.org/display/WTR/Development+Builds'and using command 'gem install watir' to install it. THe watir sits in gems folder.  2)I got the firefox code and jssh-20060221-WINNT.xpi parts from 'http://svn.openqa.org/svn/watir/branches'and install them according to the installation doc. 3)I make sure I type firefox.exe -jssh, just one hypen 4)I got the msg of Welcome to the Mozilla _javascript_ Shell!    >5)when I run
 mozilla_all_tests.rb, the error msg i got is">ruby mozilla_all_tests.rb./../mozilla_unittests/setup.rb:35:in `start_ie_with_logger': uninitialized constant Watir::Firefox (NameError) from ./../mozilla_unittests/setup.rb:49 from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in `require__' from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in `require' from mozilla_all_tests.rb:6>Exit code: 1"I have search the Wtr-general, but until now I could not figure out what's wrong. Please help.Thank you very much!Gege  How low will we go? Check out Yahoo! Messenger¡¯s low PC-to-Phone call rates.___Wtr-general mailing listWtr-general@rubyforge.orghttp://rubyforge.org/mailman/listinfo/wtr-general  Ring'em or ping'em. Make PC-to-phone calls as low as 1?/min with Yahoo! Messenger with Voice.___Wtr-general mailing listWtr-general@rubyforge.orghttp://rubyforge.org/mailman/listinfo/wtr-general
		Feel free to call! Free PC-to-PC calls. Low rates on PC-to-Phone.  Get Yahoo! Messenger with Voice___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general

Re: [Wtr-general] Too many requires?

2006-05-22 Thread Andy Sipe
If you find you are using the same requires over and over again in multiple 
files you can centralize them:

loader.rb

require 'this'
require 'that'
require 'something else




script1.rb

require 'loader.rb'


-andy

Original Message Follows
From: Adrian Rutter <[EMAIL PROTECTED]>
Reply-To: wtr-general@rubyforge.org
To: wtr-general@rubyforge.org
Subject: [Wtr-general] Too many requires?
Date: Mon, 22 May 2006 17:50:55 +0100


Hi,

I am concerned about there being to many 'requires' in my test script.

Is the below snippet a good way to organise tests?

   require 'browser'
   require 'logon'
   require 'employees'
   require 'window'

   start_browser("http://gbahevm07l15:9081/wps/portal";)
   login("Aidy","1234")
   goto_employee_list
   enter_employees('\\\gbahes75\projects\sales\Datapool\employee_data.csv')
   close_window

Cheers

Aidy



---
This message and any attachment are confidential and may be privileged or 
otherwise protected from disclosure.
If you are not the intended recipient, please telephone or email the sender 
and delete this message and any attachment from your system.
If you are not the intended recipient you must not copy this message or 
attachment or disclose the contents to any other person.
---
___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general


___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general


[Wtr-general] Javascript security alert popup

2006-05-22 Thread Gavazn Vahshi
Hello everyone,

What's the best approach to deal with javascript
security alert popups? Autoit?

I get the popup when I try http://mysite and the link
is forwarded to https://mysite waiting for user
confirmation.

I'm kind of new to this, but I did go through a few
months of threads and was not ablle to find a solution
in autoit.

Thanks,
  -G

__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 
___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general


[Wtr-general] Too many requires?

2006-05-22 Thread Adrian Rutter

Hi,

I am concerned about there being to many 'requires' in my test script.

Is the below snippet a good way to organise tests?

  require 'browser'
  require 'logon'
  require 'employees'
  require 'window'

  start_browser("http://gbahevm07l15:9081/wps/portal";)
  login("Aidy","1234")
  goto_employee_list
  enter_employees('\\\gbahes75\projects\sales\Datapool\employee_data.csv')
  close_window

Cheers

Aidy



---
This message and any attachment are confidential and may be privileged or 
otherwise protected from disclosure. 
If you are not the intended recipient, please telephone or email the sender and 
delete this message and any attachment from your system.  
If you are not the intended recipient you must not copy this message or 
attachment or disclose the contents to any other person.
---
___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general


Re: [Wtr-general] FireWatir

2006-05-22 Thread Amit Garde
On 5/22/06, gege qian <[EMAIL PROTECTED]> wrote:
>
> Hi, All
>
> could anyone tell how long does it take for running the mozilla_all_tests.rb
> on firefox?

FireWatir is about 20X to 30X slower than the corresponding IE tests
on our machines; Angrez and I are looking at an alternative
implementation to make FireWatir faster and closer to what Watir/IE is
like but it's likely to take a while.

Amit
___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general


Re: [Wtr-general] FireWatir

2006-05-22 Thread Zeljko Filipin
It took me just a few seconds over three hours. :)
Finished in 10892.833 seconds.
On 5/22/06, gege qian <[EMAIL PROTECTED]> wrote:>> could anyone tell how long 
does it take for running the mozilla_all_tests.rb> on firefox?
___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general


Re: [Wtr-general] Making scripts more OO?

2006-05-22 Thread Chris McMahon
> Is there any other method that I could use instead of using an instance
> variable prefix on i.e.,
> or is this the correct method?

In my very humble opinion, what you've done is exactly right.  I still
struggle a little managing scope in Ruby.  But I think you'll find as
you start abstracting common code is that you'll need to think about
such things more.  Here's an example where I keep the WSDL for some
web services tests in a file shared  by all of my scripts:


require 'common_variables'
@@local_wsdl_url = @wsdl_url

-Chris

___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general


Re: [Wtr-general] FireWatir

2006-05-22 Thread Rodrigo Julian Martin








Hello!

 

I guess that the last time I’ve runned
mozilla_all_tests took me 2 hours more or less…

 

Cheers!

 









From:
[EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of gege qian
Sent: Lunes, 22 de Mayo de 2006
11:31 a.m.
To: wtr-general@rubyforge.org
Subject: [Wtr-general] FireWatir



 



Hi, All





 





could anyone tell how long does it take for running the
mozilla_all_tests.rb on firefox?





 





 





Thanks a lot





 





Gege

gege qian
<[EMAIL PROTECTED]> wrote:







HI: All





 





I'm trying to use firewatir, but could not make it work. Please give me
some help.





 





1)I have download "watir-1[1].5.0.980.gem" from
'http://wiki.openqa.org/display/WTR/Development+Builds'
and using command 'gem install watir' to install it. THe watir sits in gems
folder. 





 





2)I got the firefox code and jssh-20060221-WINNT.xpi parts from 'http://svn.openqa.org/svn/watir/branches'
and install them according to the installation doc.





 





3)I make sure I type firefox.exe -jssh, just one hypen





 





4)I got the msg of 
Welcome to the Mozilla _javascript_ Shell!





   
>





5)when I run mozilla_all_tests.rb, the error msg i got is
">ruby mozilla_all_tests.rb
./../mozilla_unittests/setup.rb:35:in `start_ie_with_logger': uninitialized
constant Watir::Firefox (NameError)
 from ./../mozilla_unittests/setup.rb:49
 from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in
`require__'
 from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in
`require'
 from mozilla_all_tests.rb:6
>Exit code: 1
"





I have search the Wtr-general, but until now I could not figure out
what's wrong. Please help.






Thank you very much!





Gege











How low will we go? Check out Yahoo! Messenger’s low PC-to-Phone
call rates.___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general












Ring'em or ping'em. Make PC-to-phone
calls as low as 1¢/min with Yahoo! Messenger with Voice.








___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general

[Wtr-general] FireWatir

2006-05-22 Thread gege qian
Hi, All     could anyone tell how long does it take for running the mozilla_all_tests.rb on firefox?        Thanks a lot     Gegegege qian <[EMAIL PROTECTED]> wrote:HI: All     I'm trying to use firewatir, but could not make it work. Please give me some help.     1)I have download "watir-1[1].5.0.980.gem" from 'http://wiki.openqa.org/display/WTR/Development+Builds'and using command 'gem install watir' to install it. THe watir sits in gems folder.      2)I got the firefox code and jssh-20060221-WINNT.xpi parts from 'http://svn.openqa.org/svn/watir/branches'and install them according to the installation doc.     3)I
 make sure I type firefox.exe -jssh, just one hypen     4)I got the msg of Welcome to the Mozilla _javascript_ Shell!      >  5)when I run mozilla_all_tests.rb, the error msg i got is">ruby mozilla_all_tests.rb./../mozilla_unittests/setup.rb:35:in `start_ie_with_logger': uninitialized constant Watir::Firefox (NameError) from ./../mozilla_unittests/setup.rb:49 from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in `require__' from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in `require' from mozilla_all_tests.rb:6>Exit code: 1"  I have search the Wtr-general, but until now I could not figure out
 what's wrong. Please help.  Thank you very much!  Gege  How low will we go? Check out Yahoo! Messenger’s low PC-to-Phone call rates.___Wtr-general mailing listWtr-general@rubyforge.orghttp://rubyforge.org/mailman/listinfo/wtr-general
		Ring'em or ping'em. Make  PC-to-phone calls as low as 1¢/min with Yahoo! Messenger with Voice.___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general

Re: [Wtr-general] Join my Earthscreen network

2006-05-22 Thread Bret Pettichord
This counts as Spam and is not appropriate for this list.BretOn 5/22/06, Sreedhar Kharidehal <
[EMAIL PROTECTED]> wrote:I'm doing a little something about global warming, I'm inviting my
friends to join me:http://friends.earthscreen.com/?r=IRFUKDIIICdXCWoICigC&i=gmail&[EMAIL PROTECTED]&p=1&z=1&tc=11

___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general

[Wtr-general] Making scripts more OO?

2006-05-22 Thread Adrian Rutter

Hi,

I am trying to make my test scripts more OO.

This is a class and the instantiation



class Sales

def start_browser (url)
   @ie = Watir::IE.new
   @ie.goto(url)
   @ie.maximize()
 end

def login (username, password)
  @ie.link(:text, 'Log in').click
  @ie.text_field(:name, "userid").set(username)
  @ie.text_field(:name, "password").set(password)
  @ie.button(:value, 'Log in').click

end

 end

 sales = Sales.new
 sales.start_browser("http://gbahevm07l15:9081/wps/portal";)
 sales.login("Aidy","1234")



Is there any other method that I could use instead of using an instance
variable prefix on i.e.,
or is this the correct method?

Thanks

Aidy



---
This message and any attachment are confidential and may be privileged or 
otherwise protected from disclosure. 
If you are not the intended recipient, please telephone or email the sender and 
delete this message and any attachment from your system.  
If you are not the intended recipient you must not copy this message or 
attachment or disclose the contents to any other person.
---
___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general


Re: [Wtr-general] link.to_s fails with NoMethodError

2006-05-22 Thread Zeljko Filipin
It looks to me that you have found a bug. Method "innertext" is notdefined for 
Watir::Link. If you want it fixed it would be the best tosubmit it to bug 
database at http://jira.openqa.org/browse/WTR
On 5/22/06, Manish Sapariya <[EMAIL PROTECTED]> wrote:
> NoMethodError: undefined method `innertext' for #
___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general


[Wtr-general] Join my Earthscreen network

2006-05-22 Thread Sreedhar Kharidehal
I'm doing a little something about global warming, I'm inviting my
friends to join me:

http://friends.earthscreen.com/?r=IRFUKDIIICdXCWoICigC&i=gmail&[EMAIL 
PROTECTED]&p=1&z=1&tc=11

___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general


[Wtr-general] Let's make a difference

2006-05-22 Thread Sreedhar Kharidehal
I'm doing a little something for the mother earth, and I thought you
might like to join me:

http://friends.earthscreen.com/?r=gQGEKDIIICdXCWoICigC&i=gmail&[EMAIL 
PROTECTED]&p=2&z=1&tc=23

___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general


[Wtr-general] link.to_s fails with NoMethodError

2006-05-22 Thread Manish Sapariya
Hi,
for link.methods I can see to_s listed as one of the methods.
However when I execute it it fails with NoMethodError.

I am working on the HEAD branch of 1.5 (watir-1.5.0.1005).

As I have not developed any Ruby/Watir code, can anybody
point me to a link or doc which can guide me fix such problems.

Thanks and Regards,
Manish

irb(main):015:0> $ie.frame("mainFrame").link(:index, 1).methods
=> ["table", "hiddens", "html", "instance_variables", "frozen?", 
"file_field", "__send__", "link_has_image", "to_a", 
"activeObjectHighLightColor", "class_name", "log", "src", "radio", 
"flash", "href", "ps", "class", "activeObjectHighLightColor=", 
"exists?", "text", "p", "instance_variable_get", "before_text", 
"link_string_creator", "to_s", "send", "cell", "fire_event", "clone", 
"nil?", "select_list", "display", "getOLEObject", "enabled?", 
"instance_variable_set", "to_yaml_properties", "require_gem", "form", 
"file_fields", "inspect", "pretty_print_inspect", "div", 
"show_all_objects", "radios", "instance_eval", "image", "for", 
"fireEvent", "dup", "pre", "innerText", "alt", "equal?", "name", 
"afterText", "after_text", "locate_tagged_element", "divs", "methods", 
"row", "require", "method", "cells", "attribute_value", "taint", "eql?", 
"select_lists", "focus", "beforeText", "hash", "disabled", 
"singleton_methods", "text_field", "document", "instance_of?", "pres", 
"waitForIE", "extend", "button", "link", "id", "span", 
"require_gem_with_options", "text_fields", "locate_input_element", 
"protected_methods", "wait", "label", "tainted?", "value", "links", 
"checkbox", "textField", "is_complex_yaml?", "untaint", "fileField", 
"kind_of?", "popup", "__id__", "pretty_print_cycle", "disabled?", 
"private_methods", "==", "style", "frame", "===", "freeze", "locate", 
"is_a?", "selectBox", "checkboxes", "click", "ole_object", "title", 
"spans", "to_yaml", "pretty_print", "object_id", "hidden", "=~", 
"public_methods", "images", "rows", "ole_object=", "buttons", 
"typingspeed", "labels", "checkBox", "pretty_print_instance_variables", 
"respond_to?", "to_yaml_type", "tables", "click_no_wait", "type", 
"typingspeed="]
irb(main):015:0> $ie.frame("mainFrame").link(:index, 1).to_s
NoMethodError: undefined method `innertext' for #
from C:/Program 
Files/ruby/lib/ruby/gems/1.8/gems/watir-1.5.0.1005/./watir.rb:3291:in 
`link_string_creator'
from C:/Program 
Files/ruby/lib/ruby/gems/1.8/gems/watir-1.5.0.1005/./watir.rb:3300:in `to_s'
from (irb):15
from (null):0
irb(main):016:0>
___
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general