Class: RSpec::Hive::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/rspec/hive/configuration.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(path_to_config_file = nil) ⇒ Configuration

Returns a new instance of Configuration.



15
16
17
18
19
20
21
22
23
24
# File 'lib/rspec/hive/configuration.rb', line 15

def initialize(path_to_config_file = nil)
  if path_to_config_file.nil?
    load_default_variables
  else
    interpolated = ERB.new(File.read(path_to_config_file)).result
    config = YAML.load(interpolated)['hive']
    load_variables_from_config(config)
  end
  @logger = Logger.new(STDOUT)
end

Instance Attribute Details

#connection_timeoutObject

Returns the value of attribute connection_timeout.



6
7
8
# File 'lib/rspec/hive/configuration.rb', line 6

def connection_timeout
  @connection_timeout
end

#docker_shared_directory_pathObject

Returns the value of attribute docker_shared_directory_path.



6
7
8
# File 'lib/rspec/hive/configuration.rb', line 6

def docker_shared_directory_path
  @docker_shared_directory_path
end

#hive_optionsObject

Returns the value of attribute hive_options.



6
7
8
# File 'lib/rspec/hive/configuration.rb', line 6

def hive_options
  @hive_options
end

#hive_versionObject

Returns the value of attribute hive_version.



6
7
8
# File 'lib/rspec/hive/configuration.rb', line 6

def hive_version
  @hive_version
end

#hostObject

Returns the value of attribute host.



6
7
8
# File 'lib/rspec/hive/configuration.rb', line 6

def host
  @host
end

#host_shared_directory_pathObject

Returns the value of attribute host_shared_directory_path.



6
7
8
# File 'lib/rspec/hive/configuration.rb', line 6

def host_shared_directory_path
  @host_shared_directory_path
end

#loggerObject

Returns the value of attribute logger.



6
7
8
# File 'lib/rspec/hive/configuration.rb', line 6

def logger
  @logger
end

#portObject

Returns the value of attribute port.



6
7
8
# File 'lib/rspec/hive/configuration.rb', line 6

def port
  @port
end