Documentation
¶
Overview ¶
Code generated by MockGen. DO NOT EDIT. Source: pkg/perf/iperf/exec_wrapper.go
Generated by this command:
mockgen -source=pkg/perf/iperf/exec_wrapper.go -destination=pkg/perf/iperf/mock_exec_wrapper.go -package=iperf
Package execwrapper is a generated GoMock package.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ExecWrapper ¶
type ExecWrapper interface { LookPath(file string) (string, error) CommandContext(ctx context.Context, name string, arg ...string) ExecCmd }
ExecWrapper wraps the exec package functions to allow for mocking
type MockExecCmd ¶
type MockExecCmd struct {
// contains filtered or unexported fields
}
MockExecCmd is a mock of ExecCmd interface.
func NewMockExecCmd ¶
func NewMockExecCmd(ctrl *gomock.Controller) *MockExecCmd
NewMockExecCmd creates a new mock instance.
func (*MockExecCmd) CombinedOutput ¶
func (m *MockExecCmd) CombinedOutput() ([]byte, error)
CombinedOutput mocks base method.
func (*MockExecCmd) EXPECT ¶
func (m *MockExecCmd) EXPECT() *MockExecCmdMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
type MockExecCmdMockRecorder ¶
type MockExecCmdMockRecorder struct {
// contains filtered or unexported fields
}
MockExecCmdMockRecorder is the mock recorder for MockExecCmd.
func (*MockExecCmdMockRecorder) CombinedOutput ¶
func (mr *MockExecCmdMockRecorder) CombinedOutput() *gomock.Call
CombinedOutput indicates an expected call of CombinedOutput.
type MockExecWrapper ¶
type MockExecWrapper struct {
// contains filtered or unexported fields
}
MockExecWrapper is a mock of ExecWrapper interface.
func NewMockExecWrapper ¶
func NewMockExecWrapper(ctrl *gomock.Controller) *MockExecWrapper
NewMockExecWrapper creates a new mock instance.
func (*MockExecWrapper) CommandContext ¶
CommandContext mocks base method.
func (*MockExecWrapper) EXPECT ¶
func (m *MockExecWrapper) EXPECT() *MockExecWrapperMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
type MockExecWrapperMockRecorder ¶
type MockExecWrapperMockRecorder struct {
// contains filtered or unexported fields
}
MockExecWrapperMockRecorder is the mock recorder for MockExecWrapper.
func (*MockExecWrapperMockRecorder) CommandContext ¶
func (mr *MockExecWrapperMockRecorder) CommandContext(ctx, name any, arg ...any) *gomock.Call
CommandContext indicates an expected call of CommandContext.
type RealExecCmd ¶
type RealExecCmd struct {
// contains filtered or unexported fields
}
RealExecCmd wraps exec.Cmd to implement ExecCmd interface
func (*RealExecCmd) CombinedOutput ¶
func (r *RealExecCmd) CombinedOutput() ([]byte, error)
CombinedOutput runs the command and returns its combined standard output and standard error
type RealExecWrapper ¶
type RealExecWrapper struct{}
RealExecWrapper implements ExecWrapper using the real exec package
func (*RealExecWrapper) CommandContext ¶
CommandContext returns the Cmd struct to execute the named program with the given arguments