Object
@private
# File firefox/src/rb/lib/selenium/webdriver/firefox/binary.rb, line 36 def cope_with_mac_strangeness(args) sleep 0.3 if @process.ugly_death? # process crashed, trying a restart. sleeping 5 seconds shorter than the java driver sleep 5 execute(*args) end # ensure we're ok sleep 0.3 if @process.ugly_death? raise Error::WebDriverError, "unable to start Firefox cleanly, args: #{args.inspect}" end end
# File firefox/src/rb/lib/selenium/webdriver/firefox/binary.rb, line 12 def create_base_profile(name) execute("-CreateProfile", name) status = nil Timeout.timeout(15, Error::TimeOutError) do _, status = wait end if status && status.to_i != 0 raise Error::WebDriverError, "could not create base profile: (exit status: #{status})" end end
# File firefox/src/rb/lib/selenium/webdriver/firefox/binary.rb, line 31 def execute(*extra_args) args = [self.class.path, "-no-remote", "--verbose"] + extra_args @process = ChildProcess.new(*args).start end
# File firefox/src/rb/lib/selenium/webdriver/firefox/binary.rb, line 56 def kill @process.kill if @process end
# File firefox/src/rb/lib/selenium/webdriver/firefox/binary.rb, line 64 def pid @process.pid if @process end
# File firefox/src/rb/lib/selenium/webdriver/firefox/binary.rb, line 52 def quit @process.ensure_death if @process end
Generated with the Darkfish Rdoc Generator 2.