Documentation
¶
Overview ¶
Package dbmock is a generated GoMock package.
Package dbmock is a generated GoMock package.
Index ¶
- type MockBeginner
- type MockBeginnerMockRecorder
- type MockCollectableRows
- type MockCollectableRowsMockRecorder
- type MockConnection
- func (m *MockConnection) Begin(ctx context.Context, opts *database.TransactionOptions) (database.Transaction, error)
- func (m *MockConnection) EXPECT() *MockConnectionMockRecorder
- func (m *MockConnection) Exec(ctx context.Context, stmt string, args ...any) (int64, error)
- func (m *MockConnection) Migrate(ctx context.Context) error
- func (m *MockConnection) Ping(ctx context.Context) error
- func (m *MockConnection) Query(ctx context.Context, stmt string, args ...any) (database.Rows, error)
- func (m *MockConnection) QueryRow(ctx context.Context, stmt string, args ...any) database.Row
- func (m *MockConnection) Release(ctx context.Context) error
- type MockConnectionMockRecorder
- func (mr *MockConnectionMockRecorder) Begin(ctx, opts any) *gomock.Call
- func (mr *MockConnectionMockRecorder) Exec(ctx, stmt any, args ...any) *gomock.Call
- func (mr *MockConnectionMockRecorder) Migrate(ctx any) *gomock.Call
- func (mr *MockConnectionMockRecorder) Ping(ctx any) *gomock.Call
- func (mr *MockConnectionMockRecorder) Query(ctx, stmt any, args ...any) *gomock.Call
- func (mr *MockConnectionMockRecorder) QueryRow(ctx, stmt any, args ...any) *gomock.Call
- func (mr *MockConnectionMockRecorder) Release(ctx any) *gomock.Call
- type MockExecutor
- type MockExecutorMockRecorder
- type MockPool
- func (m *MockPool) Acquire(ctx context.Context) (database.Connection, error)
- func (m *MockPool) Begin(ctx context.Context, opts *database.TransactionOptions) (database.Transaction, error)
- func (m *MockPool) Close(ctx context.Context) error
- func (m *MockPool) EXPECT() *MockPoolMockRecorder
- func (m *MockPool) Exec(ctx context.Context, stmt string, args ...any) (int64, error)
- func (m *MockPool) Migrate(ctx context.Context) error
- func (m *MockPool) Ping(ctx context.Context) error
- func (m *MockPool) Query(ctx context.Context, stmt string, args ...any) (database.Rows, error)
- func (m *MockPool) QueryRow(ctx context.Context, stmt string, args ...any) database.Row
- type MockPoolMockRecorder
- func (mr *MockPoolMockRecorder) Acquire(ctx any) *gomock.Call
- func (mr *MockPoolMockRecorder) Begin(ctx, opts any) *gomock.Call
- func (mr *MockPoolMockRecorder) Close(ctx any) *gomock.Call
- func (mr *MockPoolMockRecorder) Exec(ctx, stmt any, args ...any) *gomock.Call
- func (mr *MockPoolMockRecorder) Migrate(ctx any) *gomock.Call
- func (mr *MockPoolMockRecorder) Ping(ctx any) *gomock.Call
- func (mr *MockPoolMockRecorder) Query(ctx, stmt any, args ...any) *gomock.Call
- func (mr *MockPoolMockRecorder) QueryRow(ctx, stmt any, args ...any) *gomock.Call
- type MockPoolTest
- func (m *MockPoolTest) Acquire(ctx context.Context) (database.Connection, error)
- func (m *MockPoolTest) Begin(ctx context.Context, opts *database.TransactionOptions) (database.Transaction, error)
- func (m *MockPoolTest) Close(ctx context.Context) error
- func (m *MockPoolTest) EXPECT() *MockPoolTestMockRecorder
- func (m *MockPoolTest) Exec(ctx context.Context, stmt string, args ...any) (int64, error)
- func (m *MockPoolTest) Migrate(ctx context.Context) error
- func (m *MockPoolTest) MigrateTest(ctx context.Context) error
- func (m *MockPoolTest) Ping(ctx context.Context) error
- func (m *MockPoolTest) Query(ctx context.Context, stmt string, args ...any) (database.Rows, error)
- func (m *MockPoolTest) QueryRow(ctx context.Context, stmt string, args ...any) database.Row
- func (m *MockPoolTest) RawDB() *sql.DB
- type MockPoolTestMockRecorder
- func (mr *MockPoolTestMockRecorder) Acquire(ctx any) *gomock.Call
- func (mr *MockPoolTestMockRecorder) Begin(ctx, opts any) *gomock.Call
- func (mr *MockPoolTestMockRecorder) Close(ctx any) *gomock.Call
- func (mr *MockPoolTestMockRecorder) Exec(ctx, stmt any, args ...any) *gomock.Call
- func (mr *MockPoolTestMockRecorder) Migrate(ctx any) *gomock.Call
- func (mr *MockPoolTestMockRecorder) MigrateTest(ctx any) *gomock.Call
- func (mr *MockPoolTestMockRecorder) Ping(ctx any) *gomock.Call
- func (mr *MockPoolTestMockRecorder) Query(ctx, stmt any, args ...any) *gomock.Call
- func (mr *MockPoolTestMockRecorder) QueryRow(ctx, stmt any, args ...any) *gomock.Call
- func (mr *MockPoolTestMockRecorder) RawDB() *gomock.Call
- type MockQuerier
- type MockQuerierMockRecorder
- type MockQueryExecutor
- func (m *MockQueryExecutor) EXPECT() *MockQueryExecutorMockRecorder
- func (m *MockQueryExecutor) Exec(ctx context.Context, stmt string, args ...any) (int64, error)
- func (m *MockQueryExecutor) Query(ctx context.Context, stmt string, args ...any) (database.Rows, error)
- func (m *MockQueryExecutor) QueryRow(ctx context.Context, stmt string, args ...any) database.Row
- type MockQueryExecutorMockRecorder
- type MockRow
- type MockRowMockRecorder
- type MockRows
- type MockRowsMockRecorder
- type MockScanner
- type MockScannerMockRecorder
- type MockTransaction
- func (m *MockTransaction) Begin(ctx context.Context, opts *database.TransactionOptions) (database.Transaction, error)
- func (m *MockTransaction) Commit(ctx context.Context) error
- func (m *MockTransaction) EXPECT() *MockTransactionMockRecorder
- func (m *MockTransaction) End(ctx context.Context, err error) error
- func (m *MockTransaction) Exec(ctx context.Context, stmt string, args ...any) (int64, error)
- func (m *MockTransaction) Query(ctx context.Context, stmt string, args ...any) (database.Rows, error)
- func (m *MockTransaction) QueryRow(ctx context.Context, stmt string, args ...any) database.Row
- func (m *MockTransaction) Rollback(ctx context.Context) error
- type MockTransactionMockRecorder
- func (mr *MockTransactionMockRecorder) Begin(ctx, opts any) *gomock.Call
- func (mr *MockTransactionMockRecorder) Commit(ctx any) *gomock.Call
- func (mr *MockTransactionMockRecorder) End(ctx, err any) *gomock.Call
- func (mr *MockTransactionMockRecorder) Exec(ctx, stmt any, args ...any) *gomock.Call
- func (mr *MockTransactionMockRecorder) Query(ctx, stmt any, args ...any) *gomock.Call
- func (mr *MockTransactionMockRecorder) QueryRow(ctx, stmt any, args ...any) *gomock.Call
- func (mr *MockTransactionMockRecorder) Rollback(ctx any) *gomock.Call
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MockBeginner ¶
type MockBeginner struct {
// contains filtered or unexported fields
}
MockBeginner is a mock of Beginner interface.
func NewMockBeginner ¶
func NewMockBeginner(ctrl *gomock.Controller) *MockBeginner
NewMockBeginner creates a new mock instance.
func (*MockBeginner) Begin ¶
func (m *MockBeginner) Begin(ctx context.Context, opts *database.TransactionOptions) (database.Transaction, error)
Begin mocks base method.
func (*MockBeginner) EXPECT ¶
func (m *MockBeginner) EXPECT() *MockBeginnerMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
type MockBeginnerMockRecorder ¶
type MockBeginnerMockRecorder struct {
// contains filtered or unexported fields
}
MockBeginnerMockRecorder is the mock recorder for MockBeginner.
type MockCollectableRows ¶
type MockCollectableRows struct {
// contains filtered or unexported fields
}
MockCollectableRows is a mock of CollectableRows interface.
func NewMockCollectableRows ¶
func NewMockCollectableRows(ctrl *gomock.Controller) *MockCollectableRows
NewMockCollectableRows creates a new mock instance.
func (*MockCollectableRows) Collect ¶
func (m *MockCollectableRows) Collect(dest any) error
Collect mocks base method.
func (*MockCollectableRows) CollectExactlyOneRow ¶
func (m *MockCollectableRows) CollectExactlyOneRow(dest any) error
CollectExactlyOneRow mocks base method.
func (*MockCollectableRows) CollectFirst ¶
func (m *MockCollectableRows) CollectFirst(dest any) error
CollectFirst mocks base method.
func (*MockCollectableRows) EXPECT ¶
func (m *MockCollectableRows) EXPECT() *MockCollectableRowsMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
type MockCollectableRowsMockRecorder ¶
type MockCollectableRowsMockRecorder struct {
// contains filtered or unexported fields
}
MockCollectableRowsMockRecorder is the mock recorder for MockCollectableRows.
func (*MockCollectableRowsMockRecorder) Collect ¶
func (mr *MockCollectableRowsMockRecorder) Collect(dest any) *gomock.Call
Collect indicates an expected call of Collect.
func (*MockCollectableRowsMockRecorder) CollectExactlyOneRow ¶
func (mr *MockCollectableRowsMockRecorder) CollectExactlyOneRow(dest any) *gomock.Call
CollectExactlyOneRow indicates an expected call of CollectExactlyOneRow.
func (*MockCollectableRowsMockRecorder) CollectFirst ¶
func (mr *MockCollectableRowsMockRecorder) CollectFirst(dest any) *gomock.Call
CollectFirst indicates an expected call of CollectFirst.
type MockConnection ¶
type MockConnection struct {
// contains filtered or unexported fields
}
MockConnection is a mock of Connection interface.
func NewMockConnection ¶
func NewMockConnection(ctrl *gomock.Controller) *MockConnection
NewMockConnection creates a new mock instance.
func (*MockConnection) Begin ¶
func (m *MockConnection) Begin(ctx context.Context, opts *database.TransactionOptions) (database.Transaction, error)
Begin mocks base method.
func (*MockConnection) EXPECT ¶
func (m *MockConnection) EXPECT() *MockConnectionMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockConnection) Migrate ¶
func (m *MockConnection) Migrate(ctx context.Context) error
Migrate mocks base method.
func (*MockConnection) Ping ¶
func (m *MockConnection) Ping(ctx context.Context) error
Ping mocks base method.
func (*MockConnection) Query ¶
func (m *MockConnection) Query(ctx context.Context, stmt string, args ...any) (database.Rows, error)
Query mocks base method.
type MockConnectionMockRecorder ¶
type MockConnectionMockRecorder struct {
// contains filtered or unexported fields
}
MockConnectionMockRecorder is the mock recorder for MockConnection.
func (*MockConnectionMockRecorder) Begin ¶
func (mr *MockConnectionMockRecorder) Begin(ctx, opts any) *gomock.Call
Begin indicates an expected call of Begin.
func (*MockConnectionMockRecorder) Exec ¶
func (mr *MockConnectionMockRecorder) Exec(ctx, stmt any, args ...any) *gomock.Call
Exec indicates an expected call of Exec.
func (*MockConnectionMockRecorder) Migrate ¶
func (mr *MockConnectionMockRecorder) Migrate(ctx any) *gomock.Call
Migrate indicates an expected call of Migrate.
func (*MockConnectionMockRecorder) Ping ¶
func (mr *MockConnectionMockRecorder) Ping(ctx any) *gomock.Call
Ping indicates an expected call of Ping.
func (*MockConnectionMockRecorder) Query ¶
func (mr *MockConnectionMockRecorder) Query(ctx, stmt any, args ...any) *gomock.Call
Query indicates an expected call of Query.
type MockExecutor ¶
type MockExecutor struct {
// contains filtered or unexported fields
}
MockExecutor is a mock of Executor interface.
func NewMockExecutor ¶
func NewMockExecutor(ctrl *gomock.Controller) *MockExecutor
NewMockExecutor creates a new mock instance.
func (*MockExecutor) EXPECT ¶
func (m *MockExecutor) EXPECT() *MockExecutorMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
type MockExecutorMockRecorder ¶
type MockExecutorMockRecorder struct {
// contains filtered or unexported fields
}
MockExecutorMockRecorder is the mock recorder for MockExecutor.
type MockPool ¶
type MockPool struct {
// contains filtered or unexported fields
}
MockPool is a mock of Pool interface.
func NewMockPool ¶
func NewMockPool(ctrl *gomock.Controller) *MockPool
NewMockPool creates a new mock instance.
func (*MockPool) Begin ¶
func (m *MockPool) Begin(ctx context.Context, opts *database.TransactionOptions) (database.Transaction, error)
Begin mocks base method.
func (*MockPool) EXPECT ¶
func (m *MockPool) EXPECT() *MockPoolMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
type MockPoolMockRecorder ¶
type MockPoolMockRecorder struct {
// contains filtered or unexported fields
}
MockPoolMockRecorder is the mock recorder for MockPool.
func (*MockPoolMockRecorder) Acquire ¶
func (mr *MockPoolMockRecorder) Acquire(ctx any) *gomock.Call
Acquire indicates an expected call of Acquire.
func (*MockPoolMockRecorder) Begin ¶
func (mr *MockPoolMockRecorder) Begin(ctx, opts any) *gomock.Call
Begin indicates an expected call of Begin.
func (*MockPoolMockRecorder) Close ¶
func (mr *MockPoolMockRecorder) Close(ctx any) *gomock.Call
Close indicates an expected call of Close.
func (*MockPoolMockRecorder) Exec ¶
func (mr *MockPoolMockRecorder) Exec(ctx, stmt any, args ...any) *gomock.Call
Exec indicates an expected call of Exec.
func (*MockPoolMockRecorder) Migrate ¶
func (mr *MockPoolMockRecorder) Migrate(ctx any) *gomock.Call
Migrate indicates an expected call of Migrate.
func (*MockPoolMockRecorder) Ping ¶
func (mr *MockPoolMockRecorder) Ping(ctx any) *gomock.Call
Ping indicates an expected call of Ping.
type MockPoolTest ¶
type MockPoolTest struct {
// contains filtered or unexported fields
}
MockPoolTest is a mock of PoolTest interface.
func NewMockPoolTest ¶
func NewMockPoolTest(ctrl *gomock.Controller) *MockPoolTest
NewMockPoolTest creates a new mock instance.
func (*MockPoolTest) Acquire ¶
func (m *MockPoolTest) Acquire(ctx context.Context) (database.Connection, error)
Acquire mocks base method.
func (*MockPoolTest) Begin ¶
func (m *MockPoolTest) Begin(ctx context.Context, opts *database.TransactionOptions) (database.Transaction, error)
Begin mocks base method.
func (*MockPoolTest) Close ¶
func (m *MockPoolTest) Close(ctx context.Context) error
Close mocks base method.
func (*MockPoolTest) EXPECT ¶
func (m *MockPoolTest) EXPECT() *MockPoolTestMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockPoolTest) Migrate ¶
func (m *MockPoolTest) Migrate(ctx context.Context) error
Migrate mocks base method.
func (*MockPoolTest) MigrateTest ¶
func (m *MockPoolTest) MigrateTest(ctx context.Context) error
MigrateTest mocks base method.
func (*MockPoolTest) Ping ¶
func (m *MockPoolTest) Ping(ctx context.Context) error
Ping mocks base method.
type MockPoolTestMockRecorder ¶
type MockPoolTestMockRecorder struct {
// contains filtered or unexported fields
}
MockPoolTestMockRecorder is the mock recorder for MockPoolTest.
func (*MockPoolTestMockRecorder) Acquire ¶
func (mr *MockPoolTestMockRecorder) Acquire(ctx any) *gomock.Call
Acquire indicates an expected call of Acquire.
func (*MockPoolTestMockRecorder) Begin ¶
func (mr *MockPoolTestMockRecorder) Begin(ctx, opts any) *gomock.Call
Begin indicates an expected call of Begin.
func (*MockPoolTestMockRecorder) Close ¶
func (mr *MockPoolTestMockRecorder) Close(ctx any) *gomock.Call
Close indicates an expected call of Close.
func (*MockPoolTestMockRecorder) Exec ¶
func (mr *MockPoolTestMockRecorder) Exec(ctx, stmt any, args ...any) *gomock.Call
Exec indicates an expected call of Exec.
func (*MockPoolTestMockRecorder) Migrate ¶
func (mr *MockPoolTestMockRecorder) Migrate(ctx any) *gomock.Call
Migrate indicates an expected call of Migrate.
func (*MockPoolTestMockRecorder) MigrateTest ¶
func (mr *MockPoolTestMockRecorder) MigrateTest(ctx any) *gomock.Call
MigrateTest indicates an expected call of MigrateTest.
func (*MockPoolTestMockRecorder) Ping ¶
func (mr *MockPoolTestMockRecorder) Ping(ctx any) *gomock.Call
Ping indicates an expected call of Ping.
func (*MockPoolTestMockRecorder) Query ¶
func (mr *MockPoolTestMockRecorder) Query(ctx, stmt any, args ...any) *gomock.Call
Query indicates an expected call of Query.
func (*MockPoolTestMockRecorder) QueryRow ¶
func (mr *MockPoolTestMockRecorder) QueryRow(ctx, stmt any, args ...any) *gomock.Call
QueryRow indicates an expected call of QueryRow.
func (*MockPoolTestMockRecorder) RawDB ¶
func (mr *MockPoolTestMockRecorder) RawDB() *gomock.Call
RawDB indicates an expected call of RawDB.
type MockQuerier ¶
type MockQuerier struct {
// contains filtered or unexported fields
}
MockQuerier is a mock of Querier interface.
func NewMockQuerier ¶
func NewMockQuerier(ctrl *gomock.Controller) *MockQuerier
NewMockQuerier creates a new mock instance.
func (*MockQuerier) EXPECT ¶
func (m *MockQuerier) EXPECT() *MockQuerierMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
type MockQuerierMockRecorder ¶
type MockQuerierMockRecorder struct {
// contains filtered or unexported fields
}
MockQuerierMockRecorder is the mock recorder for MockQuerier.
type MockQueryExecutor ¶
type MockQueryExecutor struct {
// contains filtered or unexported fields
}
MockQueryExecutor is a mock of QueryExecutor interface.
func NewMockQueryExecutor ¶
func NewMockQueryExecutor(ctrl *gomock.Controller) *MockQueryExecutor
NewMockQueryExecutor creates a new mock instance.
func (*MockQueryExecutor) EXPECT ¶
func (m *MockQueryExecutor) EXPECT() *MockQueryExecutorMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
type MockQueryExecutorMockRecorder ¶
type MockQueryExecutorMockRecorder struct {
// contains filtered or unexported fields
}
MockQueryExecutorMockRecorder is the mock recorder for MockQueryExecutor.
func (*MockQueryExecutorMockRecorder) Exec ¶
func (mr *MockQueryExecutorMockRecorder) Exec(ctx, stmt any, args ...any) *gomock.Call
Exec indicates an expected call of Exec.
type MockRow ¶
type MockRow struct {
// contains filtered or unexported fields
}
MockRow is a mock of Row interface.
func NewMockRow ¶
func NewMockRow(ctrl *gomock.Controller) *MockRow
NewMockRow creates a new mock instance.
func (*MockRow) EXPECT ¶
func (m *MockRow) EXPECT() *MockRowMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
type MockRowMockRecorder ¶
type MockRowMockRecorder struct {
// contains filtered or unexported fields
}
MockRowMockRecorder is the mock recorder for MockRow.
type MockRows ¶
type MockRows struct {
// contains filtered or unexported fields
}
MockRows is a mock of Rows interface.
func NewMockRows ¶
func NewMockRows(ctrl *gomock.Controller) *MockRows
NewMockRows creates a new mock instance.
func (*MockRows) EXPECT ¶
func (m *MockRows) EXPECT() *MockRowsMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
type MockRowsMockRecorder ¶
type MockRowsMockRecorder struct {
// contains filtered or unexported fields
}
MockRowsMockRecorder is the mock recorder for MockRows.
func (*MockRowsMockRecorder) Close ¶
func (mr *MockRowsMockRecorder) Close() *gomock.Call
Close indicates an expected call of Close.
func (*MockRowsMockRecorder) Err ¶
func (mr *MockRowsMockRecorder) Err() *gomock.Call
Err indicates an expected call of Err.
func (*MockRowsMockRecorder) Next ¶
func (mr *MockRowsMockRecorder) Next() *gomock.Call
Next indicates an expected call of Next.
type MockScanner ¶
type MockScanner struct {
// contains filtered or unexported fields
}
MockScanner is a mock of Scanner interface.
func NewMockScanner ¶
func NewMockScanner(ctrl *gomock.Controller) *MockScanner
NewMockScanner creates a new mock instance.
func (*MockScanner) EXPECT ¶
func (m *MockScanner) EXPECT() *MockScannerMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
type MockScannerMockRecorder ¶
type MockScannerMockRecorder struct {
// contains filtered or unexported fields
}
MockScannerMockRecorder is the mock recorder for MockScanner.
type MockTransaction ¶
type MockTransaction struct {
// contains filtered or unexported fields
}
MockTransaction is a mock of Transaction interface.
func NewMockTransaction ¶
func NewMockTransaction(ctrl *gomock.Controller) *MockTransaction
NewMockTransaction creates a new mock instance.
func (*MockTransaction) Begin ¶
func (m *MockTransaction) Begin(ctx context.Context, opts *database.TransactionOptions) (database.Transaction, error)
Begin mocks base method.
func (*MockTransaction) Commit ¶
func (m *MockTransaction) Commit(ctx context.Context) error
Commit mocks base method.
func (*MockTransaction) EXPECT ¶
func (m *MockTransaction) EXPECT() *MockTransactionMockRecorder
EXPECT returns an object that allows the caller to indicate expected use.
func (*MockTransaction) End ¶
func (m *MockTransaction) End(ctx context.Context, err error) error
End mocks base method.
func (*MockTransaction) Query ¶
func (m *MockTransaction) Query(ctx context.Context, stmt string, args ...any) (database.Rows, error)
Query mocks base method.
type MockTransactionMockRecorder ¶
type MockTransactionMockRecorder struct {
// contains filtered or unexported fields
}
MockTransactionMockRecorder is the mock recorder for MockTransaction.
func (*MockTransactionMockRecorder) Begin ¶
func (mr *MockTransactionMockRecorder) Begin(ctx, opts any) *gomock.Call
Begin indicates an expected call of Begin.
func (*MockTransactionMockRecorder) Commit ¶
func (mr *MockTransactionMockRecorder) Commit(ctx any) *gomock.Call
Commit indicates an expected call of Commit.
func (*MockTransactionMockRecorder) End ¶
func (mr *MockTransactionMockRecorder) End(ctx, err any) *gomock.Call
End indicates an expected call of End.
func (*MockTransactionMockRecorder) Exec ¶
func (mr *MockTransactionMockRecorder) Exec(ctx, stmt any, args ...any) *gomock.Call
Exec indicates an expected call of Exec.
func (*MockTransactionMockRecorder) Query ¶
func (mr *MockTransactionMockRecorder) Query(ctx, stmt any, args ...any) *gomock.Call
Query indicates an expected call of Query.