test

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Mar 3, 2017 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Copyright 2016 The Rook Authors. All rights reserved.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MockRookRestClient

type MockRookRestClient struct {
	MockGetNodes                     func() ([]model.Node, error)
	MockGetPools                     func() ([]model.Pool, error)
	MockCreatePool                   func(pool model.Pool) (string, error)
	MockGetBlockImages               func() ([]model.BlockImage, error)
	MockCreateBlockImage             func(image model.BlockImage) (string, error)
	MockGetClientAccessInfo          func() (model.ClientAccessInfo, error)
	MockGetFilesystems               func() ([]model.Filesystem, error)
	MockCreateFilesystem             func(model.FilesystemRequest) (string, error)
	MockDeleteFilesystem             func(model.FilesystemRequest) (string, error)
	MockGetStatusDetails             func() (model.StatusDetails, error)
	MockCreateObjectStore            func() (string, error)
	MockGetObjectStoreConnectionInfo func() (*model.ObjectStoreConnectInfo, error)
	MockCreateObjectUser             func(model.ObjectUser) (*model.ObjectUser, error)
	MockListBuckets                  func() ([]model.ObjectBucket, error)
	MockListObjectUsers              func() ([]model.ObjectUser, error)
	MockGetObjectUser                func(string) (*model.ObjectUser, error)
	MockUpdateObjectUser             func(model.ObjectUser) (*model.ObjectUser, error)
	MockDeleteObjectUser             func(string) error
}

Mock Rook REST Client implementation

func (*MockRookRestClient) CreateBlockImage

func (m *MockRookRestClient) CreateBlockImage(image model.BlockImage) (string, error)

func (*MockRookRestClient) CreateFilesystem added in v0.1.1

func (m *MockRookRestClient) CreateFilesystem(fsr model.FilesystemRequest) (string, error)

func (*MockRookRestClient) CreateObjectStore added in v0.2.0

func (m *MockRookRestClient) CreateObjectStore() (string, error)

func (*MockRookRestClient) CreateObjectUser added in v0.3.0

func (m *MockRookRestClient) CreateObjectUser(u model.ObjectUser) (*model.ObjectUser, error)

func (*MockRookRestClient) CreatePool

func (m *MockRookRestClient) CreatePool(pool model.Pool) (string, error)

func (*MockRookRestClient) DeleteFilesystem added in v0.1.1

func (m *MockRookRestClient) DeleteFilesystem(fsr model.FilesystemRequest) (string, error)

func (*MockRookRestClient) DeleteObjectUser added in v0.3.0

func (m *MockRookRestClient) DeleteObjectUser(s string) error

func (*MockRookRestClient) GetBlockImages

func (m *MockRookRestClient) GetBlockImages() ([]model.BlockImage, error)

func (*MockRookRestClient) GetClientAccessInfo added in v0.1.1

func (m *MockRookRestClient) GetClientAccessInfo() (model.ClientAccessInfo, error)

func (*MockRookRestClient) GetFilesystems added in v0.1.1

func (m *MockRookRestClient) GetFilesystems() ([]model.Filesystem, error)

func (*MockRookRestClient) GetNodes

func (m *MockRookRestClient) GetNodes() ([]model.Node, error)

func (*MockRookRestClient) GetObjectStoreConnectionInfo added in v0.2.0

func (m *MockRookRestClient) GetObjectStoreConnectionInfo() (*model.ObjectStoreConnectInfo, error)

func (*MockRookRestClient) GetObjectUser added in v0.3.0

func (m *MockRookRestClient) GetObjectUser(s string) (*model.ObjectUser, error)

func (*MockRookRestClient) GetPools

func (m *MockRookRestClient) GetPools() ([]model.Pool, error)

func (*MockRookRestClient) GetStatusDetails

func (m *MockRookRestClient) GetStatusDetails() (model.StatusDetails, error)

func (*MockRookRestClient) ListBuckets added in v0.3.0

func (m *MockRookRestClient) ListBuckets() ([]model.ObjectBucket, error)

func (*MockRookRestClient) ListObjectUsers added in v0.3.0

func (m *MockRookRestClient) ListObjectUsers() ([]model.ObjectUser, error)

func (*MockRookRestClient) URL

func (m *MockRookRestClient) URL() string

func (*MockRookRestClient) UpdateObjectUser added in v0.3.0

func (m *MockRookRestClient) UpdateObjectUser(u model.ObjectUser) (*model.ObjectUser, error)

type RookMockRestClientFactory

type RookMockRestClientFactory struct{}

func (*RookMockRestClientFactory) CreateRookRestClient

func (*RookMockRestClientFactory) CreateRookRestClient(url string, httpClient *http.Client) client.RookRestClient

Jump to

Keyboard shortcuts

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