github.com/m3db/m3@v1.5.1-0.20231129193456-75a402aa583b/src/dbnode/digest/digest_mock.go (about) 1 // Code generated by MockGen. DO NOT EDIT. 2 // Source: github.com/m3db/m3/src/dbnode/digest (interfaces: ReaderWithDigest) 3 4 // Copyright (c) 2021 Uber Technologies, Inc. 5 // 6 // Permission is hereby granted, free of charge, to any person obtaining a copy 7 // of this software and associated documentation files (the "Software"), to deal 8 // in the Software without restriction, including without limitation the rights 9 // to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 10 // copies of the Software, and to permit persons to whom the Software is 11 // furnished to do so, subject to the following conditions: 12 // 13 // The above copyright notice and this permission notice shall be included in 14 // all copies or substantial portions of the Software. 15 // 16 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 17 // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 18 // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 19 // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 20 // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 21 // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 22 // THE SOFTWARE. 23 24 // Package digest is a generated GoMock package. 25 package digest 26 27 import ( 28 "hash" 29 "io" 30 "reflect" 31 32 "github.com/golang/mock/gomock" 33 ) 34 35 // MockReaderWithDigest is a mock of ReaderWithDigest interface. 36 type MockReaderWithDigest struct { 37 ctrl *gomock.Controller 38 recorder *MockReaderWithDigestMockRecorder 39 } 40 41 // MockReaderWithDigestMockRecorder is the mock recorder for MockReaderWithDigest. 42 type MockReaderWithDigestMockRecorder struct { 43 mock *MockReaderWithDigest 44 } 45 46 // NewMockReaderWithDigest creates a new mock instance. 47 func NewMockReaderWithDigest(ctrl *gomock.Controller) *MockReaderWithDigest { 48 mock := &MockReaderWithDigest{ctrl: ctrl} 49 mock.recorder = &MockReaderWithDigestMockRecorder{mock} 50 return mock 51 } 52 53 // EXPECT returns an object that allows the caller to indicate expected use. 54 func (m *MockReaderWithDigest) EXPECT() *MockReaderWithDigestMockRecorder { 55 return m.recorder 56 } 57 58 // Digest mocks base method. 59 func (m *MockReaderWithDigest) Digest() hash.Hash32 { 60 m.ctrl.T.Helper() 61 ret := m.ctrl.Call(m, "Digest") 62 ret0, _ := ret[0].(hash.Hash32) 63 return ret0 64 } 65 66 // Digest indicates an expected call of Digest. 67 func (mr *MockReaderWithDigestMockRecorder) Digest() *gomock.Call { 68 mr.mock.ctrl.T.Helper() 69 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Digest", reflect.TypeOf((*MockReaderWithDigest)(nil).Digest)) 70 } 71 72 // Read mocks base method. 73 func (m *MockReaderWithDigest) Read(arg0 []byte) (int, error) { 74 m.ctrl.T.Helper() 75 ret := m.ctrl.Call(m, "Read", arg0) 76 ret0, _ := ret[0].(int) 77 ret1, _ := ret[1].(error) 78 return ret0, ret1 79 } 80 81 // Read indicates an expected call of Read. 82 func (mr *MockReaderWithDigestMockRecorder) Read(arg0 interface{}) *gomock.Call { 83 mr.mock.ctrl.T.Helper() 84 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Read", reflect.TypeOf((*MockReaderWithDigest)(nil).Read), arg0) 85 } 86 87 // Reset mocks base method. 88 func (m *MockReaderWithDigest) Reset(arg0 io.Reader) { 89 m.ctrl.T.Helper() 90 m.ctrl.Call(m, "Reset", arg0) 91 } 92 93 // Reset indicates an expected call of Reset. 94 func (mr *MockReaderWithDigestMockRecorder) Reset(arg0 interface{}) *gomock.Call { 95 mr.mock.ctrl.T.Helper() 96 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Reset", reflect.TypeOf((*MockReaderWithDigest)(nil).Reset), arg0) 97 } 98 99 // Validate mocks base method. 100 func (m *MockReaderWithDigest) Validate(arg0 uint32) error { 101 m.ctrl.T.Helper() 102 ret := m.ctrl.Call(m, "Validate", arg0) 103 ret0, _ := ret[0].(error) 104 return ret0 105 } 106 107 // Validate indicates an expected call of Validate. 108 func (mr *MockReaderWithDigestMockRecorder) Validate(arg0 interface{}) *gomock.Call { 109 mr.mock.ctrl.T.Helper() 110 return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Validate", reflect.TypeOf((*MockReaderWithDigest)(nil).Validate), arg0) 111 }