Class: MockEtcd::Client

Inherits:
Etcd::Client
  • Object
show all
Defined in:
lib/mock_etcd/client.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(opts = {}) ⇒ Client

Returns a new instance of Client.



9
10
11
12
13
14
# File 'lib/mock_etcd/client.rb', line 9

def initialize(opts = {})
  @index = 0
  @nodes = {}

  super
end

Instance Attribute Details

#nodesObject (readonly)

Returns the value of attribute nodes.



7
8
9
# File 'lib/mock_etcd/client.rb', line 7

def nodes
  @nodes
end

Instance Method Details

#api_execute(path, method, options = {}) ⇒ Object



15
16
17
18
19
# File 'lib/mock_etcd/client.rb', line 15

def api_execute(path, method, options = {})
  stub_request! path, method, options

  super
end