hcloudtest

package
v0.3.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 3, 2018 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewActionClientMock

func NewActionClientMock() hcloud_wrapped.ActionClient

NewActionClientMock creates a new ActionClient mock

func NewFloatingIPClientMock

func NewFloatingIPClientMock() hcloud.FloatingIPClient

NewFloatingIPClientMock creates a FloatingIPClientMock

func NewISOClientMock added in v0.3.2

func NewISOClientMock() hcloud_wrapped.ISOClient

NewISOClientMock creates a new ISOClientMock

func NewImageClientMock added in v0.3.0

func NewImageClientMock() hcloud.ImageClient

NewImageClientMock creates a new ImageClientMock

func NewSSHClientMock

func NewSSHClientMock() hcloud_wrapped.SSHKeyClient

NewSSHClientMock creates a new SSHKeyClientMock

func NewServerClientMock

func NewServerClientMock() hcloud_wrapped.ServerClient

NewServerClientMock creates a new ServerClientMock

func NewServerTypeClientMock added in v0.3.0

func NewServerTypeClientMock() hcloud.ServerTypeClient

NewServerTypeClientMock creates a new ServerTypeClientMock

Types

type ActionClientMock

type ActionClientMock struct {
	mock.Mock
}

ActionClientMock mocks the hcloud.ActionClient interface

func (*ActionClientMock) All

func (m *ActionClientMock) All(ctx context.Context) ([]*hcloud.Action, error)

All mock

func (*ActionClientMock) GetByID

func (m *ActionClientMock) GetByID(ctx context.Context, id int) (*hcloud.Action, *hcloud.Response, error)

GetByID mock

func (*ActionClientMock) List

List mock

func (*ActionClientMock) WatchProgress

func (m *ActionClientMock) WatchProgress(ctx context.Context, action *hcloud.Action) (<-chan int, <-chan error)

WatchProgress mock

type FloatingIPClientMock

type FloatingIPClientMock struct {
	mock.Mock
}

FloatingIPClientMock mock of hcloud.FloatingIPClient

func (*FloatingIPClientMock) All

All mock

func (*FloatingIPClientMock) Assign

func (m *FloatingIPClientMock) Assign(ctx context.Context, floatingIP *hcloud.FloatingIP, server *hcloud.Server) (*hcloud.Action, *hcloud.Response, error)

Assign mock

func (*FloatingIPClientMock) Create

Create mock

func (*FloatingIPClientMock) Delete

func (m *FloatingIPClientMock) Delete(ctx context.Context, floatingIP *hcloud.FloatingIP) (*hcloud.Response, error)

Delete mock

func (*FloatingIPClientMock) GetByID

GetByID mock

func (*FloatingIPClientMock) List

List mock

func (*FloatingIPClientMock) Unassign

func (m *FloatingIPClientMock) Unassign(ctx context.Context, floatingIP *hcloud.FloatingIP) (*hcloud.Action, *hcloud.Response, error)

Unassign mock

func (*FloatingIPClientMock) Update

Update mock

type ISOClientMock added in v0.3.2

type ISOClientMock struct {
	mock.Mock
}

ISOClientMock mocks the ISOClient interface

func (*ISOClientMock) Get added in v0.3.2

func (m *ISOClientMock) Get(ctx context.Context, idOrName string) (*hcloud.ISO, *hcloud.Response, error)

Get mock

func (*ISOClientMock) GetByID added in v0.3.2

func (m *ISOClientMock) GetByID(ctx context.Context, id int) (*hcloud.ISO, *hcloud.Response, error)

GetByID mock

func (*ISOClientMock) GetByName added in v0.3.2

func (m *ISOClientMock) GetByName(ctx context.Context, name string) (*hcloud.ISO, *hcloud.Response, error)

GetByName mock

type ImageClientMock added in v0.3.0

type ImageClientMock struct {
	mock.Mock
}

ImageClientMock mocks the ImageClient interface

func (*ImageClientMock) All added in v0.3.0

func (m *ImageClientMock) All(ctx context.Context) ([]*hcloud.Image, error)

All mock

func (*ImageClientMock) Delete added in v0.3.0

func (m *ImageClientMock) Delete(ctx context.Context, image *hcloud.Image) (*hcloud.Response, error)

Delete mock

func (*ImageClientMock) Get added in v0.3.0

func (m *ImageClientMock) Get(ctx context.Context, idOrName string) (*hcloud.Image, *hcloud.Response, error)

Get mock

func (*ImageClientMock) GetByID added in v0.3.0

func (m *ImageClientMock) GetByID(ctx context.Context, id int) (*hcloud.Image, *hcloud.Response, error)

GetByID mock

func (*ImageClientMock) GetByName added in v0.3.0

