From 9b2cb308501ce825c1f350f6300bf23a0a62b5e1 Mon Sep 17 00:00:00 2001 From: root Date: Mon, 11 Dec 2023 05:50:14 -0500 Subject: [PATCH] update mock test --- Makefile | 17 +- api/api_query_params.go | 2 +- metrics_types.go | 1 + mocks/ApiClient.go | 90 +++-- mocks/Client.go | 602 ++++++++++++++++++++++++++++- mocks/FieldProvider.go | 36 +- mocks/Logger.go | 39 +- mocks/QueryParamsEncoder.go | 66 +++- mocks/RequestConfigRenderer.go | 42 +- mocks/TimeoutSemaphoreInterface.go | 50 ++- mocks/Traceable.go | 47 ++- 11 files changed, 836 insertions(+), 156 deletions(-) diff --git a/Makefile b/Makefile index 5801e0a..2a447cf 100644 --- a/Makefile +++ b/Makefile @@ -33,13 +33,24 @@ int-test: gocover: go tool cover -html=c.out -check: mock-test gosec +check: mocks gosec gofmt -w ./. golint ./... go vet mocks: +ifeq (, $(shell which mockery)) + go install github.com/vektra/mockery/v2@latest + $(shell $(GOBIN)/mockery --all) +else mockery --all - +endif gosec: - gosec -quiet -log gosec.log -out=gosecresults.csv -fmt=csv ./... +ifeq (, $(shell which gosec)) + go install github.com/securego/gosec/v2/cmd/gosec@latest + $(shell $(GOBIN)/gosec -quiet -log gosec.log -out=gosecresults.csv -fmt=csv ./...) +else + $(shell gosec -quiet -log gosec.log -out=gosecresults.csv -fmt=csv ./...) +endif + @echo "Logs are stored at gosec.log, Outputfile at gosecresults.csv" + diff --git a/api/api_query_params.go b/api/api_query_params.go index 8acedc6..3abc26e 100644 --- a/api/api_query_params.go +++ b/api/api_query_params.go @@ -119,7 +119,7 @@ func (qp *QueryParams) Async(value bool) QueryParamsEncoder { return qp } -// Encode encodes the values into ``URL encoded'' form +// Encode encodes the values into “URL encoded” form // ("bar=baz&foo=quux") sorted by key. func (qp *QueryParams) Encode() string { q := make(url.Values) diff --git a/metrics_types.go b/metrics_types.go index 8f63ea8..5d3cb26 100644 --- a/metrics_types.go +++ b/metrics_types.go @@ -25,6 +25,7 @@ type CopySessionTypeEnum string /* Intervals of which metrics can be provided + Enum: [ Twenty_Sec, Five_Mins, One_Hour, One_Day ] */ diff --git a/mocks/ApiClient.go b/mocks/ApiClient.go index 46e6d75..5b4dbda 100644 --- a/mocks/ApiClient.go +++ b/mocks/ApiClient.go @@ -1,45 +1,61 @@ -/* - * - * Copyright © 2021-2022 Dell Inc. or its subsidiaries. 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. - * - */ - -// Code generated by mockery v1.0.0. DO NOT EDIT. +// Code generated by mockery v2.38.0. DO NOT EDIT. package mocks -import api "github.com/dell/gopowerstore/api" -import context "context" -import http "net/http" -import mock "github.com/stretchr/testify/mock" +import ( + context "context" + + api "github.com/dell/gopowerstore/api" + + http "net/http" + + mock "github.com/stretchr/testify/mock" +) // ApiClient is an autogenerated mock type for the ApiClient type type ApiClient struct { mock.Mock } +// GetCustomHTTPHeaders provides a mock function with given fields: +func (_m *ApiClient) GetCustomHTTPHeaders() http.Header { + ret := _m.Called() + + if len(ret) == 0 { + panic("no return value specified for GetCustomHTTPHeaders") + } + + var r0 http.Header + if rf, ok := ret.Get(0).(func() http.Header); ok { + r0 = rf() + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(http.Header) + } + } + + return r0 +} + // Query provides a mock function with given fields: ctx, cfg, resp func (_m *ApiClient) Query(ctx context.Context, cfg api.RequestConfigRenderer, resp interface{}) (api.RespMeta, error) { ret := _m.Called(ctx, cfg, resp) + if len(ret) == 0 { + panic("no return value specified for Query") + } + var r0 api.RespMeta + var r1 error + if rf, ok := ret.Get(0).(func(context.Context, api.RequestConfigRenderer, interface{}) (api.RespMeta, error)); ok { + return rf(ctx, cfg, resp) + } if rf, ok := ret.Get(0).(func(context.Context, api.RequestConfigRenderer, interface{}) api.RespMeta); ok { r0 = rf(ctx, cfg, resp) } else { r0 = ret.Get(0).(api.RespMeta) } - var r1 error if rf, ok := ret.Get(1).(func(context.Context, api.RequestConfigRenderer, interface{}) error); ok { r1 = rf(ctx, cfg, resp) } else { @@ -53,6 +69,10 @@ func (_m *ApiClient) Query(ctx context.Context, cfg api.RequestConfigRenderer, r func (_m *ApiClient) QueryParams() api.QueryParamsEncoder { ret := _m.Called() + if len(ret) == 0 { + panic("no return value specified for QueryParams") + } + var r0 api.QueryParamsEncoder if rf, ok := ret.Get(0).(func() api.QueryParamsEncoder); ok { r0 = rf() @@ -69,6 +89,10 @@ func (_m *ApiClient) QueryParams() api.QueryParamsEncoder { func (_m *ApiClient) QueryParamsWithFields(provider api.FieldProvider) api.QueryParamsEncoder { ret := _m.Called(provider) + if len(ret) == 0 { + panic("no return value specified for QueryParamsWithFields") + } + var r0 api.QueryParamsEncoder if rf, ok := ret.Get(0).(func(api.FieldProvider) api.QueryParamsEncoder); ok { r0 = rf(provider) @@ -95,6 +119,10 @@ func (_m *ApiClient) SetLogger(logger api.Logger) { func (_m *ApiClient) SetTraceID(ctx context.Context, traceID string) context.Context { ret := _m.Called(ctx, traceID) + if len(ret) == 0 { + panic("no return value specified for SetTraceID") + } + var r0 context.Context if rf, ok := ret.Get(0).(func(context.Context, string) context.Context); ok { r0 = rf(ctx, traceID) @@ -111,6 +139,10 @@ func (_m *ApiClient) SetTraceID(ctx context.Context, traceID string) context.Con func (_m *ApiClient) TraceID(ctx context.Context) string { ret := _m.Called(ctx) + if len(ret) == 0 { + panic("no return value specified for TraceID") + } + var r0 string if rf, ok := ret.Get(0).(func(context.Context) string); ok { r0 = rf(ctx) @@ -120,3 +152,17 @@ func (_m *ApiClient) TraceID(ctx context.Context) string { return r0 } + +// NewApiClient creates a new instance of ApiClient. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. +// The first argument is typically a *testing.T value. +func NewApiClient(t interface { + mock.TestingT + Cleanup(func()) +}) *ApiClient { + mock := &ApiClient{} + mock.Mock.Test(t) + + t.Cleanup(func() { mock.AssertExpectations(t) }) + + return mock +} diff --git a/mocks/Client.go b/mocks/Client.go index e1bce8f..ed74b63 100644 --- a/mocks/Client.go +++ b/mocks/Client.go @@ -1,20 +1,4 @@ -/* - * - * Copyright © 2021-2023 Dell Inc. or its subsidiaries. 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. - * - */ - -// Code generated by mockery v2.35.3. DO NOT EDIT. +// Code generated by mockery v2.38.0. DO NOT EDIT. package mocks @@ -39,6 +23,10 @@ type Client struct { func (_m *Client) APIClient() api.ApiClient { ret := _m.Called() + if len(ret) == 0 { + panic("no return value specified for APIClient") + } + var r0 api.ApiClient if rf, ok := ret.Get(0).(func() api.ApiClient); ok { r0 = rf() @@ -55,6 +43,10 @@ func (_m *Client) APIClient() api.ApiClient { func (_m *Client) AddMembersToVolumeGroup(ctx context.Context, params *gopowerstore.VolumeGroupMembers, id string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, params, id) + if len(ret) == 0 { + panic("no return value specified for AddMembersToVolumeGroup") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.VolumeGroupMembers, string) (gopowerstore.EmptyResponse, error)); ok { @@ -79,6 +71,10 @@ func (_m *Client) AddMembersToVolumeGroup(ctx context.Context, params *gopowerst func (_m *Client) AttachVolumeToHost(ctx context.Context, hostID string, attachParams *gopowerstore.HostVolumeAttach) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, hostID, attachParams) + if len(ret) == 0 { + panic("no return value specified for AttachVolumeToHost") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, *gopowerstore.HostVolumeAttach) (gopowerstore.EmptyResponse, error)); ok { @@ -103,6 +99,10 @@ func (_m *Client) AttachVolumeToHost(ctx context.Context, hostID string, attachP func (_m *Client) AttachVolumeToHostGroup(ctx context.Context, hostGroupID string, attachParams *gopowerstore.HostVolumeAttach) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, hostGroupID, attachParams) + if len(ret) == 0 { + panic("no return value specified for AttachVolumeToHostGroup") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, *gopowerstore.HostVolumeAttach) (gopowerstore.EmptyResponse, error)); ok { @@ -127,6 +127,10 @@ func (_m *Client) AttachVolumeToHostGroup(ctx context.Context, hostGroupID strin func (_m *Client) CloneFS(ctx context.Context, createParams *gopowerstore.FsClone, fsID string) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, createParams, fsID) + if len(ret) == 0 { + panic("no return value specified for CloneFS") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.FsClone, string) (gopowerstore.CreateResponse, error)); ok { @@ -151,6 +155,10 @@ func (_m *Client) CloneFS(ctx context.Context, createParams *gopowerstore.FsClon func (_m *Client) CloneVolume(ctx context.Context, createParams *gopowerstore.VolumeClone, volID string) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, createParams, volID) + if len(ret) == 0 { + panic("no return value specified for CloneVolume") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.VolumeClone, string) (gopowerstore.CreateResponse, error)); ok { @@ -175,6 +183,10 @@ func (_m *Client) CloneVolume(ctx context.Context, createParams *gopowerstore.Vo func (_m *Client) ComputeDifferences(ctx context.Context, snapdiffParams *gopowerstore.VolumeComputeDifferences, volID string) (gopowerstore.VolumeComputeDifferencesResponse, error) { ret := _m.Called(ctx, snapdiffParams, volID) + if len(ret) == 0 { + panic("no return value specified for ComputeDifferences") + } + var r0 gopowerstore.VolumeComputeDifferencesResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.VolumeComputeDifferences, string) (gopowerstore.VolumeComputeDifferencesResponse, error)); ok { @@ -199,6 +211,10 @@ func (_m *Client) ComputeDifferences(ctx context.Context, snapdiffParams *gopowe func (_m *Client) CopyMetricsByAppliance(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.CopyMetricsByApplianceResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for CopyMetricsByAppliance") + } + var r0 []gopowerstore.CopyMetricsByApplianceResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.CopyMetricsByApplianceResponse, error)); ok { @@ -225,6 +241,10 @@ func (_m *Client) CopyMetricsByAppliance(ctx context.Context, entityID string, i func (_m *Client) CopyMetricsByCluster(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.CopyMetricsByClusterResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for CopyMetricsByCluster") + } + var r0 []gopowerstore.CopyMetricsByClusterResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.CopyMetricsByClusterResponse, error)); ok { @@ -251,6 +271,10 @@ func (_m *Client) CopyMetricsByCluster(ctx context.Context, entityID string, int func (_m *Client) CopyMetricsByRemoteSystem(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.CopyMetricsByRemoteSystemResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for CopyMetricsByRemoteSystem") + } + var r0 []gopowerstore.CopyMetricsByRemoteSystemResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.CopyMetricsByRemoteSystemResponse, error)); ok { @@ -277,6 +301,10 @@ func (_m *Client) CopyMetricsByRemoteSystem(ctx context.Context, entityID string func (_m *Client) CopyMetricsByVolume(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.CopyMetricsByVolumeResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for CopyMetricsByVolume") + } + var r0 []gopowerstore.CopyMetricsByVolumeResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.CopyMetricsByVolumeResponse, error)); ok { @@ -303,6 +331,10 @@ func (_m *Client) CopyMetricsByVolume(ctx context.Context, entityID string, inte func (_m *Client) CopyMetricsByVolumeGroup(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.CopyMetricsByVolumeGroupResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for CopyMetricsByVolumeGroup") + } + var r0 []gopowerstore.CopyMetricsByVolumeGroupResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.CopyMetricsByVolumeGroupResponse, error)); ok { @@ -329,6 +361,10 @@ func (_m *Client) CopyMetricsByVolumeGroup(ctx context.Context, entityID string, func (_m *Client) CreateFS(ctx context.Context, createParams *gopowerstore.FsCreate) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, createParams) + if len(ret) == 0 { + panic("no return value specified for CreateFS") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.FsCreate) (gopowerstore.CreateResponse, error)); ok { @@ -353,6 +389,10 @@ func (_m *Client) CreateFS(ctx context.Context, createParams *gopowerstore.FsCre func (_m *Client) CreateFsFromSnapshot(ctx context.Context, createParams *gopowerstore.FsClone, snapID string) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, createParams, snapID) + if len(ret) == 0 { + panic("no return value specified for CreateFsFromSnapshot") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.FsClone, string) (gopowerstore.CreateResponse, error)); ok { @@ -377,6 +417,10 @@ func (_m *Client) CreateFsFromSnapshot(ctx context.Context, createParams *gopowe func (_m *Client) CreateFsSnapshot(ctx context.Context, createSnapParams *gopowerstore.SnapshotFSCreate, id string) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, createSnapParams, id) + if len(ret) == 0 { + panic("no return value specified for CreateFsSnapshot") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.SnapshotFSCreate, string) (gopowerstore.CreateResponse, error)); ok { @@ -401,6 +445,10 @@ func (_m *Client) CreateFsSnapshot(ctx context.Context, createSnapParams *gopowe func (_m *Client) CreateHost(ctx context.Context, createParams *gopowerstore.HostCreate) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, createParams) + if len(ret) == 0 { + panic("no return value specified for CreateHost") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.HostCreate) (gopowerstore.CreateResponse, error)); ok { @@ -425,6 +473,10 @@ func (_m *Client) CreateHost(ctx context.Context, createParams *gopowerstore.Hos func (_m *Client) CreateHostGroup(ctx context.Context, createParams *gopowerstore.HostGroupCreate) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, createParams) + if len(ret) == 0 { + panic("no return value specified for CreateHostGroup") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.HostGroupCreate) (gopowerstore.CreateResponse, error)); ok { @@ -449,6 +501,10 @@ func (_m *Client) CreateHostGroup(ctx context.Context, createParams *gopowerstor func (_m *Client) CreateNAS(ctx context.Context, createParams *gopowerstore.NASCreate) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, createParams) + if len(ret) == 0 { + panic("no return value specified for CreateNAS") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.NASCreate) (gopowerstore.CreateResponse, error)); ok { @@ -473,6 +529,10 @@ func (_m *Client) CreateNAS(ctx context.Context, createParams *gopowerstore.NASC func (_m *Client) CreateNFSExport(ctx context.Context, createParams *gopowerstore.NFSExportCreate) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, createParams) + if len(ret) == 0 { + panic("no return value specified for CreateNFSExport") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.NFSExportCreate) (gopowerstore.CreateResponse, error)); ok { @@ -497,6 +557,10 @@ func (_m *Client) CreateNFSExport(ctx context.Context, createParams *gopowerstor func (_m *Client) CreateNFSServer(ctx context.Context, createParams *gopowerstore.NFSServerCreate) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, createParams) + if len(ret) == 0 { + panic("no return value specified for CreateNFSServer") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.NFSServerCreate) (gopowerstore.CreateResponse, error)); ok { @@ -521,6 +585,10 @@ func (_m *Client) CreateNFSServer(ctx context.Context, createParams *gopowerstor func (_m *Client) CreateProtectionPolicy(ctx context.Context, createParams *gopowerstore.ProtectionPolicyCreate) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, createParams) + if len(ret) == 0 { + panic("no return value specified for CreateProtectionPolicy") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.ProtectionPolicyCreate) (gopowerstore.CreateResponse, error)); ok { @@ -545,6 +613,10 @@ func (_m *Client) CreateProtectionPolicy(ctx context.Context, createParams *gopo func (_m *Client) CreateReplicationRule(ctx context.Context, createParams *gopowerstore.ReplicationRuleCreate) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, createParams) + if len(ret) == 0 { + panic("no return value specified for CreateReplicationRule") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.ReplicationRuleCreate) (gopowerstore.CreateResponse, error)); ok { @@ -569,6 +641,10 @@ func (_m *Client) CreateReplicationRule(ctx context.Context, createParams *gopow func (_m *Client) CreateSnapshot(ctx context.Context, createSnapParams *gopowerstore.SnapshotCreate, id string) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, createSnapParams, id) + if len(ret) == 0 { + panic("no return value specified for CreateSnapshot") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.SnapshotCreate, string) (gopowerstore.CreateResponse, error)); ok { @@ -593,6 +669,10 @@ func (_m *Client) CreateSnapshot(ctx context.Context, createSnapParams *gopowers func (_m *Client) CreateSnapshotRule(ctx context.Context, createParams *gopowerstore.SnapshotRuleCreate) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, createParams) + if len(ret) == 0 { + panic("no return value specified for CreateSnapshotRule") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.SnapshotRuleCreate) (gopowerstore.CreateResponse, error)); ok { @@ -617,6 +697,10 @@ func (_m *Client) CreateSnapshotRule(ctx context.Context, createParams *gopowers func (_m *Client) CreateStorageContainer(ctx context.Context, createParams *gopowerstore.StorageContainer) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, createParams) + if len(ret) == 0 { + panic("no return value specified for CreateStorageContainer") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.StorageContainer) (gopowerstore.CreateResponse, error)); ok { @@ -641,6 +725,10 @@ func (_m *Client) CreateStorageContainer(ctx context.Context, createParams *gopo func (_m *Client) CreateVolume(ctx context.Context, createParams *gopowerstore.VolumeCreate) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, createParams) + if len(ret) == 0 { + panic("no return value specified for CreateVolume") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.VolumeCreate) (gopowerstore.CreateResponse, error)); ok { @@ -665,6 +753,10 @@ func (_m *Client) CreateVolume(ctx context.Context, createParams *gopowerstore.V func (_m *Client) CreateVolumeFromSnapshot(ctx context.Context, createParams *gopowerstore.VolumeClone, snapID string) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, createParams, snapID) + if len(ret) == 0 { + panic("no return value specified for CreateVolumeFromSnapshot") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.VolumeClone, string) (gopowerstore.CreateResponse, error)); ok { @@ -689,6 +781,10 @@ func (_m *Client) CreateVolumeFromSnapshot(ctx context.Context, createParams *go func (_m *Client) CreateVolumeGroup(ctx context.Context, createParams *gopowerstore.VolumeGroupCreate) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, createParams) + if len(ret) == 0 { + panic("no return value specified for CreateVolumeGroup") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.VolumeGroupCreate) (gopowerstore.CreateResponse, error)); ok { @@ -713,6 +809,10 @@ func (_m *Client) CreateVolumeGroup(ctx context.Context, createParams *gopowerst func (_m *Client) CreateVolumeGroupSnapshot(ctx context.Context, volumeGroupID string, createParams *gopowerstore.VolumeGroupSnapshotCreate) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, volumeGroupID, createParams) + if len(ret) == 0 { + panic("no return value specified for CreateVolumeGroupSnapshot") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, *gopowerstore.VolumeGroupSnapshotCreate) (gopowerstore.CreateResponse, error)); ok { @@ -737,6 +837,10 @@ func (_m *Client) CreateVolumeGroupSnapshot(ctx context.Context, volumeGroupID s func (_m *Client) DeleteFS(ctx context.Context, id string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for DeleteFS") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.EmptyResponse, error)); ok { @@ -761,6 +865,10 @@ func (_m *Client) DeleteFS(ctx context.Context, id string) (gopowerstore.EmptyRe func (_m *Client) DeleteFsSnapshot(ctx context.Context, id string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for DeleteFsSnapshot") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.EmptyResponse, error)); ok { @@ -785,6 +893,10 @@ func (_m *Client) DeleteFsSnapshot(ctx context.Context, id string) (gopowerstore func (_m *Client) DeleteHost(ctx context.Context, deleteParams *gopowerstore.HostDelete, id string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, deleteParams, id) + if len(ret) == 0 { + panic("no return value specified for DeleteHost") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.HostDelete, string) (gopowerstore.EmptyResponse, error)); ok { @@ -809,6 +921,10 @@ func (_m *Client) DeleteHost(ctx context.Context, deleteParams *gopowerstore.Hos func (_m *Client) DeleteHostGroup(ctx context.Context, id string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for DeleteHostGroup") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.EmptyResponse, error)); ok { @@ -833,6 +949,10 @@ func (_m *Client) DeleteHostGroup(ctx context.Context, id string) (gopowerstore. func (_m *Client) DeleteNAS(ctx context.Context, id string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for DeleteNAS") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.EmptyResponse, error)); ok { @@ -857,6 +977,10 @@ func (_m *Client) DeleteNAS(ctx context.Context, id string) (gopowerstore.EmptyR func (_m *Client) DeleteNFSExport(ctx context.Context, id string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for DeleteNFSExport") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.EmptyResponse, error)); ok { @@ -881,6 +1005,10 @@ func (_m *Client) DeleteNFSExport(ctx context.Context, id string) (gopowerstore. func (_m *Client) DeleteProtectionPolicy(ctx context.Context, id string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for DeleteProtectionPolicy") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.EmptyResponse, error)); ok { @@ -905,6 +1033,10 @@ func (_m *Client) DeleteProtectionPolicy(ctx context.Context, id string) (gopowe func (_m *Client) DeleteReplicationRule(ctx context.Context, id string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for DeleteReplicationRule") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.EmptyResponse, error)); ok { @@ -929,6 +1061,10 @@ func (_m *Client) DeleteReplicationRule(ctx context.Context, id string) (gopower func (_m *Client) DeleteSnapshot(ctx context.Context, deleteParams *gopowerstore.VolumeDelete, id string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, deleteParams, id) + if len(ret) == 0 { + panic("no return value specified for DeleteSnapshot") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.VolumeDelete, string) (gopowerstore.EmptyResponse, error)); ok { @@ -953,6 +1089,10 @@ func (_m *Client) DeleteSnapshot(ctx context.Context, deleteParams *gopowerstore func (_m *Client) DeleteSnapshotRule(ctx context.Context, deleteParams *gopowerstore.SnapshotRuleDelete, id string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, deleteParams, id) + if len(ret) == 0 { + panic("no return value specified for DeleteSnapshotRule") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.SnapshotRuleDelete, string) (gopowerstore.EmptyResponse, error)); ok { @@ -977,6 +1117,10 @@ func (_m *Client) DeleteSnapshotRule(ctx context.Context, deleteParams *gopowers func (_m *Client) DeleteStorageContainer(ctx context.Context, id string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for DeleteStorageContainer") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.EmptyResponse, error)); ok { @@ -1001,6 +1145,10 @@ func (_m *Client) DeleteStorageContainer(ctx context.Context, id string) (gopowe func (_m *Client) DeleteVolume(ctx context.Context, deleteParams *gopowerstore.VolumeDelete, id string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, deleteParams, id) + if len(ret) == 0 { + panic("no return value specified for DeleteVolume") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.VolumeDelete, string) (gopowerstore.EmptyResponse, error)); ok { @@ -1025,6 +1173,10 @@ func (_m *Client) DeleteVolume(ctx context.Context, deleteParams *gopowerstore.V func (_m *Client) DeleteVolumeGroup(ctx context.Context, id string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for DeleteVolumeGroup") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.EmptyResponse, error)); ok { @@ -1049,6 +1201,10 @@ func (_m *Client) DeleteVolumeGroup(ctx context.Context, id string) (gopowerstor func (_m *Client) DetachVolumeFromHost(ctx context.Context, hostID string, detachParams *gopowerstore.HostVolumeDetach) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, hostID, detachParams) + if len(ret) == 0 { + panic("no return value specified for DetachVolumeFromHost") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, *gopowerstore.HostVolumeDetach) (gopowerstore.EmptyResponse, error)); ok { @@ -1073,6 +1229,10 @@ func (_m *Client) DetachVolumeFromHost(ctx context.Context, hostID string, detac func (_m *Client) DetachVolumeFromHostGroup(ctx context.Context, hostGroupID string, detachParams *gopowerstore.HostVolumeDetach) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, hostGroupID, detachParams) + if len(ret) == 0 { + panic("no return value specified for DetachVolumeFromHostGroup") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, *gopowerstore.HostVolumeDetach) (gopowerstore.EmptyResponse, error)); ok { @@ -1097,6 +1257,10 @@ func (_m *Client) DetachVolumeFromHostGroup(ctx context.Context, hostGroupID str func (_m *Client) ExecuteActionOnReplicationSession(ctx context.Context, id string, actionType gopowerstore.ActionType, params *gopowerstore.FailoverParams) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, id, actionType, params) + if len(ret) == 0 { + panic("no return value specified for ExecuteActionOnReplicationSession") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.ActionType, *gopowerstore.FailoverParams) (gopowerstore.EmptyResponse, error)); ok { @@ -1121,6 +1285,10 @@ func (_m *Client) ExecuteActionOnReplicationSession(ctx context.Context, id stri func (_m *Client) GetAllRemoteSystems(ctx context.Context) ([]gopowerstore.RemoteSystem, error) { ret := _m.Called(ctx) + if len(ret) == 0 { + panic("no return value specified for GetAllRemoteSystems") + } + var r0 []gopowerstore.RemoteSystem var r1 error if rf, ok := ret.Get(0).(func(context.Context) ([]gopowerstore.RemoteSystem, error)); ok { @@ -1147,6 +1315,10 @@ func (_m *Client) GetAllRemoteSystems(ctx context.Context) ([]gopowerstore.Remot func (_m *Client) GetAppliance(ctx context.Context, id string) (gopowerstore.ApplianceInstance, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for GetAppliance") + } + var r0 gopowerstore.ApplianceInstance var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.ApplianceInstance, error)); ok { @@ -1171,6 +1343,10 @@ func (_m *Client) GetAppliance(ctx context.Context, id string) (gopowerstore.App func (_m *Client) GetApplianceByName(ctx context.Context, name string) (gopowerstore.ApplianceInstance, error) { ret := _m.Called(ctx, name) + if len(ret) == 0 { + panic("no return value specified for GetApplianceByName") + } + var r0 gopowerstore.ApplianceInstance var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.ApplianceInstance, error)); ok { @@ -1195,6 +1371,10 @@ func (_m *Client) GetApplianceByName(ctx context.Context, name string) (gopowers func (_m *Client) GetCapacity(ctx context.Context) (int64, error) { ret := _m.Called(ctx) + if len(ret) == 0 { + panic("no return value specified for GetCapacity") + } + var r0 int64 var r1 error if rf, ok := ret.Get(0).(func(context.Context) (int64, error)); ok { @@ -1219,6 +1399,10 @@ func (_m *Client) GetCapacity(ctx context.Context) (int64, error) { func (_m *Client) GetCluster(ctx context.Context) (gopowerstore.Cluster, error) { ret := _m.Called(ctx) + if len(ret) == 0 { + panic("no return value specified for GetCluster") + } + var r0 gopowerstore.Cluster var r1 error if rf, ok := ret.Get(0).(func(context.Context) (gopowerstore.Cluster, error)); ok { @@ -1243,6 +1427,10 @@ func (_m *Client) GetCluster(ctx context.Context) (gopowerstore.Cluster, error) func (_m *Client) GetCustomHTTPHeaders() http.Header { ret := _m.Called() + if len(ret) == 0 { + panic("no return value specified for GetCustomHTTPHeaders") + } + var r0 http.Header if rf, ok := ret.Get(0).(func() http.Header); ok { r0 = rf() @@ -1259,6 +1447,10 @@ func (_m *Client) GetCustomHTTPHeaders() http.Header { func (_m *Client) GetFCPort(ctx context.Context, id string) (gopowerstore.FcPort, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for GetFCPort") + } + var r0 gopowerstore.FcPort var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.FcPort, error)); ok { @@ -1283,6 +1475,10 @@ func (_m *Client) GetFCPort(ctx context.Context, id string) (gopowerstore.FcPort func (_m *Client) GetFCPorts(ctx context.Context) ([]gopowerstore.FcPort, error) { ret := _m.Called(ctx) + if len(ret) == 0 { + panic("no return value specified for GetFCPorts") + } + var r0 []gopowerstore.FcPort var r1 error if rf, ok := ret.Get(0).(func(context.Context) ([]gopowerstore.FcPort, error)); ok { @@ -1309,6 +1505,10 @@ func (_m *Client) GetFCPorts(ctx context.Context) ([]gopowerstore.FcPort, error) func (_m *Client) GetFS(ctx context.Context, id string) (gopowerstore.FileSystem, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for GetFS") + } + var r0 gopowerstore.FileSystem var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.FileSystem, error)); ok { @@ -1333,6 +1533,10 @@ func (_m *Client) GetFS(ctx context.Context, id string) (gopowerstore.FileSystem func (_m *Client) GetFSByName(ctx context.Context, name string) (gopowerstore.FileSystem, error) { ret := _m.Called(ctx, name) + if len(ret) == 0 { + panic("no return value specified for GetFSByName") + } + var r0 gopowerstore.FileSystem var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.FileSystem, error)); ok { @@ -1357,6 +1561,10 @@ func (_m *Client) GetFSByName(ctx context.Context, name string) (gopowerstore.Fi func (_m *Client) GetFileInterface(ctx context.Context, id string) (gopowerstore.FileInterface, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for GetFileInterface") + } + var r0 gopowerstore.FileInterface var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.FileInterface, error)); ok { @@ -1381,6 +1589,10 @@ func (_m *Client) GetFileInterface(ctx context.Context, id string) (gopowerstore func (_m *Client) GetFsSnapshot(ctx context.Context, snapID string) (gopowerstore.FileSystem, error) { ret := _m.Called(ctx, snapID) + if len(ret) == 0 { + panic("no return value specified for GetFsSnapshot") + } + var r0 gopowerstore.FileSystem var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.FileSystem, error)); ok { @@ -1405,6 +1617,10 @@ func (_m *Client) GetFsSnapshot(ctx context.Context, snapID string) (gopowerstor func (_m *Client) GetFsSnapshots(ctx context.Context) ([]gopowerstore.FileSystem, error) { ret := _m.Called(ctx) + if len(ret) == 0 { + panic("no return value specified for GetFsSnapshots") + } + var r0 []gopowerstore.FileSystem var r1 error if rf, ok := ret.Get(0).(func(context.Context) ([]gopowerstore.FileSystem, error)); ok { @@ -1431,6 +1647,10 @@ func (_m *Client) GetFsSnapshots(ctx context.Context) ([]gopowerstore.FileSystem func (_m *Client) GetFsSnapshotsByVolumeID(ctx context.Context, volID string) ([]gopowerstore.FileSystem, error) { ret := _m.Called(ctx, volID) + if len(ret) == 0 { + panic("no return value specified for GetFsSnapshotsByVolumeID") + } + var r0 []gopowerstore.FileSystem var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) ([]gopowerstore.FileSystem, error)); ok { @@ -1457,6 +1677,10 @@ func (_m *Client) GetFsSnapshotsByVolumeID(ctx context.Context, volID string) ([ func (_m *Client) GetHost(ctx context.Context, id string) (gopowerstore.Host, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for GetHost") + } + var r0 gopowerstore.Host var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.Host, error)); ok { @@ -1481,6 +1705,10 @@ func (_m *Client) GetHost(ctx context.Context, id string) (gopowerstore.Host, er func (_m *Client) GetHostByName(ctx context.Context, name string) (gopowerstore.Host, error) { ret := _m.Called(ctx, name) + if len(ret) == 0 { + panic("no return value specified for GetHostByName") + } + var r0 gopowerstore.Host var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.Host, error)); ok { @@ -1505,6 +1733,10 @@ func (_m *Client) GetHostByName(ctx context.Context, name string) (gopowerstore. func (_m *Client) GetHostGroup(ctx context.Context, id string) (gopowerstore.HostGroup, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for GetHostGroup") + } + var r0 gopowerstore.HostGroup var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.HostGroup, error)); ok { @@ -1529,6 +1761,10 @@ func (_m *Client) GetHostGroup(ctx context.Context, id string) (gopowerstore.Hos func (_m *Client) GetHostGroupByName(ctx context.Context, name string) (gopowerstore.HostGroup, error) { ret := _m.Called(ctx, name) + if len(ret) == 0 { + panic("no return value specified for GetHostGroupByName") + } + var r0 gopowerstore.HostGroup var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.HostGroup, error)); ok { @@ -1553,6 +1789,10 @@ func (_m *Client) GetHostGroupByName(ctx context.Context, name string) (gopowers func (_m *Client) GetHostGroups(ctx context.Context) ([]gopowerstore.HostGroup, error) { ret := _m.Called(ctx) + if len(ret) == 0 { + panic("no return value specified for GetHostGroups") + } + var r0 []gopowerstore.HostGroup var r1 error if rf, ok := ret.Get(0).(func(context.Context) ([]gopowerstore.HostGroup, error)); ok { @@ -1579,6 +1819,10 @@ func (_m *Client) GetHostGroups(ctx context.Context) ([]gopowerstore.HostGroup, func (_m *Client) GetHostVolumeMapping(ctx context.Context, id string) (gopowerstore.HostVolumeMapping, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for GetHostVolumeMapping") + } + var r0 gopowerstore.HostVolumeMapping var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.HostVolumeMapping, error)); ok { @@ -1603,6 +1847,10 @@ func (_m *Client) GetHostVolumeMapping(ctx context.Context, id string) (gopowers func (_m *Client) GetHostVolumeMappingByVolumeID(ctx context.Context, volumeID string) ([]gopowerstore.HostVolumeMapping, error) { ret := _m.Called(ctx, volumeID) + if len(ret) == 0 { + panic("no return value specified for GetHostVolumeMappingByVolumeID") + } + var r0 []gopowerstore.HostVolumeMapping var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) ([]gopowerstore.HostVolumeMapping, error)); ok { @@ -1629,6 +1877,10 @@ func (_m *Client) GetHostVolumeMappingByVolumeID(ctx context.Context, volumeID s func (_m *Client) GetHostVolumeMappings(ctx context.Context) ([]gopowerstore.HostVolumeMapping, error) { ret := _m.Called(ctx) + if len(ret) == 0 { + panic("no return value specified for GetHostVolumeMappings") + } + var r0 []gopowerstore.HostVolumeMapping var r1 error if rf, ok := ret.Get(0).(func(context.Context) ([]gopowerstore.HostVolumeMapping, error)); ok { @@ -1655,6 +1907,10 @@ func (_m *Client) GetHostVolumeMappings(ctx context.Context) ([]gopowerstore.Hos func (_m *Client) GetHosts(ctx context.Context) ([]gopowerstore.Host, error) { ret := _m.Called(ctx) + if len(ret) == 0 { + panic("no return value specified for GetHosts") + } + var r0 []gopowerstore.Host var r1 error if rf, ok := ret.Get(0).(func(context.Context) ([]gopowerstore.Host, error)); ok { @@ -1681,6 +1937,10 @@ func (_m *Client) GetHosts(ctx context.Context) ([]gopowerstore.Host, error) { func (_m *Client) GetMaxVolumeSize(ctx context.Context) (int64, error) { ret := _m.Called(ctx) + if len(ret) == 0 { + panic("no return value specified for GetMaxVolumeSize") + } + var r0 int64 var r1 error if rf, ok := ret.Get(0).(func(context.Context) (int64, error)); ok { @@ -1705,6 +1965,10 @@ func (_m *Client) GetMaxVolumeSize(ctx context.Context) (int64, error) { func (_m *Client) GetNAS(ctx context.Context, id string) (gopowerstore.NAS, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for GetNAS") + } + var r0 gopowerstore.NAS var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.NAS, error)); ok { @@ -1729,6 +1993,10 @@ func (_m *Client) GetNAS(ctx context.Context, id string) (gopowerstore.NAS, erro func (_m *Client) GetNASByName(ctx context.Context, name string) (gopowerstore.NAS, error) { ret := _m.Called(ctx, name) + if len(ret) == 0 { + panic("no return value specified for GetNASByName") + } + var r0 gopowerstore.NAS var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.NAS, error)); ok { @@ -1753,6 +2021,10 @@ func (_m *Client) GetNASByName(ctx context.Context, name string) (gopowerstore.N func (_m *Client) GetNFSExportByFileSystemID(ctx context.Context, fsID string) (gopowerstore.NFSExport, error) { ret := _m.Called(ctx, fsID) + if len(ret) == 0 { + panic("no return value specified for GetNFSExportByFileSystemID") + } + var r0 gopowerstore.NFSExport var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.NFSExport, error)); ok { @@ -1777,6 +2049,10 @@ func (_m *Client) GetNFSExportByFileSystemID(ctx context.Context, fsID string) ( func (_m *Client) GetNFSExportByName(ctx context.Context, name string) (gopowerstore.NFSExport, error) { ret := _m.Called(ctx, name) + if len(ret) == 0 { + panic("no return value specified for GetNFSExportByName") + } + var r0 gopowerstore.NFSExport var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.NFSExport, error)); ok { @@ -1801,6 +2077,10 @@ func (_m *Client) GetNFSExportByName(ctx context.Context, name string) (gopowers func (_m *Client) GetNfsServer(ctx context.Context, id string) (gopowerstore.NFSServerInstance, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for GetNfsServer") + } + var r0 gopowerstore.NFSServerInstance var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.NFSServerInstance, error)); ok { @@ -1825,6 +2105,10 @@ func (_m *Client) GetNfsServer(ctx context.Context, id string) (gopowerstore.NFS func (_m *Client) GetProtectionPolicies(ctx context.Context) ([]gopowerstore.ProtectionPolicy, error) { ret := _m.Called(ctx) + if len(ret) == 0 { + panic("no return value specified for GetProtectionPolicies") + } + var r0 []gopowerstore.ProtectionPolicy var r1 error if rf, ok := ret.Get(0).(func(context.Context) ([]gopowerstore.ProtectionPolicy, error)); ok { @@ -1851,6 +2135,10 @@ func (_m *Client) GetProtectionPolicies(ctx context.Context) ([]gopowerstore.Pro func (_m *Client) GetProtectionPolicy(ctx context.Context, id string) (gopowerstore.ProtectionPolicy, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for GetProtectionPolicy") + } + var r0 gopowerstore.ProtectionPolicy var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.ProtectionPolicy, error)); ok { @@ -1875,6 +2163,10 @@ func (_m *Client) GetProtectionPolicy(ctx context.Context, id string) (gopowerst func (_m *Client) GetProtectionPolicyByName(ctx context.Context, name string) (gopowerstore.ProtectionPolicy, error) { ret := _m.Called(ctx, name) + if len(ret) == 0 { + panic("no return value specified for GetProtectionPolicyByName") + } + var r0 gopowerstore.ProtectionPolicy var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.ProtectionPolicy, error)); ok { @@ -1899,6 +2191,10 @@ func (_m *Client) GetProtectionPolicyByName(ctx context.Context, name string) (g func (_m *Client) GetRemoteSystem(ctx context.Context, id string) (gopowerstore.RemoteSystem, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for GetRemoteSystem") + } + var r0 gopowerstore.RemoteSystem var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.RemoteSystem, error)); ok { @@ -1923,6 +2219,10 @@ func (_m *Client) GetRemoteSystem(ctx context.Context, id string) (gopowerstore. func (_m *Client) GetRemoteSystemByName(ctx context.Context, name string) (gopowerstore.RemoteSystem, error) { ret := _m.Called(ctx, name) + if len(ret) == 0 { + panic("no return value specified for GetRemoteSystemByName") + } + var r0 gopowerstore.RemoteSystem var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.RemoteSystem, error)); ok { @@ -1947,6 +2247,10 @@ func (_m *Client) GetRemoteSystemByName(ctx context.Context, name string) (gopow func (_m *Client) GetReplicationRule(ctx context.Context, id string) (gopowerstore.ReplicationRule, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for GetReplicationRule") + } + var r0 gopowerstore.ReplicationRule var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.ReplicationRule, error)); ok { @@ -1971,6 +2275,10 @@ func (_m *Client) GetReplicationRule(ctx context.Context, id string) (gopowersto func (_m *Client) GetReplicationRuleByName(ctx context.Context, name string) (gopowerstore.ReplicationRule, error) { ret := _m.Called(ctx, name) + if len(ret) == 0 { + panic("no return value specified for GetReplicationRuleByName") + } + var r0 gopowerstore.ReplicationRule var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.ReplicationRule, error)); ok { @@ -1995,6 +2303,10 @@ func (_m *Client) GetReplicationRuleByName(ctx context.Context, name string) (go func (_m *Client) GetReplicationSessionByID(ctx context.Context, id string) (gopowerstore.ReplicationSession, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for GetReplicationSessionByID") + } + var r0 gopowerstore.ReplicationSession var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.ReplicationSession, error)); ok { @@ -2019,6 +2331,10 @@ func (_m *Client) GetReplicationSessionByID(ctx context.Context, id string) (gop func (_m *Client) GetReplicationSessionByLocalResourceID(ctx context.Context, id string) (gopowerstore.ReplicationSession, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for GetReplicationSessionByLocalResourceID") + } + var r0 gopowerstore.ReplicationSession var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.ReplicationSession, error)); ok { @@ -2043,6 +2359,10 @@ func (_m *Client) GetReplicationSessionByLocalResourceID(ctx context.Context, id func (_m *Client) GetSnapshot(ctx context.Context, snapID string) (gopowerstore.Volume, error) { ret := _m.Called(ctx, snapID) + if len(ret) == 0 { + panic("no return value specified for GetSnapshot") + } + var r0 gopowerstore.Volume var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.Volume, error)); ok { @@ -2067,6 +2387,10 @@ func (_m *Client) GetSnapshot(ctx context.Context, snapID string) (gopowerstore. func (_m *Client) GetSnapshotByName(ctx context.Context, snapName string) (gopowerstore.Volume, error) { ret := _m.Called(ctx, snapName) + if len(ret) == 0 { + panic("no return value specified for GetSnapshotByName") + } + var r0 gopowerstore.Volume var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.Volume, error)); ok { @@ -2091,6 +2415,10 @@ func (_m *Client) GetSnapshotByName(ctx context.Context, snapName string) (gopow func (_m *Client) GetSnapshotRule(ctx context.Context, id string) (gopowerstore.SnapshotRule, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for GetSnapshotRule") + } + var r0 gopowerstore.SnapshotRule var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.SnapshotRule, error)); ok { @@ -2115,6 +2443,10 @@ func (_m *Client) GetSnapshotRule(ctx context.Context, id string) (gopowerstore. func (_m *Client) GetSnapshotRuleByName(ctx context.Context, name string) (gopowerstore.SnapshotRule, error) { ret := _m.Called(ctx, name) + if len(ret) == 0 { + panic("no return value specified for GetSnapshotRuleByName") + } + var r0 gopowerstore.SnapshotRule var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.SnapshotRule, error)); ok { @@ -2139,6 +2471,10 @@ func (_m *Client) GetSnapshotRuleByName(ctx context.Context, name string) (gopow func (_m *Client) GetSnapshotRules(ctx context.Context) ([]gopowerstore.SnapshotRule, error) { ret := _m.Called(ctx) + if len(ret) == 0 { + panic("no return value specified for GetSnapshotRules") + } + var r0 []gopowerstore.SnapshotRule var r1 error if rf, ok := ret.Get(0).(func(context.Context) ([]gopowerstore.SnapshotRule, error)); ok { @@ -2165,6 +2501,10 @@ func (_m *Client) GetSnapshotRules(ctx context.Context) ([]gopowerstore.Snapshot func (_m *Client) GetSnapshots(ctx context.Context) ([]gopowerstore.Volume, error) { ret := _m.Called(ctx) + if len(ret) == 0 { + panic("no return value specified for GetSnapshots") + } + var r0 []gopowerstore.Volume var r1 error if rf, ok := ret.Get(0).(func(context.Context) ([]gopowerstore.Volume, error)); ok { @@ -2191,6 +2531,10 @@ func (_m *Client) GetSnapshots(ctx context.Context) ([]gopowerstore.Volume, erro func (_m *Client) GetSnapshotsByVolumeID(ctx context.Context, volID string) ([]gopowerstore.Volume, error) { ret := _m.Called(ctx, volID) + if len(ret) == 0 { + panic("no return value specified for GetSnapshotsByVolumeID") + } + var r0 []gopowerstore.Volume var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) ([]gopowerstore.Volume, error)); ok { @@ -2217,6 +2561,10 @@ func (_m *Client) GetSnapshotsByVolumeID(ctx context.Context, volID string) ([]g func (_m *Client) GetSoftwareInstalled(ctx context.Context) ([]gopowerstore.SoftwareInstalled, error) { ret := _m.Called(ctx) + if len(ret) == 0 { + panic("no return value specified for GetSoftwareInstalled") + } + var r0 []gopowerstore.SoftwareInstalled var r1 error if rf, ok := ret.Get(0).(func(context.Context) ([]gopowerstore.SoftwareInstalled, error)); ok { @@ -2243,6 +2591,10 @@ func (_m *Client) GetSoftwareInstalled(ctx context.Context) ([]gopowerstore.Soft func (_m *Client) GetSoftwareMajorMinorVersion(ctx context.Context) (float32, error) { ret := _m.Called(ctx) + if len(ret) == 0 { + panic("no return value specified for GetSoftwareMajorMinorVersion") + } + var r0 float32 var r1 error if rf, ok := ret.Get(0).(func(context.Context) (float32, error)); ok { @@ -2267,6 +2619,10 @@ func (_m *Client) GetSoftwareMajorMinorVersion(ctx context.Context) (float32, er func (_m *Client) GetStorageContainer(ctx context.Context, id string) (gopowerstore.StorageContainer, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for GetStorageContainer") + } + var r0 gopowerstore.StorageContainer var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.StorageContainer, error)); ok { @@ -2291,6 +2647,10 @@ func (_m *Client) GetStorageContainer(ctx context.Context, id string) (gopowerst func (_m *Client) GetStorageISCSITargetAddresses(ctx context.Context) ([]gopowerstore.IPPoolAddress, error) { ret := _m.Called(ctx) + if len(ret) == 0 { + panic("no return value specified for GetStorageISCSITargetAddresses") + } + var r0 []gopowerstore.IPPoolAddress var r1 error if rf, ok := ret.Get(0).(func(context.Context) ([]gopowerstore.IPPoolAddress, error)); ok { @@ -2317,6 +2677,10 @@ func (_m *Client) GetStorageISCSITargetAddresses(ctx context.Context) ([]gopower func (_m *Client) GetVolume(ctx context.Context, id string) (gopowerstore.Volume, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for GetVolume") + } + var r0 gopowerstore.Volume var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.Volume, error)); ok { @@ -2341,6 +2705,10 @@ func (_m *Client) GetVolume(ctx context.Context, id string) (gopowerstore.Volume func (_m *Client) GetVolumeByName(ctx context.Context, name string) (gopowerstore.Volume, error) { ret := _m.Called(ctx, name) + if len(ret) == 0 { + panic("no return value specified for GetVolumeByName") + } + var r0 gopowerstore.Volume var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.Volume, error)); ok { @@ -2365,6 +2733,10 @@ func (_m *Client) GetVolumeByName(ctx context.Context, name string) (gopowerstor func (_m *Client) GetVolumeGroup(ctx context.Context, id string) (gopowerstore.VolumeGroup, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for GetVolumeGroup") + } + var r0 gopowerstore.VolumeGroup var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.VolumeGroup, error)); ok { @@ -2389,6 +2761,10 @@ func (_m *Client) GetVolumeGroup(ctx context.Context, id string) (gopowerstore.V func (_m *Client) GetVolumeGroupByName(ctx context.Context, name string) (gopowerstore.VolumeGroup, error) { ret := _m.Called(ctx, name) + if len(ret) == 0 { + panic("no return value specified for GetVolumeGroupByName") + } + var r0 gopowerstore.VolumeGroup var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.VolumeGroup, error)); ok { @@ -2413,6 +2789,10 @@ func (_m *Client) GetVolumeGroupByName(ctx context.Context, name string) (gopowe func (_m *Client) GetVolumeGroupSnapshot(ctx context.Context, snapID string) (gopowerstore.VolumeGroup, error) { ret := _m.Called(ctx, snapID) + if len(ret) == 0 { + panic("no return value specified for GetVolumeGroupSnapshot") + } + var r0 gopowerstore.VolumeGroup var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.VolumeGroup, error)); ok { @@ -2437,6 +2817,10 @@ func (_m *Client) GetVolumeGroupSnapshot(ctx context.Context, snapID string) (go func (_m *Client) GetVolumeGroupSnapshotByName(ctx context.Context, snapName string) (gopowerstore.VolumeGroup, error) { ret := _m.Called(ctx, snapName) + if len(ret) == 0 { + panic("no return value specified for GetVolumeGroupSnapshotByName") + } + var r0 gopowerstore.VolumeGroup var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.VolumeGroup, error)); ok { @@ -2461,6 +2845,10 @@ func (_m *Client) GetVolumeGroupSnapshotByName(ctx context.Context, snapName str func (_m *Client) GetVolumeGroupSnapshots(ctx context.Context) ([]gopowerstore.VolumeGroup, error) { ret := _m.Called(ctx) + if len(ret) == 0 { + panic("no return value specified for GetVolumeGroupSnapshots") + } + var r0 []gopowerstore.VolumeGroup var r1 error if rf, ok := ret.Get(0).(func(context.Context) ([]gopowerstore.VolumeGroup, error)); ok { @@ -2487,6 +2875,10 @@ func (_m *Client) GetVolumeGroupSnapshots(ctx context.Context) ([]gopowerstore.V func (_m *Client) GetVolumeGroups(ctx context.Context) ([]gopowerstore.VolumeGroup, error) { ret := _m.Called(ctx) + if len(ret) == 0 { + panic("no return value specified for GetVolumeGroups") + } + var r0 []gopowerstore.VolumeGroup var r1 error if rf, ok := ret.Get(0).(func(context.Context) ([]gopowerstore.VolumeGroup, error)); ok { @@ -2513,6 +2905,10 @@ func (_m *Client) GetVolumeGroups(ctx context.Context) ([]gopowerstore.VolumeGro func (_m *Client) GetVolumeGroupsByVolumeID(ctx context.Context, id string) (gopowerstore.VolumeGroups, error) { ret := _m.Called(ctx, id) + if len(ret) == 0 { + panic("no return value specified for GetVolumeGroupsByVolumeID") + } + var r0 gopowerstore.VolumeGroups var r1 error if rf, ok := ret.Get(0).(func(context.Context, string) (gopowerstore.VolumeGroups, error)); ok { @@ -2537,6 +2933,10 @@ func (_m *Client) GetVolumeGroupsByVolumeID(ctx context.Context, id string) (gop func (_m *Client) GetVolumes(ctx context.Context) ([]gopowerstore.Volume, error) { ret := _m.Called(ctx) + if len(ret) == 0 { + panic("no return value specified for GetVolumes") + } + var r0 []gopowerstore.Volume var r1 error if rf, ok := ret.Get(0).(func(context.Context) ([]gopowerstore.Volume, error)); ok { @@ -2563,6 +2963,10 @@ func (_m *Client) GetVolumes(ctx context.Context) ([]gopowerstore.Volume, error) func (_m *Client) ModifyFS(ctx context.Context, modifyParams *gopowerstore.FSModify, volID string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, modifyParams, volID) + if len(ret) == 0 { + panic("no return value specified for ModifyFS") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.FSModify, string) (gopowerstore.EmptyResponse, error)); ok { @@ -2587,6 +2991,10 @@ func (_m *Client) ModifyFS(ctx context.Context, modifyParams *gopowerstore.FSMod func (_m *Client) ModifyHost(ctx context.Context, modifyParams *gopowerstore.HostModify, id string) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, modifyParams, id) + if len(ret) == 0 { + panic("no return value specified for ModifyHost") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.HostModify, string) (gopowerstore.CreateResponse, error)); ok { @@ -2611,6 +3019,10 @@ func (_m *Client) ModifyHost(ctx context.Context, modifyParams *gopowerstore.Hos func (_m *Client) ModifyHostGroup(ctx context.Context, modifyParams *gopowerstore.HostGroupModify, id string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, modifyParams, id) + if len(ret) == 0 { + panic("no return value specified for ModifyHostGroup") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.HostGroupModify, string) (gopowerstore.EmptyResponse, error)); ok { @@ -2635,6 +3047,10 @@ func (_m *Client) ModifyHostGroup(ctx context.Context, modifyParams *gopowerstor func (_m *Client) ModifyNFSExport(ctx context.Context, modifyParams *gopowerstore.NFSExportModify, id string) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, modifyParams, id) + if len(ret) == 0 { + panic("no return value specified for ModifyNFSExport") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.NFSExportModify, string) (gopowerstore.CreateResponse, error)); ok { @@ -2659,6 +3075,10 @@ func (_m *Client) ModifyNFSExport(ctx context.Context, modifyParams *gopowerstor func (_m *Client) ModifyProtectionPolicy(ctx context.Context, modifyParams *gopowerstore.ProtectionPolicyCreate, id string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, modifyParams, id) + if len(ret) == 0 { + panic("no return value specified for ModifyProtectionPolicy") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.ProtectionPolicyCreate, string) (gopowerstore.EmptyResponse, error)); ok { @@ -2683,6 +3103,10 @@ func (_m *Client) ModifyProtectionPolicy(ctx context.Context, modifyParams *gopo func (_m *Client) ModifySnapshotRule(ctx context.Context, modifyParams *gopowerstore.SnapshotRuleCreate, id string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, modifyParams, id) + if len(ret) == 0 { + panic("no return value specified for ModifySnapshotRule") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.SnapshotRuleCreate, string) (gopowerstore.EmptyResponse, error)); ok { @@ -2707,6 +3131,10 @@ func (_m *Client) ModifySnapshotRule(ctx context.Context, modifyParams *gopowers func (_m *Client) ModifyStorageContainer(ctx context.Context, modifyParams *gopowerstore.StorageContainer, id string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, modifyParams, id) + if len(ret) == 0 { + panic("no return value specified for ModifyStorageContainer") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.StorageContainer, string) (gopowerstore.EmptyResponse, error)); ok { @@ -2731,6 +3159,10 @@ func (_m *Client) ModifyStorageContainer(ctx context.Context, modifyParams *gopo func (_m *Client) ModifyVolume(ctx context.Context, modifyParams *gopowerstore.VolumeModify, volID string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, modifyParams, volID) + if len(ret) == 0 { + panic("no return value specified for ModifyVolume") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.VolumeModify, string) (gopowerstore.EmptyResponse, error)); ok { @@ -2755,6 +3187,10 @@ func (_m *Client) ModifyVolume(ctx context.Context, modifyParams *gopowerstore.V func (_m *Client) ModifyVolumeGroup(ctx context.Context, modifyParams *gopowerstore.VolumeGroupModify, id string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, modifyParams, id) + if len(ret) == 0 { + panic("no return value specified for ModifyVolumeGroup") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.VolumeGroupModify, string) (gopowerstore.EmptyResponse, error)); ok { @@ -2779,6 +3215,10 @@ func (_m *Client) ModifyVolumeGroup(ctx context.Context, modifyParams *gopowerst func (_m *Client) PerformanceMetricsByAppliance(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByApplianceResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for PerformanceMetricsByAppliance") + } + var r0 []gopowerstore.PerformanceMetricsByApplianceResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByApplianceResponse, error)); ok { @@ -2805,6 +3245,10 @@ func (_m *Client) PerformanceMetricsByAppliance(ctx context.Context, entityID st func (_m *Client) PerformanceMetricsByCluster(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByClusterResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for PerformanceMetricsByCluster") + } + var r0 []gopowerstore.PerformanceMetricsByClusterResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByClusterResponse, error)); ok { @@ -2831,6 +3275,10 @@ func (_m *Client) PerformanceMetricsByCluster(ctx context.Context, entityID stri func (_m *Client) PerformanceMetricsByFeEthNode(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByFeEthNodeResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for PerformanceMetricsByFeEthNode") + } + var r0 []gopowerstore.PerformanceMetricsByFeEthNodeResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByFeEthNodeResponse, error)); ok { @@ -2857,6 +3305,10 @@ func (_m *Client) PerformanceMetricsByFeEthNode(ctx context.Context, entityID st func (_m *Client) PerformanceMetricsByFeEthPort(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByFeEthPortResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for PerformanceMetricsByFeEthPort") + } + var r0 []gopowerstore.PerformanceMetricsByFeEthPortResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByFeEthPortResponse, error)); ok { @@ -2883,6 +3335,10 @@ func (_m *Client) PerformanceMetricsByFeEthPort(ctx context.Context, entityID st func (_m *Client) PerformanceMetricsByFeFcNode(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByFeFcNodeResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for PerformanceMetricsByFeFcNode") + } + var r0 []gopowerstore.PerformanceMetricsByFeFcNodeResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByFeFcNodeResponse, error)); ok { @@ -2909,6 +3365,10 @@ func (_m *Client) PerformanceMetricsByFeFcNode(ctx context.Context, entityID str func (_m *Client) PerformanceMetricsByFeFcPort(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByFeFcPortResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for PerformanceMetricsByFeFcPort") + } + var r0 []gopowerstore.PerformanceMetricsByFeFcPortResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByFeFcPortResponse, error)); ok { @@ -2935,6 +3395,10 @@ func (_m *Client) PerformanceMetricsByFeFcPort(ctx context.Context, entityID str func (_m *Client) PerformanceMetricsByFileSystem(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByFileSystemResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for PerformanceMetricsByFileSystem") + } + var r0 []gopowerstore.PerformanceMetricsByFileSystemResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByFileSystemResponse, error)); ok { @@ -2961,6 +3425,10 @@ func (_m *Client) PerformanceMetricsByFileSystem(ctx context.Context, entityID s func (_m *Client) PerformanceMetricsByNode(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByNodeResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for PerformanceMetricsByNode") + } + var r0 []gopowerstore.PerformanceMetricsByNodeResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByNodeResponse, error)); ok { @@ -2987,6 +3455,10 @@ func (_m *Client) PerformanceMetricsByNode(ctx context.Context, entityID string, func (_m *Client) PerformanceMetricsByVM(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByVMResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for PerformanceMetricsByVM") + } + var r0 []gopowerstore.PerformanceMetricsByVMResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByVMResponse, error)); ok { @@ -3013,6 +3485,10 @@ func (_m *Client) PerformanceMetricsByVM(ctx context.Context, entityID string, i func (_m *Client) PerformanceMetricsByVg(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByVgResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for PerformanceMetricsByVg") + } + var r0 []gopowerstore.PerformanceMetricsByVgResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByVgResponse, error)); ok { @@ -3039,6 +3515,10 @@ func (_m *Client) PerformanceMetricsByVg(ctx context.Context, entityID string, i func (_m *Client) PerformanceMetricsByVolume(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByVolumeResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for PerformanceMetricsByVolume") + } + var r0 []gopowerstore.PerformanceMetricsByVolumeResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByVolumeResponse, error)); ok { @@ -3065,6 +3545,10 @@ func (_m *Client) PerformanceMetricsByVolume(ctx context.Context, entityID strin func (_m *Client) PerformanceMetricsNfsByNode(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByNfsResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for PerformanceMetricsNfsByNode") + } + var r0 []gopowerstore.PerformanceMetricsByNfsResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByNfsResponse, error)); ok { @@ -3091,6 +3575,10 @@ func (_m *Client) PerformanceMetricsNfsByNode(ctx context.Context, entityID stri func (_m *Client) PerformanceMetricsNfsv3ByNode(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByNfsv3Response, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for PerformanceMetricsNfsv3ByNode") + } + var r0 []gopowerstore.PerformanceMetricsByNfsv3Response var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByNfsv3Response, error)); ok { @@ -3117,6 +3605,10 @@ func (_m *Client) PerformanceMetricsNfsv3ByNode(ctx context.Context, entityID st func (_m *Client) PerformanceMetricsNfsv4ByNode(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByNfsv4Response, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for PerformanceMetricsNfsv4ByNode") + } + var r0 []gopowerstore.PerformanceMetricsByNfsv4Response var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsByNfsv4Response, error)); ok { @@ -3143,6 +3635,10 @@ func (_m *Client) PerformanceMetricsNfsv4ByNode(ctx context.Context, entityID st func (_m *Client) PerformanceMetricsSmb1BuiltinclientByNode(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsBySmbV1BuiltinClientResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for PerformanceMetricsSmb1BuiltinclientByNode") + } + var r0 []gopowerstore.PerformanceMetricsBySmbV1BuiltinClientResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsBySmbV1BuiltinClientResponse, error)); ok { @@ -3169,6 +3665,10 @@ func (_m *Client) PerformanceMetricsSmb1BuiltinclientByNode(ctx context.Context, func (_m *Client) PerformanceMetricsSmb1ByNode(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsBySmbV1NodeResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for PerformanceMetricsSmb1ByNode") + } + var r0 []gopowerstore.PerformanceMetricsBySmbV1NodeResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsBySmbV1NodeResponse, error)); ok { @@ -3195,6 +3695,10 @@ func (_m *Client) PerformanceMetricsSmb1ByNode(ctx context.Context, entityID str func (_m *Client) PerformanceMetricsSmb2BuiltinclientByNode(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsBySmbV2BuiltinClientResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for PerformanceMetricsSmb2BuiltinclientByNode") + } + var r0 []gopowerstore.PerformanceMetricsBySmbV2BuiltinClientResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsBySmbV2BuiltinClientResponse, error)); ok { @@ -3221,6 +3725,10 @@ func (_m *Client) PerformanceMetricsSmb2BuiltinclientByNode(ctx context.Context, func (_m *Client) PerformanceMetricsSmb2ByNode(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsBySmbV2NodeResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for PerformanceMetricsSmb2ByNode") + } + var r0 []gopowerstore.PerformanceMetricsBySmbV2NodeResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsBySmbV2NodeResponse, error)); ok { @@ -3247,6 +3755,10 @@ func (_m *Client) PerformanceMetricsSmb2ByNode(ctx context.Context, entityID str func (_m *Client) PerformanceMetricsSmbBranchCacheByNode(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsBySmbCacheResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for PerformanceMetricsSmbBranchCacheByNode") + } + var r0 []gopowerstore.PerformanceMetricsBySmbCacheResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsBySmbCacheResponse, error)); ok { @@ -3273,6 +3785,10 @@ func (_m *Client) PerformanceMetricsSmbBranchCacheByNode(ctx context.Context, en func (_m *Client) PerformanceMetricsSmbBuiltinclientByNode(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsBySmbClientResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for PerformanceMetricsSmbBuiltinclientByNode") + } + var r0 []gopowerstore.PerformanceMetricsBySmbClientResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsBySmbClientResponse, error)); ok { @@ -3299,6 +3815,10 @@ func (_m *Client) PerformanceMetricsSmbBuiltinclientByNode(ctx context.Context, func (_m *Client) PerformanceMetricsSmbByNode(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsBySmbNodeResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for PerformanceMetricsSmbByNode") + } + var r0 []gopowerstore.PerformanceMetricsBySmbNodeResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.PerformanceMetricsBySmbNodeResponse, error)); ok { @@ -3325,6 +3845,10 @@ func (_m *Client) PerformanceMetricsSmbByNode(ctx context.Context, entityID stri func (_m *Client) RegisterK8sCluster(ctx context.Context, request *gopowerstore.K8sCluster) (gopowerstore.CreateResponse, error) { ret := _m.Called(ctx, request) + if len(ret) == 0 { + panic("no return value specified for RegisterK8sCluster") + } + var r0 gopowerstore.CreateResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.K8sCluster) (gopowerstore.CreateResponse, error)); ok { @@ -3349,6 +3873,10 @@ func (_m *Client) RegisterK8sCluster(ctx context.Context, request *gopowerstore. func (_m *Client) RemoveMembersFromVolumeGroup(ctx context.Context, params *gopowerstore.VolumeGroupMembers, id string) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, params, id) + if len(ret) == 0 { + panic("no return value specified for RemoveMembersFromVolumeGroup") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, *gopowerstore.VolumeGroupMembers, string) (gopowerstore.EmptyResponse, error)); ok { @@ -3383,6 +3911,10 @@ func (_m *Client) SetLogger(logger gopowerstore.Logger) { func (_m *Client) SetTraceID(ctx context.Context, value string) context.Context { ret := _m.Called(ctx, value) + if len(ret) == 0 { + panic("no return value specified for SetTraceID") + } + var r0 context.Context if rf, ok := ret.Get(0).(func(context.Context, string) context.Context); ok { r0 = rf(ctx, value) @@ -3399,6 +3931,10 @@ func (_m *Client) SetTraceID(ctx context.Context, value string) context.Context func (_m *Client) SpaceMetricsByAppliance(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.SpaceMetricsByApplianceResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for SpaceMetricsByAppliance") + } + var r0 []gopowerstore.SpaceMetricsByApplianceResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.SpaceMetricsByApplianceResponse, error)); ok { @@ -3425,6 +3961,10 @@ func (_m *Client) SpaceMetricsByAppliance(ctx context.Context, entityID string, func (_m *Client) SpaceMetricsByCluster(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.SpaceMetricsByClusterResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for SpaceMetricsByCluster") + } + var r0 []gopowerstore.SpaceMetricsByClusterResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.SpaceMetricsByClusterResponse, error)); ok { @@ -3451,6 +3991,10 @@ func (_m *Client) SpaceMetricsByCluster(ctx context.Context, entityID string, in func (_m *Client) SpaceMetricsByStorageContainer(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.SpaceMetricsByStorageContainerResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for SpaceMetricsByStorageContainer") + } + var r0 []gopowerstore.SpaceMetricsByStorageContainerResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.SpaceMetricsByStorageContainerResponse, error)); ok { @@ -3477,6 +4021,10 @@ func (_m *Client) SpaceMetricsByStorageContainer(ctx context.Context, entityID s func (_m *Client) SpaceMetricsByVM(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.SpaceMetricsByVMResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for SpaceMetricsByVM") + } + var r0 []gopowerstore.SpaceMetricsByVMResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.SpaceMetricsByVMResponse, error)); ok { @@ -3503,6 +4051,10 @@ func (_m *Client) SpaceMetricsByVM(ctx context.Context, entityID string, interva func (_m *Client) SpaceMetricsByVolume(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.SpaceMetricsByVolumeResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for SpaceMetricsByVolume") + } + var r0 []gopowerstore.SpaceMetricsByVolumeResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.SpaceMetricsByVolumeResponse, error)); ok { @@ -3529,6 +4081,10 @@ func (_m *Client) SpaceMetricsByVolume(ctx context.Context, entityID string, int func (_m *Client) SpaceMetricsByVolumeFamily(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.SpaceMetricsByVolumeFamilyResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for SpaceMetricsByVolumeFamily") + } + var r0 []gopowerstore.SpaceMetricsByVolumeFamilyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.SpaceMetricsByVolumeFamilyResponse, error)); ok { @@ -3555,6 +4111,10 @@ func (_m *Client) SpaceMetricsByVolumeFamily(ctx context.Context, entityID strin func (_m *Client) SpaceMetricsByVolumeGroup(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.SpaceMetricsByVolumeGroupResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for SpaceMetricsByVolumeGroup") + } + var r0 []gopowerstore.SpaceMetricsByVolumeGroupResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.SpaceMetricsByVolumeGroupResponse, error)); ok { @@ -3581,6 +4141,10 @@ func (_m *Client) SpaceMetricsByVolumeGroup(ctx context.Context, entityID string func (_m *Client) UpdateVolumeGroupProtectionPolicy(ctx context.Context, id string, params *gopowerstore.VolumeGroupChangePolicy) (gopowerstore.EmptyResponse, error) { ret := _m.Called(ctx, id, params) + if len(ret) == 0 { + panic("no return value specified for UpdateVolumeGroupProtectionPolicy") + } + var r0 gopowerstore.EmptyResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, *gopowerstore.VolumeGroupChangePolicy) (gopowerstore.EmptyResponse, error)); ok { @@ -3605,6 +4169,10 @@ func (_m *Client) UpdateVolumeGroupProtectionPolicy(ctx context.Context, id stri func (_m *Client) WearMetricsByDrive(ctx context.Context, entityID string, interval gopowerstore.MetricsIntervalEnum) ([]gopowerstore.WearMetricsByDriveResponse, error) { ret := _m.Called(ctx, entityID, interval) + if len(ret) == 0 { + panic("no return value specified for WearMetricsByDrive") + } + var r0 []gopowerstore.WearMetricsByDriveResponse var r1 error if rf, ok := ret.Get(0).(func(context.Context, string, gopowerstore.MetricsIntervalEnum) ([]gopowerstore.WearMetricsByDriveResponse, error)); ok { diff --git a/mocks/FieldProvider.go b/mocks/FieldProvider.go index 794b940..fd33d64 100644 --- a/mocks/FieldProvider.go +++ b/mocks/FieldProvider.go @@ -1,20 +1,4 @@ -/* - * - * Copyright © 2021-2022 Dell Inc. or its subsidiaries. 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. - * - */ - -// Code generated by mockery v1.0.0. DO NOT EDIT. +// Code generated by mockery v2.38.0. DO NOT EDIT. package mocks @@ -29,6 +13,10 @@ type FieldProvider struct { func (_m *FieldProvider) Fields() []string { ret := _m.Called() + if len(ret) == 0 { + panic("no return value specified for Fields") + } + var r0 []string if rf, ok := ret.Get(0).(func() []string); ok { r0 = rf() @@ -40,3 +28,17 @@ func (_m *FieldProvider) Fields() []string { return r0 } + +// NewFieldProvider creates a new instance of FieldProvider. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. +// The first argument is typically a *testing.T value. +func NewFieldProvider(t interface { + mock.TestingT + Cleanup(func()) +}) *FieldProvider { + mock := &FieldProvider{} + mock.Mock.Test(t) + + t.Cleanup(func() { mock.AssertExpectations(t) }) + + return mock +} diff --git a/mocks/Logger.go b/mocks/Logger.go index 147f576..85284ac 100644 --- a/mocks/Logger.go +++ b/mocks/Logger.go @@ -1,25 +1,12 @@ -/* - * - * Copyright © 2021-2022 Dell Inc. or its subsidiaries. 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. - * - */ - -// Code generated by mockery v1.0.0. DO NOT EDIT. +// Code generated by mockery v2.38.0. DO NOT EDIT. package mocks -import context "context" -import mock "github.com/stretchr/testify/mock" +import ( + context "context" + + mock "github.com/stretchr/testify/mock" +) // Logger is an autogenerated mock type for the Logger type type Logger struct { @@ -49,3 +36,17 @@ func (_m *Logger) Info(ctx context.Context, format string, args ...interface{}) _ca = append(_ca, args...) _m.Called(_ca...) } + +// NewLogger creates a new instance of Logger. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. +// The first argument is typically a *testing.T value. +func NewLogger(t interface { + mock.TestingT + Cleanup(func()) +}) *Logger { + mock := &Logger{} + mock.Mock.Test(t) + + t.Cleanup(func() { mock.AssertExpectations(t) }) + + return mock +} diff --git a/mocks/QueryParamsEncoder.go b/mocks/QueryParamsEncoder.go index 35de881..42eb28b 100644 --- a/mocks/QueryParamsEncoder.go +++ b/mocks/QueryParamsEncoder.go @@ -1,25 +1,11 @@ -/* - * - * Copyright © 2021-2022 Dell Inc. or its subsidiaries. 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. - * - */ - -// Code generated by mockery v1.0.0. DO NOT EDIT. +// Code generated by mockery v2.38.0. DO NOT EDIT. package mocks -import api "github.com/dell/gopowerstore/api" -import mock "github.com/stretchr/testify/mock" +import ( + api "github.com/dell/gopowerstore/api" + mock "github.com/stretchr/testify/mock" +) // QueryParamsEncoder is an autogenerated mock type for the QueryParamsEncoder type type QueryParamsEncoder struct { @@ -30,6 +16,10 @@ type QueryParamsEncoder struct { func (_m *QueryParamsEncoder) Async(_a0 bool) api.QueryParamsEncoder { ret := _m.Called(_a0) + if len(ret) == 0 { + panic("no return value specified for Async") + } + var r0 api.QueryParamsEncoder if rf, ok := ret.Get(0).(func(bool) api.QueryParamsEncoder); ok { r0 = rf(_a0) @@ -46,6 +36,10 @@ func (_m *QueryParamsEncoder) Async(_a0 bool) api.QueryParamsEncoder { func (_m *QueryParamsEncoder) Encode() string { ret := _m.Called() + if len(ret) == 0 { + panic("no return value specified for Encode") + } + var r0 string if rf, ok := ret.Get(0).(func() string); ok { r0 = rf() @@ -60,6 +54,10 @@ func (_m *QueryParamsEncoder) Encode() string { func (_m *QueryParamsEncoder) Limit(_a0 int) api.QueryParamsEncoder { ret := _m.Called(_a0) + if len(ret) == 0 { + panic("no return value specified for Limit") + } + var r0 api.QueryParamsEncoder if rf, ok := ret.Get(0).(func(int) api.QueryParamsEncoder); ok { r0 = rf(_a0) @@ -76,6 +74,10 @@ func (_m *QueryParamsEncoder) Limit(_a0 int) api.QueryParamsEncoder { func (_m *QueryParamsEncoder) Offset(_a0 int) api.QueryParamsEncoder { ret := _m.Called(_a0) + if len(ret) == 0 { + panic("no return value specified for Offset") + } + var r0 api.QueryParamsEncoder if rf, ok := ret.Get(0).(func(int) api.QueryParamsEncoder); ok { r0 = rf(_a0) @@ -98,6 +100,10 @@ func (_m *QueryParamsEncoder) Order(_a0 ...string) api.QueryParamsEncoder { _ca = append(_ca, _va...) ret := _m.Called(_ca...) + if len(ret) == 0 { + panic("no return value specified for Order") + } + var r0 api.QueryParamsEncoder if rf, ok := ret.Get(0).(func(...string) api.QueryParamsEncoder); ok { r0 = rf(_a0...) @@ -114,6 +120,10 @@ func (_m *QueryParamsEncoder) Order(_a0 ...string) api.QueryParamsEncoder { func (_m *QueryParamsEncoder) RawArg(_a0 string, _a1 string) api.QueryParamsEncoder { ret := _m.Called(_a0, _a1) + if len(ret) == 0 { + panic("no return value specified for RawArg") + } + var r0 api.QueryParamsEncoder if rf, ok := ret.Get(0).(func(string, string) api.QueryParamsEncoder); ok { r0 = rf(_a0, _a1) @@ -136,6 +146,10 @@ func (_m *QueryParamsEncoder) Select(_a0 ...string) api.QueryParamsEncoder { _ca = append(_ca, _va...) ret := _m.Called(_ca...) + if len(ret) == 0 { + panic("no return value specified for Select") + } + var r0 api.QueryParamsEncoder if rf, ok := ret.Get(0).(func(...string) api.QueryParamsEncoder); ok { r0 = rf(_a0...) @@ -147,3 +161,17 @@ func (_m *QueryParamsEncoder) Select(_a0 ...string) api.QueryParamsEncoder { return r0 } + +// NewQueryParamsEncoder creates a new instance of QueryParamsEncoder. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. +// The first argument is typically a *testing.T value. +func NewQueryParamsEncoder(t interface { + mock.TestingT + Cleanup(func()) +}) *QueryParamsEncoder { + mock := &QueryParamsEncoder{} + mock.Mock.Test(t) + + t.Cleanup(func() { mock.AssertExpectations(t) }) + + return mock +} diff --git a/mocks/RequestConfigRenderer.go b/mocks/RequestConfigRenderer.go index 322417e..2cd792e 100644 --- a/mocks/RequestConfigRenderer.go +++ b/mocks/RequestConfigRenderer.go @@ -1,25 +1,11 @@ -/* - * - * Copyright © 2021-2022 Dell Inc. or its subsidiaries. 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. - * - */ - -// Code generated by mockery v1.0.0. DO NOT EDIT. +// Code generated by mockery v2.38.0. DO NOT EDIT. package mocks -import api "github.com/dell/gopowerstore/api" -import mock "github.com/stretchr/testify/mock" +import ( + api "github.com/dell/gopowerstore/api" + mock "github.com/stretchr/testify/mock" +) // RequestConfigRenderer is an autogenerated mock type for the RequestConfigRenderer type type RequestConfigRenderer struct { @@ -30,6 +16,10 @@ type RequestConfigRenderer struct { func (_m *RequestConfigRenderer) RenderRequestConfig() api.RequestConfig { ret := _m.Called() + if len(ret) == 0 { + panic("no return value specified for RenderRequestConfig") + } + var r0 api.RequestConfig if rf, ok := ret.Get(0).(func() api.RequestConfig); ok { r0 = rf() @@ -39,3 +29,17 @@ func (_m *RequestConfigRenderer) RenderRequestConfig() api.RequestConfig { return r0 } + +// NewRequestConfigRenderer creates a new instance of RequestConfigRenderer. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. +// The first argument is typically a *testing.T value. +func NewRequestConfigRenderer(t interface { + mock.TestingT + Cleanup(func()) +}) *RequestConfigRenderer { + mock := &RequestConfigRenderer{} + mock.Mock.Test(t) + + t.Cleanup(func() { mock.AssertExpectations(t) }) + + return mock +} diff --git a/mocks/TimeoutSemaphoreInterface.go b/mocks/TimeoutSemaphoreInterface.go index 1f56966..9682d6e 100644 --- a/mocks/TimeoutSemaphoreInterface.go +++ b/mocks/TimeoutSemaphoreInterface.go @@ -1,26 +1,14 @@ -/* - * - * Copyright © 2021-2022 Dell Inc. or its subsidiaries. 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. - * - */ - -// Code generated by mockery v1.0.0. DO NOT EDIT. +// Code generated by mockery v2.38.0. DO NOT EDIT. package mocks -import api "github.com/dell/gopowerstore/api" -import context "context" -import mock "github.com/stretchr/testify/mock" +import ( + context "context" + + api "github.com/dell/gopowerstore/api" + + mock "github.com/stretchr/testify/mock" +) // TimeoutSemaphoreInterface is an autogenerated mock type for the TimeoutSemaphoreInterface type type TimeoutSemaphoreInterface struct { @@ -31,6 +19,10 @@ type TimeoutSemaphoreInterface struct { func (_m *TimeoutSemaphoreInterface) Acquire(ctx context.Context) error { ret := _m.Called(ctx) + if len(ret) == 0 { + panic("no return value specified for Acquire") + } + var r0 error if rf, ok := ret.Get(0).(func(context.Context) error); ok { r0 = rf(ctx) @@ -50,6 +42,10 @@ func (_m *TimeoutSemaphoreInterface) Release(ctx context.Context) { func (_m *TimeoutSemaphoreInterface) SetLogger(logger api.Logger) api.TimeoutSemaphoreInterface { ret := _m.Called(logger) + if len(ret) == 0 { + panic("no return value specified for SetLogger") + } + var r0 api.TimeoutSemaphoreInterface if rf, ok := ret.Get(0).(func(api.Logger) api.TimeoutSemaphoreInterface); ok { r0 = rf(logger) @@ -61,3 +57,17 @@ func (_m *TimeoutSemaphoreInterface) SetLogger(logger api.Logger) api.TimeoutSem return r0 } + +// NewTimeoutSemaphoreInterface creates a new instance of TimeoutSemaphoreInterface. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. +// The first argument is typically a *testing.T value. +func NewTimeoutSemaphoreInterface(t interface { + mock.TestingT + Cleanup(func()) +}) *TimeoutSemaphoreInterface { + mock := &TimeoutSemaphoreInterface{} + mock.Mock.Test(t) + + t.Cleanup(func() { mock.AssertExpectations(t) }) + + return mock +} diff --git a/mocks/Traceable.go b/mocks/Traceable.go index d6d901d..54dfe3d 100644 --- a/mocks/Traceable.go +++ b/mocks/Traceable.go @@ -1,25 +1,12 @@ -/* - * - * Copyright © 2021-2022 Dell Inc. or its subsidiaries. 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. - * - */ - -// Code generated by mockery v1.0.0. DO NOT EDIT. +// Code generated by mockery v2.38.0. DO NOT EDIT. package mocks -import context "context" -import mock "github.com/stretchr/testify/mock" +import ( + context "context" + + mock "github.com/stretchr/testify/mock" +) // Traceable is an autogenerated mock type for the Traceable type type Traceable struct { @@ -30,6 +17,10 @@ type Traceable struct { func (_m *Traceable) SetTraceID(ctx context.Context, traceID string) context.Context { ret := _m.Called(ctx, traceID) + if len(ret) == 0 { + panic("no return value specified for SetTraceID") + } + var r0 context.Context if rf, ok := ret.Get(0).(func(context.Context, string) context.Context); ok { r0 = rf(ctx, traceID) @@ -46,6 +37,10 @@ func (_m *Traceable) SetTraceID(ctx context.Context, traceID string) context.Con func (_m *Traceable) TraceID(ctx context.Context) string { ret := _m.Called(ctx) + if len(ret) == 0 { + panic("no return value specified for TraceID") + } + var r0 string if rf, ok := ret.Get(0).(func(context.Context) string); ok { r0 = rf(ctx) @@ -55,3 +50,17 @@ func (_m *Traceable) TraceID(ctx context.Context) string { return r0 } + +// NewTraceable creates a new instance of Traceable. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. +// The first argument is typically a *testing.T value. +func NewTraceable(t interface { + mock.TestingT + Cleanup(func()) +}) *Traceable { + mock := &Traceable{} + mock.Mock.Test(t) + + t.Cleanup(func() { mock.AssertExpectations(t) }) + + return mock +}