mock_postgres

package
v0.0.0-...-d078668 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 7, 2025 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Overview

Package mock_postgres is a generated GoMock package.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MockBasePool

type MockBasePool struct {
	// contains filtered or unexported fields
}

MockBasePool is a mock of BasePool interface.

func NewMockBasePool

func NewMockBasePool(ctrl *gomock.Controller) *MockBasePool

NewMockBasePool creates a new mock instance.

func (*MockBasePool) Begin

func (m *MockBasePool) Begin(ctx context.Context) (pgx.Tx, error)

Begin mocks base method.

func (*MockBasePool) Close

func (m *MockBasePool) Close()

Close mocks base method.

func (*MockBasePool) CopyFrom

func (m *MockBasePool) CopyFrom(ctx context.Context, tableName pgx.Identifier, columnNames []string, rowSrc pgx.CopyFromSource) (int64, error)

CopyFrom mocks base method.

func (*MockBasePool) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockBasePool) Exec

func (m *MockBasePool) Exec(ctx context.Context, sql string, arguments ...any) (pgconn.CommandTag, error)

Exec mocks base method.

func (*MockBasePool) Ping

func (m *MockBasePool) Ping(ctx context.Context) error

Ping mocks base method.

func (*MockBasePool) Query

func (m *MockBasePool) Query(ctx context.Context, sql string, args ...any) (pgx.Rows, error)

Query mocks base method.

func (*MockBasePool) QueryRow

func (m *MockBasePool) QueryRow(ctx context.Context, sql string, args ...any) pgx.Row

QueryRow mocks base method.

func (*MockBasePool) SendBatch

func (m *MockBasePool) SendBatch(ctx context.Context, b *pgx.Batch) pgx.BatchResults

SendBatch mocks base method.

func (*MockBasePool) Stat

func (m *MockBasePool) Stat() *pgxpool.Stat

Stat mocks base method.

type MockBasePoolMockRecorder

type MockBasePoolMockRecorder struct {
	// contains filtered or unexported fields
}

MockBasePoolMockRecorder is the mock recorder for MockBasePool.

func (*MockBasePoolMockRecorder) Begin

func (mr *MockBasePoolMockRecorder) Begin(ctx any) *gomock.Call

Begin indicates an expected call of Begin.

func (*MockBasePoolMockRecorder) Close

func (mr *MockBasePoolMockRecorder) Close() *gomock.Call

Close indicates an expected call of Close.

func (*MockBasePoolMockRecorder) CopyFrom

func (mr *MockBasePoolMockRecorder) CopyFrom(ctx, tableName, columnNames, rowSrc any) *gomock.Call

CopyFrom indicates an expected call of CopyFrom.

func (*MockBasePoolMockRecorder) Exec

func (mr *MockBasePoolMockRecorder) Exec(ctx, sql any, arguments ...any) *gomock.Call

Exec indicates an expected call of Exec.

func (*MockBasePoolMockRecorder) Ping

func (mr *MockBasePoolMockRecorder) Ping(ctx any) *gomock.Call

Ping indicates an expected call of Ping.

func (*MockBasePoolMockRecorder) Query

func (mr *MockBasePoolMockRecorder) Query(ctx, sql any, args ...any) *gomock.Call

Query indicates an expected call of Query.

func (*MockBasePoolMockRecorder) QueryRow

func (mr *MockBasePoolMockRecorder) QueryRow(ctx, sql any, args ...any) *gomock.Call

QueryRow indicates an expected call of QueryRow.

func (*MockBasePoolMockRecorder) SendBatch

func (mr *MockBasePoolMockRecorder) SendBatch(ctx, b any) *gomock.Call

SendBatch indicates an expected call of SendBatch.

func (*MockBasePoolMockRecorder) Stat

func (mr *MockBasePoolMockRecorder) Stat() *gomock.Call

Stat indicates an expected call of Stat.

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) Close

func (m *MockPool) Close()

Close mocks base method.

func (*MockPool) CopyFrom

func (m *MockPool) CopyFrom(ctx context.Context, tableName pgx.Identifier, columnNames []string, rowSrc pgx.CopyFromSource) (int64, error)

CopyFrom mocks base method.

func (*MockPool) EXPECT

func (m *MockPool) EXPECT() *MockPoolMockRecorder

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockPool) Exec

func (m *MockPool) Exec(ctx context.Context, sql string, arguments ...any) (pgconn.CommandTag, error)

Exec mocks base method.

func (*MockPool) Ping

func (m *MockPool) Ping(ctx context.Context) error

Ping mocks base method.

func (*MockPool) Query

func (m *MockPool) Query(ctx context.Context, sql string, args ...any) (pgx.Rows, error)

Query mocks base method.

func (*MockPool) QueryRow

func (m *MockPool) QueryRow(ctx context.Context, sql string, args ...any) pgx.Row

QueryRow mocks base method.

func (*MockPool) SendBatch

func (m *MockPool) SendBatch(ctx context.Context, b *pgx.Batch) error

SendBatch mocks base method.

func (*MockPool) WithTransaction

func (m *MockPool) WithTransaction(ctx context.Context, f func(context.Context, pgx.Tx) error) error

WithTransaction mocks base method.

type MockPoolMockRecorder

type MockPoolMockRecorder struct {
	// contains filtered or unexported fields
}

MockPoolMockRecorder is the mock recorder for MockPool.

func (*MockPoolMockRecorder) Close

func (mr *MockPoolMockRecorder) Close() *gomock.Call

Close indicates an expected call of Close.

func (*MockPoolMockRecorder) CopyFrom

func (mr *MockPoolMockRecorder) CopyFrom(ctx, tableName, columnNames, rowSrc any) *gomock.Call

CopyFrom indicates an expected call of CopyFrom.

func (*MockPoolMockRecorder) Exec

func (mr *MockPoolMockRecorder) Exec(ctx, sql any, arguments ...any) *gomock.Call

Exec indicates an expected call of Exec.

func (*MockPoolMockRecorder) Ping

func (mr *MockPoolMockRecorder) Ping(ctx any) *gomock.Call

Ping indicates an expected call of Ping.

func (*MockPoolMockRecorder) Query

func (mr *MockPoolMockRecorder) Query(ctx, sql any, args ...any) *gomock.Call

Query indicates an expected call of Query.

func (*MockPoolMockRecorder) QueryRow

func (mr *MockPoolMockRecorder) QueryRow(ctx, sql any, args ...any) *gomock.Call

QueryRow indicates an expected call of QueryRow.

func (*MockPoolMockRecorder) SendBatch

func (mr *MockPoolMockRecorder) SendBatch(ctx, b any) *gomock.Call

SendBatch indicates an expected call of SendBatch.

func (*MockPoolMockRecorder) WithTransaction

func (mr *MockPoolMockRecorder) WithTransaction(ctx, f any) *gomock.Call

WithTransaction indicates an expected call of WithTransaction.

Source Files

  • postgres.go

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL