Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MockServer ¶
type MockServer struct { Network string Address string GrpcServer *grpc.Server // contains filtered or unexported fields }
MockServer provides a mocked out grpc server of the etcdserver interface.
func (*MockServer) ResolverAddress ¶
func (ms *MockServer) ResolverAddress() resolver.Address
type MockServers ¶
type MockServers struct { Servers []*MockServer // contains filtered or unexported fields }
MockServers provides a cluster of mocket out gprc servers of the etcdserver interface.
func StartMockServers ¶
func StartMockServers(count int) (ms *MockServers, err error)
StartMockServers creates the desired count of mock servers and starts them.
func StartMockServersOnNetwork ¶
func StartMockServersOnNetwork(count int, network string) (ms *MockServers, err error)
StartMockServersOnNetwork creates mock servers on either 'tcp' or 'unix' sockets.
func (*MockServers) StartAt ¶
func (ms *MockServers) StartAt(idx int) (err error)
StartAt restarts mock server at given index.
func (*MockServers) Stop ¶
func (ms *MockServers) Stop()
Stop stops the mock server, immediately closing all open connections and listeners.
func (*MockServers) StopAt ¶
func (ms *MockServers) StopAt(idx int)
StopAt stops mock server at given index.
Click to show internal directories.
Click to hide internal directories.