I am trying to detect when a Facebook pop-up is displayed to then fill out the Facebook login form. I have tried the attach method, also the wait method, and the sleep method but it seems that as soon as I launch the new page all connection is lost:
#this output is displayed
puts "lets the game begingsx"
$b.goto("javascript:gigya.services.socialize.plugins.login.providerClick('loginPluginDiv','facebook')")
#this output is never displayed
puts "lets start sleep"
$b.window(:title,/Log In | Facebook/i).use do
$b.text_field(:id => 'email').when_present.set("xyz@gmail.com")
end