github.com/google/syzkaller@v0.0.0-20240517125934-c0f1611a36d6/vm/proxyapp/mocks/subProcessCmd.go (about) 1 // Code generated by mockery v2.40.3. DO NOT EDIT. 2 3 package mocks 4 5 import ( 6 io "io" 7 8 mock "github.com/stretchr/testify/mock" 9 ) 10 11 // SubProcessCmd is an autogenerated mock type for the subProcessCmd type 12 type SubProcessCmd struct { 13 mock.Mock 14 } 15 16 // Start provides a mock function with given fields: 17 func (_m *SubProcessCmd) Start() error { 18 ret := _m.Called() 19 20 if len(ret) == 0 { 21 panic("no return value specified for Start") 22 } 23 24 var r0 error 25 if rf, ok := ret.Get(0).(func() error); ok { 26 r0 = rf() 27 } else { 28 r0 = ret.Error(0) 29 } 30 31 return r0 32 } 33 34 // StderrPipe provides a mock function with given fields: 35 func (_m *SubProcessCmd) StderrPipe() (io.ReadCloser, error) { 36 ret := _m.Called() 37 38 if len(ret) == 0 { 39 panic("no return value specified for StderrPipe") 40 } 41 42 var r0 io.ReadCloser 43 var r1 error 44 if rf, ok := ret.Get(0).(func() (io.ReadCloser, error)); ok { 45 return rf() 46 } 47 if rf, ok := ret.Get(0).(func() io.ReadCloser); ok { 48 r0 = rf() 49 } else { 50 if ret.Get(0) != nil { 51 r0 = ret.Get(0).(io.ReadCloser) 52 } 53 } 54 55 if rf, ok := ret.Get(1).(func() error); ok { 56 r1 = rf() 57 } else { 58 r1 = ret.Error(1) 59 } 60 61 return r0, r1 62 } 63 64 // StdinPipe provides a mock function with given fields: 65 func (_m *SubProcessCmd) StdinPipe() (io.WriteCloser, error) { 66 ret := _m.Called() 67 68 if len(ret) == 0 { 69 panic("no return value specified for StdinPipe") 70 } 71 72 var r0 io.WriteCloser 73 var r1 error 74 if rf, ok := ret.Get(0).(func() (io.WriteCloser, error)); ok { 75 return rf() 76 } 77 if rf, ok := ret.Get(0).(func() io.WriteCloser); ok { 78 r0 = rf() 79 } else { 80 if ret.Get(0) != nil { 81 r0 = ret.Get(0).(io.WriteCloser) 82 } 83 } 84 85 if rf, ok := ret.Get(1).(func() error); ok { 86 r1 = rf() 87 } else { 88 r1 = ret.Error(1) 89 } 90 91 return r0, r1 92 } 93 94 // StdoutPipe provides a mock function with given fields: 95 func (_m *SubProcessCmd) StdoutPipe() (io.ReadCloser, error) { 96 ret := _m.Called() 97 98 if len(ret) == 0 { 99 panic("no return value specified for StdoutPipe") 100 } 101 102 var r0 io.ReadCloser 103 var r1 error 104 if rf, ok := ret.Get(0).(func() (io.ReadCloser, error)); ok { 105 return rf() 106 } 107 if rf, ok := ret.Get(0).(func() io.ReadCloser); ok { 108 r0 = rf() 109 } else { 110 if ret.Get(0) != nil { 111 r0 = ret.Get(0).(io.ReadCloser) 112 } 113 } 114 115 if rf, ok := ret.Get(1).(func() error); ok { 116 r1 = rf() 117 } else { 118 r1 = ret.Error(1) 119 } 120 121 return r0, r1 122 } 123 124 // Wait provides a mock function with given fields: 125 func (_m *SubProcessCmd) Wait() error { 126 ret := _m.Called() 127 128 if len(ret) == 0 { 129 panic("no return value specified for Wait") 130 } 131 132 var r0 error 133 if rf, ok := ret.Get(0).(func() error); ok { 134 r0 = rf() 135 } else { 136 r0 = ret.Error(0) 137 } 138 139 return r0 140 } 141 142 // NewSubProcessCmd creates a new instance of SubProcessCmd. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. 143 // The first argument is typically a *testing.T value. 144 func NewSubProcessCmd(t interface { 145 mock.TestingT 146 Cleanup(func()) 147 }) *SubProcessCmd { 148 mock := &SubProcessCmd{} 149 mock.Mock.Test(t) 150 151 t.Cleanup(func() { mock.AssertExpectations(t) }) 152 153 return mock 154 }