123456789_123456789_123456789_123456789_123456789_

Class: RSpec::Core::DRbRunner Private

Do not use. This class is for internal use only.
Relationships & Source Files
Inherits: Object
Defined in: rspec-core/lib/rspec/core/drb.rb

Class Method Summary

Instance Method Summary

Instance Method Details

#drb_argv

[ GitHub ]

  
# File 'rspec-core/lib/rspec/core/drb.rb', line 26

def drb_argv
  @drb_argv ||= begin
    @options.configure_filter_manager(@configuration.filter_manager)
    DRbOptions.new(@options.options, @configuration.filter_manager).options
  end
end

#drb_port

[ GitHub ]

  
# File 'rspec-core/lib/rspec/core/drb.rb', line 12

def drb_port
  @options.options[:drb_port] || ENV['RSPEC_DRB'] || 8989
end

#run(err, out)

[ GitHub ]

  
# File 'rspec-core/lib/rspec/core/drb.rb', line 16

def run(err, out)
  begin
    DRb.start_service("druby://localhost:0")
  rescue SocketError, Errno::EADDRNOTAVAIL
    DRb.start_service("druby://:0")
  end
  spec_server = DRbObject.new_with_uri("druby://127.0.0.1:#{drb_port}")
  spec_server.run(drb_argv, err, out)
end