Documentation ¶
Index ¶
- type MockDBConnector
- type MockDBConnector_Connect_Call
- type MockDBConnector_Expecter
- type MockExecutorCloser
- type MockExecutorCloser_Close_Call
- type MockExecutorCloser_Exec_Call
- func (_c *MockExecutorCloser_Exec_Call) Return(rows models.RowSet, affectedRows int, err error) *MockExecutorCloser_Exec_Call
- func (_c *MockExecutorCloser_Exec_Call) Run(run func(ctx context.Context, query models.Query)) *MockExecutorCloser_Exec_Call
- func (_c *MockExecutorCloser_Exec_Call) RunAndReturn(run func(context.Context, models.Query) (models.RowSet, int, error)) *MockExecutorCloser_Exec_Call
- type MockExecutorCloser_Expecter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MockDBConnector ¶
MockDBConnector is an autogenerated mock type for the DBConnector type
func NewMockDBConnector ¶
func NewMockDBConnector(t interface { mock.TestingT Cleanup(func()) }) *MockDBConnector
NewMockDBConnector creates a new instance of MockDBConnector. 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 (*MockDBConnector) Connect ¶
func (_m *MockDBConnector) Connect(ctx context.Context, addr dbconnector.Addr, credentials models.Credentials) (dbconnector.ExecutorCloser, error)
Connect provides a mock function with given fields: ctx, addr, credentials
func (*MockDBConnector) EXPECT ¶
func (_m *MockDBConnector) EXPECT() *MockDBConnector_Expecter
type MockDBConnector_Connect_Call ¶
MockDBConnector_Connect_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Connect'
func (*MockDBConnector_Connect_Call) Return ¶
func (_c *MockDBConnector_Connect_Call) Return(conn dbconnector.ExecutorCloser, err error) *MockDBConnector_Connect_Call
func (*MockDBConnector_Connect_Call) Run ¶
func (_c *MockDBConnector_Connect_Call) Run(run func(ctx context.Context, addr dbconnector.Addr, credentials models.Credentials)) *MockDBConnector_Connect_Call
func (*MockDBConnector_Connect_Call) RunAndReturn ¶
func (_c *MockDBConnector_Connect_Call) RunAndReturn(run func(context.Context, dbconnector.Addr, models.Credentials) (dbconnector.ExecutorCloser, error)) *MockDBConnector_Connect_Call
type MockDBConnector_Expecter ¶
type MockDBConnector_Expecter struct {
// contains filtered or unexported fields
}
func (*MockDBConnector_Expecter) Connect ¶
func (_e *MockDBConnector_Expecter) Connect(ctx interface{}, addr interface{}, credentials interface{}) *MockDBConnector_Connect_Call
Connect is a helper method to define mock.On call
- ctx context.Context
- addr dbconnector.Addr
- credentials models.Credentials
type MockExecutorCloser ¶
MockExecutorCloser is an autogenerated mock type for the ExecutorCloser type
func NewMockExecutorCloser ¶
func NewMockExecutorCloser(t interface { mock.TestingT Cleanup(func()) }) *MockExecutorCloser
NewMockExecutorCloser creates a new instance of MockExecutorCloser. 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 (*MockExecutorCloser) Close ¶
func (_m *MockExecutorCloser) Close() error
Close provides a mock function with given fields:
func (*MockExecutorCloser) EXPECT ¶
func (_m *MockExecutorCloser) EXPECT() *MockExecutorCloser_Expecter
type MockExecutorCloser_Close_Call ¶
MockExecutorCloser_Close_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Close'
func (*MockExecutorCloser_Close_Call) Return ¶
func (_c *MockExecutorCloser_Close_Call) Return(_a0 error) *MockExecutorCloser_Close_Call
func (*MockExecutorCloser_Close_Call) Run ¶
func (_c *MockExecutorCloser_Close_Call) Run(run func()) *MockExecutorCloser_Close_Call
func (*MockExecutorCloser_Close_Call) RunAndReturn ¶
func (_c *MockExecutorCloser_Close_Call) RunAndReturn(run func() error) *MockExecutorCloser_Close_Call
type MockExecutorCloser_Exec_Call ¶
MockExecutorCloser_Exec_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Exec'
func (*MockExecutorCloser_Exec_Call) Return ¶
func (_c *MockExecutorCloser_Exec_Call) Return(rows models.RowSet, affectedRows int, err error) *MockExecutorCloser_Exec_Call
func (*MockExecutorCloser_Exec_Call) Run ¶
func (_c *MockExecutorCloser_Exec_Call) Run(run func(ctx context.Context, query models.Query)) *MockExecutorCloser_Exec_Call
func (*MockExecutorCloser_Exec_Call) RunAndReturn ¶
func (_c *MockExecutorCloser_Exec_Call) RunAndReturn(run func(context.Context, models.Query) (models.RowSet, int, error)) *MockExecutorCloser_Exec_Call
type MockExecutorCloser_Expecter ¶
type MockExecutorCloser_Expecter struct {
// contains filtered or unexported fields
}
func (*MockExecutorCloser_Expecter) Close ¶
func (_e *MockExecutorCloser_Expecter) Close() *MockExecutorCloser_Close_Call
Close is a helper method to define mock.On call
func (*MockExecutorCloser_Expecter) Exec ¶
func (_e *MockExecutorCloser_Expecter) Exec(ctx interface{}, query interface{}) *MockExecutorCloser_Exec_Call
Exec is a helper method to define mock.On call
- ctx context.Context
- query models.Query