[wtr-general] Re: Watir 1.6.6 final released
Thanks a lot and great work, Watir works faster and more reliable Dani -- 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
Re: [wtr-general] Re: Recent Stack Overflow Questions Tagged Watir
http://stackoverflow.com/questions/3878965/abnormal-termination-running-an-rspec-watir-script -- 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] How to click on ENTER keystroke using rb-appscript in Watir-WebDriver
Hi Guys, I have a problem... I need to hit the ENTER button on the keyboard on my tests. I was using AutoIT when I was working on Windows and had this: require 'rubygems' require 'win32ole' require 'watir-webdriver' autoit = WIN32OLE.new('AutoITX3.Control') autoit.WinActivate('OK') autoit.Send('{ENTER}') BUT now im using a MAC and this does not work. Ive tried to use rb- appscript after searching the net and have come up with this: require 'rubygems' require 'appscript' require 'watir-webdriver' te = app('OK') te.activate te.key.ENTER BUT this is not working... Has anyone else used rb-appscript? any help would be great. i need this fixed by the end of play today as all of my scripts are failing. would really appreciate anyone who can tell me how to hit the ENTER keystroke on a MAC... Kind regards, Usman Hussain -- 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
Re: [wtr-general] Javascript created div elements
On Wed, Oct 6, 2010 at 7:13 PM, CJ cjr...@gmail.com wrote: I did an if test to see if it exists using this: if b.div(:id, ta_1).exists? It says it doesn't. Is it in a frame? http://wiki.openqa.org/display/WTR/Frames Željko -- watir.com - community manager watirpodcast.com - host testingpodcast.com - audio podcasts on software testing. all of them -- 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] Manipulate Keystrokes on a MAC
Hi Guys, If anyone knows how to manipulate keystrokes on a MAC I would be really grateful if you can tell me how to do this. I need to hit the ENTER and TAB keys on the keyboard. I know I can use AutoIT on windows but am totally lost on how to do this on a MAC. Kind regards, Usman Hussain -- 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
Re: [wtr-general] Javascript created div elements
No, it's not in a frame, but it doesn't exist if you do view source because the javascript and ajax did a document.write to create it after the first save. On Thu, Oct 7, 2010 at 4:14 AM, Željko Filipin zeljko.fili...@wa-research.ch wrote: On Wed, Oct 6, 2010 at 7:13 PM, CJ cjr...@gmail.com wrote: I did an if test to see if it exists using this: if b.div(:id, ta_1).exists? It says it doesn't. Is it in a frame? http://wiki.openqa.org/display/WTR/Frames Željko -- watir.com - community manager watirpodcast.com - host testingpodcast.com - audio podcasts on software testing. all of them -- 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.comwatir-general%2bunsubscr...@googlegroups.com -- CJ Romberger Wildwood Interactive http://www.wildwoodinteractive.com/ 512.732.9916 PLEASE NOTE: I only check this email address about once a day! If you're a client, the fastest way to reach me is to login to Basecamp, OR email supp...@wildwoodinteractive.com. If you're NOT a client? Why not become one!? :) -- 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
Re: [wtr-general] Javascript created div elements
It's several layers down. Are you saying to use a parent element that's visible to access it? What would the syntax look like on that? Say the parent element is another div with an id of wide_right_1 for example. On Thu, Oct 7, 2010 at 12:00 AM, Rajiv Nanduani rajivkumarnandv...@gmail.com wrote: use first parent element of the div like it could be form /table then find ur div element :) On Wed, Oct 6, 2010 at 1:13 PM, CJ cjr...@gmail.com wrote: I have a page whose submit button uses ajax to create a record in a database, and then modify the form to make clickable div elements. When you click on the div element, it opens a new window. Those div elements are visible using Chrome or Firefox and choosing Inspect Element, but they are NOT available if I use watir to show_all_objects. I need to access those elements and then click on them. The code that's visible in Inspect Element through Firefox Firebug or Chrome looks like this: div id=ta_1 class=dot onclick=window.open('innova_editor.php? page-indexsection=_1.tplta=ta_1', 'innova_editor', 'menubar=yes,scrollbars=yes,resizable=yes,height=700,width=950',true); I did an if test to see if it exists using this: if b.div(:id, ta_1).exists? It says it doesn't. I tried firing an event anyway, using this: b.div(:id, ta_1).fire_event(onClick) Says it doesn't exist. Is this possible to do? I'm stuck. :( -- 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.comhttp://groups.google.com/group/watir-general%0awatir-general+unsubscr...@googlegroups.com -- RAJIV KUMAR http://rajivkumarnandvani.wordpress.com/ http://learnqtphelp.blogspot.com/ -- 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.comwatir-general%2bunsubscr...@googlegroups.com -- CJ Romberger Wildwood Interactive http://www.wildwoodinteractive.com/ 512.732.9916 PLEASE NOTE: I only check this email address about once a day! If you're a client, the fastest way to reach me is to login to Basecamp, OR email supp...@wildwoodinteractive.com. If you're NOT a client? Why not become one!? :) -- 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
Re: [wtr-general] Javascript created div elements
On Thu, Oct 7, 2010 at 5:05 PM, CJ Romberger c...@wildwoodinteractive.com wrote: No, it's not in a frame, but it doesn't exist if you do view source because the javascript and ajax did a document.write to create it after the first save. That should not be a problem for Watir. Maybe the element it not (yet) there when you check for it, but it is created later. See this: http://wiki.openqa.org/display/WTR/How+to+wait+with+Watir Željko -- 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
Re: [wtr-general] Javascript created div elements
On Thu, Oct 7, 2010 at 5:06 PM, CJ Romberger c...@wildwoodinteractive.com wrote: Say the parent element is another div with an id of wide_right_1 for example. browser.div(:id = wide_right_1) Željko -- 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
Re: [wtr-general] Difficulty typing into textfield
I have it working like this: password = 'abc123' b.text_field(:name, mock_password).set password If that doesn't work, you might want to just test to see if watir can even see that element. if b.text_field(:name, mock_password).exists? puts Password field exists else puts Password field missing end On Wed, Oct 6, 2010 at 8:54 PM, Eric Mathiesen mathiese...@gmail.comwrote: Could also try .flash to ensure you are calling the right element from orb. Css has given me some challenges in the past.. also try emwith (;index, #).set On Oct 6, 2010 6:35 PM, blkjk blkjk@gmail.com wrote: I am trying to type text to a Login textfield. And when I use this code to access it: $b.text_field(:name, 'mockPassword').set('abc123')No password actually gets typed into the textfield and used for login. Here is what Firebug caught to identify the textfield: input type=text onfocus=jQuery('#mockPassword').hide();jQuery('#password').show();jQuery('#password').focus(); value=password name=mockPassword id=mockPassword style=width: 150px; color: rgb(204, 204, 204); class=input Any thoughts on how to make the code type the password into that field? And yes, I wish to make it work on both IE8 FF3.5 in Win7. Thanks for any help on this. -- 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.comhttp://groups.google.com/group/watir-generalwatir-general+unsubscr...@googlegroups.com -- 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.comwatir-general%2bunsubscr...@googlegroups.com -- CJ Romberger Wildwood Interactive http://www.wildwoodinteractive.com/ 512.732.9916 PLEASE NOTE: I only check this email address about once a day! If you're a client, the fastest way to reach me is to login to Basecamp, OR email supp...@wildwoodinteractive.com. If you're NOT a client? Why not become one!? :) -- 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
Re: [wtr-general] Javascript created div elements
I'll give the wait a try! Thank you for sending me this information! On Thu, Oct 7, 2010 at 10:07 AM, Željko Filipin zeljko.fili...@wa-research.ch wrote: On Thu, Oct 7, 2010 at 5:05 PM, CJ Romberger c...@wildwoodinteractive.com wrote: No, it's not in a frame, but it doesn't exist if you do view source because the javascript and ajax did a document.write to create it after the first save. That should not be a problem for Watir. Maybe the element it not (yet) there when you check for it, but it is created later. See this: http://wiki.openqa.org/display/WTR/How+to+wait+with+Watir Željko -- 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.comwatir-general%2bunsubscr...@googlegroups.com -- CJ Romberger Wildwood Interactive http://www.wildwoodinteractive.com/ 512.732.9916 PLEASE NOTE: I only check this email address about once a day! If you're a client, the fastest way to reach me is to login to Basecamp, OR email supp...@wildwoodinteractive.com. If you're NOT a client? Why not become one!? :) -- 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
Re: [wtr-general] Manipulate Keystrokes on a MAC
stop sending the same question to the list over and over. On Thu, Oct 7, 2010 at 10:05, Ozzi usmanhhuss...@gmail.com wrote: Hi Guys, If anyone knows how to manipulate keystrokes on a MAC I would be really grateful if you can tell me how to do this. I need to hit the ENTER and TAB keys on the keyboard. I know I can use AutoIT on windows but am totally lost on how to do this on a MAC. Kind regards, Usman Hussain -- 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 -- 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: Manipulate Keystrokes on a MAC
Am just trying to see if anyone has a solution or if anyone has ever come across this problem... maybe asking it in a different way will make people understand the question a bit better?... After all this is a forum where people help each other out... On Oct 7, 4:42 pm, Ethan notet...@gmail.com wrote: stop sending the same question to the list over and over. On Thu, Oct 7, 2010 at 10:05, Ozzi usmanhhuss...@gmail.com wrote: Hi Guys, If anyone knows how to manipulate keystrokes on a MAC I would be really grateful if you can tell me how to do this. I need to hit the ENTER and TAB keys on the keyboard. I know I can use AutoIT on windows but am totally lost on how to do this on a MAC. Kind regards, Usman Hussain -- Before posting, please readhttp://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 -- 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
Re: [wtr-general] Re: Manipulate Keystrokes on a MAC
if you have more to add, add it to the original thread where you asked. On Thu, Oct 7, 2010 at 11:50, Ozzi usmanhhuss...@gmail.com wrote: Am just trying to see if anyone has a solution or if anyone has ever come across this problem... maybe asking it in a different way will make people understand the question a bit better?... After all this is a forum where people help each other out... On Oct 7, 4:42 pm, Ethan notet...@gmail.com wrote: stop sending the same question to the list over and over. On Thu, Oct 7, 2010 at 10:05, Ozzi usmanhhuss...@gmail.com wrote: Hi Guys, If anyone knows how to manipulate keystrokes on a MAC I would be really grateful if you can tell me how to do this. I need to hit the ENTER and TAB keys on the keyboard. I know I can use AutoIT on windows but am totally lost on how to do this on a MAC. Kind regards, Usman Hussain -- Before posting, please readhttp://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.comwatir-general%2bunsubscr...@googlegroups.com -- 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 -- 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: Manipulate Keystrokes on a MAC
I have a similar problem and have been checking the site for a solution for a few days now and still haven't found anything. I am very eager to find a solution to this problem also. In fact I appreciate Ozzi's eagerness to find a solution by posting the problem in different terms to make it more understandable by more users, therefore increasing his (and others) chance to find a solution. Come on guys, someone must have a solution out there for manipulating keystrokes on a MAC? Ethan - HELP if you don't want no more new posts lol On Oct 7, 4:52 pm, Ethan notet...@gmail.com wrote: if you have more to add, add it to the original thread where you asked. On Thu, Oct 7, 2010 at 11:50, Ozzi usmanhhuss...@gmail.com wrote: Am just trying to see if anyone has a solution or if anyone has ever come across this problem... maybe asking it in a different way will make people understand the question a bit better?... After all this is a forum where people help each other out... On Oct 7, 4:42 pm, Ethan notet...@gmail.com wrote: stop sending the same question to the list over and over. On Thu, Oct 7, 2010 at 10:05, Ozzi usmanhhuss...@gmail.com wrote: Hi Guys, If anyone knows how to manipulate keystrokes on a MAC I would be really grateful if you can tell me how to do this. I need to hit the ENTER and TAB keys on the keyboard. I know I can use AutoIT on windows but am totally lost on how to do this on a MAC. Kind regards, Usman Hussain -- Before posting, please readhttp://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.comwatir-general%2bunsubscr...@goog legroups.com -- Before posting, please readhttp://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 -- 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
Re: [wtr-general] Re: Manipulate Keystrokes on a MAC
well, I'd have posted in the original thread if I had a solution. same is true for everybody else, I suspect, so spamming the same thing repeatedly isn't going to help, regardless of minimally different wording. however, generally, sending keystrokes via the operating system is a poor solution (in my opinion), and much more error-prone than going through the DOM. if it's interacting with a web page that is being problematic, it may be just a question of firing the right events in javascript. not knowing more about the actual problem, it's not possible to get more specific than that, but that is my general, broad advice. On Thu, Oct 7, 2010 at 12:02, saqi saqibowl...@gmail.com wrote: I have a similar problem and have been checking the site for a solution for a few days now and still haven't found anything. I am very eager to find a solution to this problem also. In fact I appreciate Ozzi's eagerness to find a solution by posting the problem in different terms to make it more understandable by more users, therefore increasing his (and others) chance to find a solution. Come on guys, someone must have a solution out there for manipulating keystrokes on a MAC? Ethan - HELP if you don't want no more new posts lol On Oct 7, 4:52 pm, Ethan notet...@gmail.com wrote: if you have more to add, add it to the original thread where you asked. On Thu, Oct 7, 2010 at 11:50, Ozzi usmanhhuss...@gmail.com wrote: Am just trying to see if anyone has a solution or if anyone has ever come across this problem... maybe asking it in a different way will make people understand the question a bit better?... After all this is a forum where people help each other out... On Oct 7, 4:42 pm, Ethan notet...@gmail.com wrote: stop sending the same question to the list over and over. On Thu, Oct 7, 2010 at 10:05, Ozzi usmanhhuss...@gmail.com wrote: Hi Guys, If anyone knows how to manipulate keystrokes on a MAC I would be really grateful if you can tell me how to do this. I need to hit the ENTER and TAB keys on the keyboard. I know I can use AutoIT on windows but am totally lost on how to do this on a MAC. Kind regards, Usman Hussain -- Before posting, please readhttp://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.comwatir-general%2bunsubscr...@googlegroups.com watir-general%2bunsubscr...@goog legroups.com -- Before posting, please readhttp://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.comwatir-general%2bunsubscr...@googlegroups.com -- 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 -- 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: How to click on ENTER keystroke using rb-appscript in Watir-WebDriver
Hello, I'm not sure if this is part of AutoIt, but have you tried send_keys? @browser.send_keys('{ENTER}') On Oct 7, 1:52 am, Ozzi usmanhhuss...@gmail.com wrote: Hi Guys, I have a problem... I need to hit the ENTER button on the keyboard on my tests. I was using AutoIT when I was working on Windows and had this: require 'rubygems' require 'win32ole' require 'watir-webdriver' autoit = WIN32OLE.new('AutoITX3.Control') autoit.WinActivate('OK') autoit.Send('{ENTER}') BUT now im using a MAC and this does not work. Ive tried to use rb- appscript after searching the net and have come up with this: require 'rubygems' require 'appscript' require 'watir-webdriver' te = app('OK') te.activate te.key.ENTER BUT this is not working... Has anyone else used rb-appscript? any help would be great. i need this fixed by the end of play today as all of my scripts are failing. would really appreciate anyone who can tell me how to hit the ENTER keystroke on a MAC... Kind regards, Usman Hussain -- 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
Re: [wtr-general] Re: Manipulate Keystrokes on a MAC
I have your solution. DONT BUY A MAC. Go Linux, it's far superior. That being said as Crapple attempts in a lame fashion to follow the *nix realm. Try using some Linux test tools. Can't guarantee they work on a Mac-In-Trash, but here... http://ltp.sourceforge.net/ Linux Test Project. On Thu, Oct 7, 2010 at 9:25 AM, Ethan notet...@gmail.com wrote: well, I'd have posted in the original thread if I had a solution. same is true for everybody else, I suspect, so spamming the same thing repeatedly isn't going to help, regardless of minimally different wording. however, generally, sending keystrokes via the operating system is a poor solution (in my opinion), and much more error-prone than going through the DOM. if it's interacting with a web page that is being problematic, it may be just a question of firing the right events in javascript. not knowing more about the actual problem, it's not possible to get more specific than that, but that is my general, broad advice. On Thu, Oct 7, 2010 at 12:02, saqi saqibowl...@gmail.com wrote: I have a similar problem and have been checking the site for a solution for a few days now and still haven't found anything. I am very eager to find a solution to this problem also. In fact I appreciate Ozzi's eagerness to find a solution by posting the problem in different terms to make it more understandable by more users, therefore increasing his (and others) chance to find a solution. Come on guys, someone must have a solution out there for manipulating keystrokes on a MAC? Ethan - HELP if you don't want no more new posts lol On Oct 7, 4:52 pm, Ethan notet...@gmail.com wrote: if you have more to add, add it to the original thread where you asked. On Thu, Oct 7, 2010 at 11:50, Ozzi usmanhhuss...@gmail.com wrote: Am just trying to see if anyone has a solution or if anyone has ever come across this problem... maybe asking it in a different way will make people understand the question a bit better?... After all this is a forum where people help each other out... On Oct 7, 4:42 pm, Ethan notet...@gmail.com wrote: stop sending the same question to the list over and over. On Thu, Oct 7, 2010 at 10:05, Ozzi usmanhhuss...@gmail.com wrote: Hi Guys, If anyone knows how to manipulate keystrokes on a MAC I would be really grateful if you can tell me how to do this. I need to hit the ENTER and TAB keys on the keyboard. I know I can use AutoIT on windows but am totally lost on how to do this on a MAC. Kind regards, Usman Hussain -- Before posting, please readhttp://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.comwatir-general%2bunsubscr...@googlegroups.com watir-general%2bunsubscr...@goog legroups.com -- Before posting, please readhttp://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.comwatir-general%2bunsubscr...@googlegroups.com -- 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.comhttp://groups.google.com/group/watir-generalwatir-general+unsubscr...@googlegroups.com -- 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.comwatir-general%2bunsubscr...@googlegroups.com -- 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