If the url option below works for you that might be easiest (our developers did something that prevented it from working). Otherwise this is how i got around the issue in firefox ( http://watirmelon.com/2012/06/27/automatic-firefox-authentication-when-using-selenium-webdriver-with-autoauth/). The gist is that you create a firefox profile and start the browser with that profile. Something similar might be possible for chome, i haven't played around with it yet since we don't support chrome for our application.
I don't have a solution for ie (i was using a local vm that hadn't been picking up on my active directory login). On Tue, Sep 4, 2012 at 1:23 PM, kloppet <[email protected]> wrote: > Hello, > > I'm running into the exact same problem. Did you ever find a solution for > this? > > On Monday, February 6, 2012 1:21:28 PM UTC-6, hillary wrote: >> >> I have an internal site that doesn't have a login page. Instead users >> will only have access to it based on their Active Directory credentials. >> There is no login page, instead users login through a windows >> authentication prompt. >> >> I'm using taza as my framework so i have a feeling that i'm going to need >> to update my the browser class, but i'm not sure where to begin. >> >> So i have two problems: >> 1. Loading the site in firefox/ie 8 (windows xp) produces the >> authentication dialog (ie 9seems to be using the credentials of my login to >> determine access so i'm not prompted). >> >> 2. Part of testing this site is that users depending on their AD group >> only have access to only certain CRUD functions. So i'm going to need to be >> able to start/login ie, firefox, and maybe chrome with a different test AD >> login. Has anyone done this type of testing before? >> so i think i edited the registry correctly. >> >> Things I've tried. >> >> i've tried the Watir::Browser.start "http://username:password@**yoururl" >> idea in webdriver, but it doesn't seem to be working because i still get >> the dialog for firefox. I was going to try rautomation, but it when i do a >> goto/start that process doesn't finish, the browser just hangs because it >> doesn't connect to the site unless the user authenticates. Also i've >> looked at this page http://wiki.openqa.org/**display/WTR/Basic+** >> Authentication <http://wiki.openqa.org/display/WTR/Basic+Authentication>but >> it kinda confuses me. Also it all seems to be autoit solutions, and i'd >> rather not use autoit if possible. Also I don't think autoit works for >> firefox, correct? >> >> For number 2 I think the solution might be using the browser start url >> idea, but again it's not working. When I followed the instructions here >> http://watirmelon.com/2010/11/**24/elegantly-handling-basic-** >> browser-authentication-with-**watir/<http://watirmelon.com/2010/11/24/elegantly-handling-basic-browser-authentication-with-watir/> >> I get this error >> >> WIN32OLERuntimeError: (in OLE method `navigate': ) >> OLE error code:800C000E in <Unknown> >> <No Description> >> HRESULT error code:0x80020009 >> Exception occurred. >> from C:/Ruby192/lib/ruby/gems/1.9.**1/gems/watir-3.0.0.rc1/lib/** >> watir/ie-cl >> ass.rb:384:in `method_missing' >> from C:/Ruby192/lib/ruby/gems/1.9.**1/gems/watir-3.0.0.rc1/lib/** >> watir/ie-cl >> ass.rb:384:in `goto' >> from C:/Ruby192/lib/ruby/gems/1.9.**1/gems/watir-3.0.0.rc1/lib/** >> watir/ie-cl >> ass.rb:116:in `start_window' >> from C:/Ruby192/lib/ruby/gems/1.9.**1/gems/watir-3.0.0.rc1/lib/** >> watir/ie-cl >> ass.rb:109:in `start' >> from C:/Ruby192/lib/ruby/gems/1.9.**1/gems/commonwatir-3.0.0.rc1/ >> **lib/watir >> /browser.rb:71:in `start' >> from (irb):2 >> from C:/Ruby192/bin/irb:12:in `<main>' >> >> >> >> >> -- > Before posting, please read http://watir.com/support. In short: search > before you ask, be nice. > > [email protected] > http://groups.google.com/group/watir-general > [email protected] > -- Before posting, please read http://watir.com/support. In short: search before you ask, be nice. [email protected] http://groups.google.com/group/watir-general [email protected]
