Class: Train::Transports::K8sHack

Inherits:
Object
  • Object
show all
Defined in:
lib/kitchen/verifier/k8s.rb

Defined Under Namespace

Classes: Connection

Instance Method Summary collapse

Instance Method Details

#connection(state = {}) ⇒ Object



15
16
17
18
19
20
21
22
23
24
# File 'lib/kitchen/verifier/k8s.rb', line 15

def connection(state = {})
  opts = merge_options(options, state || {})
  validate_options(opts)
  opts[:logger] ||= logger
  unless @connection && @connection_opts == opts
    @connection ||= Connection.new(opts)
    @connection_opts = opts.dup
  end
  @connection
end