Class: QAT::Reporter::Opentest::Publisher::Base::Client
- Inherits:
-
Object
- Object
- QAT::Reporter::Opentest::Publisher::Base::Client
- Defined in:
- lib/qat/reporter/opentest/publisher/base.rb
Overview
REST Base Client implementation
Defined Under Namespace
Classes: ConnectionError, NoConnectionFound, NoTestsFound, ServiceUnavailableError
Instance Attribute Summary collapse
-
#base_uri ⇒ Object
readonly
Returns the value of attribute base_uri.
Instance Method Summary collapse
-
#initialize(base_uri) ⇒ RestClient::Response
constructor
Returns a new REST Base Client.
Constructor Details
#initialize(base_uri) ⇒ RestClient::Response
Returns a new REST Base Client
49 50 51 52 53 54 55 56 57 58 59 60 61 |
# File 'lib/qat/reporter/opentest/publisher/base.rb', line 49 def initialize(base_uri) # sets the ip:port/base_route @base_uri = case base_uri when Hash URI::HTTP.build(base_uri).to_s when URI::HTTP base_uri.to_s when String base_uri else raise ArgumentError.new "Invalid URI class: #{base_uri.class}" end end |
Instance Attribute Details
#base_uri ⇒ Object (readonly)
Returns the value of attribute base_uri.
45 46 47 |
# File 'lib/qat/reporter/opentest/publisher/base.rb', line 45 def base_uri @base_uri end |