func (m *ImageClientMock) GetByName(ctx context.Context, name string) (*hcloud.Image, *hcloud.Response, error)

GetByName mock

func (*ImageClientMock) List added in v0.3.0

List mock

type SSHKeyClientMock

type SSHKeyClientMock struct {
	mock.Mock
}

SSHKeyClientMock mocks the hcloud.SSHKeyClient interface

func (*SSHKeyClientMock) All

func (m *SSHKeyClientMock) All(ctx context.Context) ([]*hcloud.SSHKey, error)

All mock

func (*SSHKeyClientMock) Create

Create mock

func (*SSHKeyClientMock) Delete

func (m *SSHKeyClientMock) Delete(ctx context.Context, sshKey *hcloud.SSHKey) (*hcloud.Response, error)

Delete mock

func (*SSHKeyClientMock) Get

func (m *SSHKeyClientMock) Get(ctx context.Context, idOrName string) (*hcloud.SSHKey, *hcloud.Response, error)

Get mock

func (*SSHKeyClientMock) GetByID

func (m *SSHKeyClientMock) GetByID(ctx context.Context, id int) (*hcloud.SSHKey, *hcloud.Response, error)

GetByID mock

func (*SSHKeyClientMock) GetByName

func (m *SSHKeyClientMock) GetByName(ctx context.Context, name string) (*hcloud.SSHKey, *hcloud.Response, error)

GetByName mock

func (*SSHKeyClientMock) Update

Update mock

type ServerClientMock

type ServerClientMock struct {
	mock.Mock
}

ServerClientMock mocks the ServerClient interface

func (*ServerClientMock) All

func (m *ServerClientMock) All(ctx context.Context) ([]*hcloud.Server, error)

All mock

func (*ServerClientMock) AttachISO added in v0.3.2

func (m *ServerClientMock) AttachISO(ctx context.Context, server *hcloud.Server, iso *hcloud.ISO) (*hcloud.Action, *hcloud.Response, error)

AttachISO mock

func (*ServerClientMock) Create

Create mock

func (*ServerClientMock) Delete

func (m *ServerClientMock) Delete(ctx context.Context, server *hcloud.Server) (*hcloud.Response, error)

Delete mock

func (*ServerClientMock) DetachISO added in v0.3.2

func (m *ServerClientMock) DetachISO(ctx context.Context, server *hcloud.Server) (*hcloud.Action, *hcloud.Response, error)

DetachISO mock

func (*ServerClientMock) DisableBackup

func (m *ServerClientMock) DisableBackup(ctx context.Context, server *hcloud.Server) (*hcloud.Action, *hcloud.Response, error)

DisableBackup mock

func (*ServerClientMock) DisableRescue

func (m *ServerClientMock) DisableRescue(ctx context.Context, server *hcloud.Server) (*hcloud.Action, *hcloud.Response, error)

DisableRescue mock

func (*ServerClientMock) EnableBackup

func (m *ServerClientMock) EnableBackup(ctx context.Context, server *hcloud.Server, window string) (*hcloud.Action, *hcloud.Response, error)

EnableBackup mock

func (*ServerClientMock) EnableRescue

EnableRescue mock

func (*ServerClientMock) Get

func (m *ServerClientMock) Get(ctx context.Context, idOrName string) (*hcloud.Server, *hcloud.Response, error)

Get mock

func (*ServerClientMock) GetByID

func (m *ServerClientMock) GetByID(ctx context.Context, id int) (*hcloud.Server, *hcloud.Response, error)

GetByID mock

func (*ServerClientMock) GetByName

func (m *ServerClientMock) GetByName(ctx context.Context, name string) (*hcloud.Server, *hcloud.Response, error)

GetByName mock

func (*ServerClientMock) Poweroff

func (m *ServerClientMock) Poweroff(ctx context.Context, server *hcloud.Server) (*hcloud.Action, *hcloud.Response, error)

Poweroff mock

func (*ServerClientMock) Poweron

func (m *ServerClientMock) Poweron(ctx context.Context, server *hcloud.Server) (*hcloud.Action, *hcloud.Response, error)

Poweron mock

func (*ServerClientMock) Reboot

Reboot mock

func (*ServerClientMock) Reset

Reset mock

func (*ServerClientMock) Update

Update mock

type ServerTypeClientMock added in v0.3.0

type ServerTypeClientMock struct {
	mock.Mock
}

ServerTypeClientMock mocks the ServerTypeClient interface

func (*ServerTypeClientMock) All added in v0.3.0

All mock

func (*ServerTypeClientMock) Get added in v0.3.0

Get mock

func (*ServerTypeClientMock) GetByID added in v0.3.0

GetByID mock

func (*ServerTypeClientMock) GetByName added in v0.3.0

GetByName mock

func (*ServerTypeClientMock) List added in v0.3.0

List mock

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL