Sha256: 975c50ee073b65db06c67baaed14617ea65b137a742cd83dbc3defc7f7cf3069

Contents?: true

Size: 404 Bytes

Versions: 14

Compression:

Stored size: 404 Bytes

Contents

require 'net/http'

module IntegrationHelper
  shared_context 'integration test' do
    before do
      skip 'Integration tests not enabled.' unless ENV['TEST_INTEGRATION']
    end

    def hostname
      ENV['TEST_HOSTNAME']
    end

    def port
      ENV['TEST_PORT']
    end

    def get(path)
      uri = URI("http://#{hostname}:#{port}/#{path}")
      Net::HTTP.get_response(uri)
    end
  end
end

Version data entries

14 entries across 7 versions & 1 rubygems

Version Path
ddtrace-0.51.1 integration/apps/rails-five/spec/support/integration_helper.rb
ddtrace-0.51.1 integration/apps/rack/spec/support/integration_helper.rb
ddtrace-0.51.0 integration/apps/rails-five/spec/support/integration_helper.rb
ddtrace-0.51.0 integration/apps/rack/spec/support/integration_helper.rb
ddtrace-0.50.0 integration/apps/rack/spec/support/integration_helper.rb
ddtrace-0.50.0 integration/apps/rails-five/spec/support/integration_helper.rb
ddtrace-0.49.0 integration/apps/rails-five/spec/support/integration_helper.rb
ddtrace-0.49.0 integration/apps/rack/spec/support/integration_helper.rb
ddtrace-0.48.0 integration/apps/rails-five/spec/support/integration_helper.rb
ddtrace-0.48.0 integration/apps/rack/spec/support/integration_helper.rb
ddtrace-0.47.0 integration/apps/rails-five/spec/support/integration_helper.rb
ddtrace-0.47.0 integration/apps/rack/spec/support/integration_helper.rb
ddtrace-0.46.0 integration/apps/rack/spec/support/integration_helper.rb
ddtrace-0.46.0 integration/apps/rails-five/spec/support/integration_helper.rb