How to handle authentication pop-up when the machine is lock

P

Parul Korea

I am facing issues while handling authentication pop-up when my machine
is locked.
I have scheduled my ruby script to run at a particular time. The script
does not get executed when it encounters an authentication pop-up.
Authentication pop-up stays idle.
Below is the peace of code which I am using. The same code works fine
when the machine is not locked.

require 'watir'
require 'ci/reporter/rake/test_unit_loader.rb'
require 'test/unit'
require 'watir/close_all'
require 'test/unit/ui/console/testrunner'
require 'test/unit/ui/reporter'
require 'fileutils'
include FileUtils::Verbose
require 'stringio'
require 'watir/WindowHelper'

class TestSuite_authentication < Test::Unit::TestCase
def setup
@url = 'stage.remotedonationtest.networkforgood.org'
@login_title = "Connect to #{@url}"

@username = 'abc\test'
@password = 'testpassword'

end

def test_logon
a = Thread.new {
system("ruby handle_logon.rb \"#{@login_title}\" \"#{@username}\"
\"#{@password}\"")
}

$ie = Watir::IE.start(@url)
#~ $ie.goto('stage.remotedonationtest.networkforgood.org')

a.join


# continue code here...

end

end
 

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,755
Messages
2,569,536
Members
45,011
Latest member
AjaUqq1950

Latest Threads

Top