• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

kubernetes-sigs / azuredisk-csi-driver / 13898551038

17 Mar 2025 11:41AM UTC coverage: 75.633% (-0.5%) from 76.139%
13898551038

push

github

web-flow
Merge pull request #2941 from andyzhangx/reduce-get-disk-call

fix: reduce get disk calls in disk attach/detach on VMSS

6 of 6 new or added lines in 2 files covered. (100.0%)

28 existing lines in 1 file now uncovered.

3734 of 4937 relevant lines covered (75.63%)

6.82 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/pkg/optimization/mockoptimization/interface.go
1
/*
2
Copyright The Kubernetes Authors.
3

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

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

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

17
// Code generated by MockGen. DO NOT EDIT.
18
// Source: pkg/optimization/device_perf.go
19

20
// Package mockoptimization is a generated GoMock package.
21
package mockoptimization
22

23
import (
24
        reflect "reflect"
25

26
        gomock "go.uber.org/mock/gomock"
27
        optimization "sigs.k8s.io/azuredisk-csi-driver/pkg/optimization"
28
)
29

30
// MockInterface is a mock of Interface interface.
31
type MockInterface struct {
32
        ctrl     *gomock.Controller
33
        recorder *MockInterfaceMockRecorder
34
}
35

36
// MockInterfaceMockRecorder is the mock recorder for MockInterface.
37
type MockInterfaceMockRecorder struct {
38
        mock *MockInterface
39
}
40

41
// NewMockInterface creates a new mock instance.
UNCOV
42
func NewMockInterface(ctrl *gomock.Controller) *MockInterface {
×
UNCOV
43
        mock := &MockInterface{ctrl: ctrl}
×
UNCOV
44
        mock.recorder = &MockInterfaceMockRecorder{mock}
×
UNCOV
45
        return mock
×
UNCOV
46
}
×
47

48
// EXPECT returns an object that allows the caller to indicate expected use.
UNCOV
49
func (m *MockInterface) EXPECT() *MockInterfaceMockRecorder {
×
UNCOV
50
        return m.recorder
×
UNCOV
51
}
×
52

53
// DiskSupportsPerfOptimization mocks base method.
UNCOV
54
func (m *MockInterface) DiskSupportsPerfOptimization(diskPerfProfile, diskAccountType string) bool {
×
UNCOV
55
        m.ctrl.T.Helper()
×
UNCOV
56
        ret := m.ctrl.Call(m, "DiskSupportsPerfOptimization", diskPerfProfile, diskAccountType)
×
UNCOV
57
        ret0, _ := ret[0].(bool)
×
UNCOV
58
        return ret0
×
UNCOV
59
}
×
60

61
// DiskSupportsPerfOptimization indicates an expected call of DiskSupportsPerfOptimization.
UNCOV
62
func (mr *MockInterfaceMockRecorder) DiskSupportsPerfOptimization(diskPerfProfile, diskAccountType interface{}) *gomock.Call {
×
UNCOV
63
        mr.mock.ctrl.T.Helper()
×
UNCOV
64
        return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "DiskSupportsPerfOptimization", reflect.TypeOf((*MockInterface)(nil).DiskSupportsPerfOptimization), diskPerfProfile, diskAccountType)
×
UNCOV
65
}
×
66

67
// OptimizeDiskPerformance mocks base method.
UNCOV
68
func (m *MockInterface) OptimizeDiskPerformance(nodeInfo *optimization.NodeInfo, devicePath, perfProfile, accountType, diskSizeGibStr, diskIopsStr, diskBwMbpsStr string, deviceSettingsFromCtx map[string]string) error {
×
UNCOV
69
        m.ctrl.T.Helper()
×
UNCOV
70
        ret := m.ctrl.Call(m, "OptimizeDiskPerformance", nodeInfo, devicePath, perfProfile, accountType, diskSizeGibStr, diskIopsStr, diskBwMbpsStr, deviceSettingsFromCtx)
×
UNCOV
71
        ret0, _ := ret[0].(error)
×
UNCOV
72
        return ret0
×
UNCOV
73
}
×
74

75
// OptimizeDiskPerformance indicates an expected call of OptimizeDiskPerformance.
UNCOV
76
func (mr *MockInterfaceMockRecorder) OptimizeDiskPerformance(nodeInfo, devicePath, perfProfile, accountType, diskSizeGibStr, diskIopsStr, diskBwMbpsStr, deviceSettingsFromCtx interface{}) *gomock.Call {
×
UNCOV
77
        mr.mock.ctrl.T.Helper()
×
UNCOV
78
        return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "OptimizeDiskPerformance", reflect.TypeOf((*MockInterface)(nil).OptimizeDiskPerformance), nodeInfo, devicePath, perfProfile, accountType, diskSizeGibStr, diskIopsStr, diskBwMbpsStr, deviceSettingsFromCtx)
×
UNCOV
79
}
×
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc