Sha256: f3e3790afd124de8c544aa773a5ac731225e940f921997113c79d1e385b858dd

Contents?: true

Size: 818 Bytes

Versions: 21

Compression:

Stored size: 818 Bytes

Contents

require "drb/drb"

module Spec
  module Runner
    # Facade to run specs by connecting to a DRB server
    class DrbCommandLine
      # Runs specs on a DRB server. Note that this API is similar to that of
      # CommandLine - making it possible for clients to use both interchangeably.
      def self.run(options)
        begin
          begin; \
            DRb.start_service("druby://localhost:0"); \
          rescue SocketError; \
            DRb.start_service("druby://:0"); \
          end
          spec_server = DRbObject.new_with_uri("druby://127.0.0.1:8989")
          spec_server.run(options.argv, options.error_stream, options.output_stream)
          true
        rescue DRb::DRbConnError
          options.error_stream.puts "No server is running"
          false
        end
      end
    end
  end
end

Version data entries

21 entries across 21 versions & 7 rubygems

Version Path
hubbub-0.0.11 lib/vendor/plugins/rspec/lib/spec/runner/drb_command_line.rb
hubbub-0.0.10 lib/vendor/plugins/rspec/lib/spec/runner/drb_command_line.rb
hubbub-0.0.9 lib/vendor/plugins/rspec/lib/spec/runner/drb_command_line.rb
hubbub-0.0.8 lib/vendor/plugins/rspec/lib/spec/runner/drb_command_line.rb
hubbub-0.0.6 lib/vendor/plugins/rspec/lib/spec/runner/drb_command_line.rb
simple-templater-0.0.1.4 gems/gems/rspec-1.2.9/lib/spec/runner/drb_command_line.rb
simple-templater-0.0.1.3 vendor/rspec/lib/spec/runner/drb_command_line.rb
pupu-0.0.2.pre vendor/rspec/lib/spec/runner/drb_command_line.rb
simple-templater-0.0.1.2 vendor/rspec/lib/spec/runner/drb_command_line.rb
simple-templater-0.0.1.1 vendor/rspec/lib/spec/runner/drb_command_line.rb
pupu-0.0.2 vendor/rspec/lib/spec/runner/drb_command_line.rb
rango-0.0.6 vendor/rspec/lib/spec/runner/drb_command_line.rb
rango-0.1.pre vendor/rspec/lib/spec/runner/drb_command_line.rb
pupu-0.0.1 vendor/rspec/lib/spec/runner/drb_command_line.rb
simple-templater-0.0.1 vendor/rspec/lib/spec/runner/drb_command_line.rb
middleman-0.10.17 vendor/gems/gems/rspec-1.2.9/lib/spec/runner/drb_command_line.rb
middleman-0.10.16 vendor/gems/gems/rspec-1.2.9/lib/spec/runner/drb_command_line.rb
middleman-0.10.15 vendor/gems/gems/rspec-1.2.9/lib/spec/runner/drb_command_line.rb
rackjour-0.1.8 vendor/gems/gems/rspec-1.2.9/lib/spec/runner/drb_command_line.rb
middleman-0.10.14 vendor/gems/gems/rspec-1.2.9/lib/spec/runner/drb_command_line.rb