fake

package
v1.13.3 Latest Latest
Warning

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

Go to latest
Published: Feb 1, 2019 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CSIVolume added in v1.12.0

type CSIVolume struct {
	VolumeContext map[string]string
	Path          string
	MountFlags    []string
}

type Closer added in v1.13.1

type Closer struct {
	// contains filtered or unexported fields
}

func NewCloser added in v1.13.1

func NewCloser(t *testing.T) *Closer

func (*Closer) Check added in v1.13.1

func (c *Closer) Check() *Closer

func (*Closer) Close added in v1.13.1

func (c *Closer) Close() error

type ControllerClient

type ControllerClient struct {
	// contains filtered or unexported fields
}

ControllerClient represents a CSI Controller client

func NewControllerClient

func NewControllerClient() *ControllerClient

NewControllerClient returns a ControllerClient

func (*ControllerClient) ControllerGetCapabilities

ControllerGetCapabilities implements csi method

func (*ControllerClient) ControllerPublishVolume

ControllerPublishVolume implements csi method

func (*ControllerClient) ControllerUnpublishVolume

ControllerUnpublishVolume implements csi method

func (*ControllerClient) CreateVolume

CreateVolume implements csi method

func (*ControllerClient) DeleteVolume

DeleteVolume implements csi method

func (*ControllerClient) GetCapacity

GetCapacity implements csi method

func (*ControllerClient) ListVolumes

ListVolumes implements csi method

func (*ControllerClient) SetNextCapabilities

func (f *ControllerClient) SetNextCapabilities(caps []*csipb.ControllerServiceCapability)

SetNextCapabilities injects next expected capabilities

func (*ControllerClient) SetNextError

func (f *ControllerClient) SetNextError(err error)

SetNextError injects next expected error

func (*ControllerClient) ValidateVolumeCapabilities

ValidateVolumeCapabilities implements csi method

type IdentityClient

type IdentityClient struct {
	// contains filtered or unexported fields
}

IdentityClient is a CSI identity client used for testing

func NewIdentityClient

func NewIdentityClient() *IdentityClient

NewIdentityClient returns a new IdentityClient

func (*IdentityClient) GetPluginCapabilities added in v1.10.8

GetPluginCapabilities implements csi method

func (*IdentityClient) GetPluginInfo

GetPluginInfo returns plugin info

func (*IdentityClient) Probe added in v1.10.8

Probe implements csi method

func (*IdentityClient) SetNextError

func (f *IdentityClient) SetNextError(err error)

SetNextError injects expected error

type NodeClient

type NodeClient struct {
	// contains filtered or unexported fields
}

NodeClient returns CSI node client

func NewNodeClient

func NewNodeClient(stageUnstageSet bool) *NodeClient

NewNodeClient returns fake node client

func (*NodeClient) AddNodeStagedVolume added in v1.10.8

func (f *NodeClient) AddNodeStagedVolume(volID, deviceMountPath string, volumeContext map[string]string)

func (*NodeClient) GetNodePublishedVolumes

func (f *NodeClient) GetNodePublishedVolumes() map[string]CSIVolume

GetNodePublishedVolumes returns node published volumes

func (*NodeClient) GetNodeStagedVolumes added in v1.10.8

func (f *NodeClient) GetNodeStagedVolumes() map[string]CSIVolume

GetNodeStagedVolumes returns node staged volumes

func (*NodeClient) NodeGetCapabilities

NodeGetCapabilities implements csi method

func (*NodeClient) NodeGetInfo added in v1.11.6

NodeGetId implements csi method

func (*NodeClient) NodeGetVolumeStats added in v1.13.1

NodeGetVolumeStats implements csi method

func (*NodeClient) NodePublishVolume

NodePublishVolume implements CSI NodePublishVolume

func (*NodeClient) NodeStageVolume added in v1.10.8

NodeStagevolume implements csi method

func (*NodeClient) NodeUnpublishVolume

NodeUnpublishVolume implements csi method

func (*NodeClient) NodeUnstageVolume added in v1.10.8

NodeUnstageVolume implements csi method

func (*NodeClient) SetNextError

func (f *NodeClient) SetNextError(err error)

SetNextError injects next expected error

func (*NodeClient) SetNodeGetInfoResp added in v1.11.6

func (f *NodeClient) SetNodeGetInfoResp(resp *csipb.NodeGetInfoResponse)

Jump to

Keyboard shortcuts

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