automock

package
v0.0.0-...-a423d60 Latest Latest
Warning

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

Go to latest
Published: Jul 4, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type PersistenceOp

type PersistenceOp struct {
	mock.Mock
}

PersistenceOp is an autogenerated mock type for the PersistenceOp type

func NewPersistenceOp

func NewPersistenceOp(t interface {
	mock.TestingT
	Cleanup(func())
}) *PersistenceOp

NewPersistenceOp creates a new instance of PersistenceOp. 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 (*PersistenceOp) ExecContext

func (_m *PersistenceOp) ExecContext(ctx context.Context, query string, args ...interface{}) (sql.Result, error)

ExecContext provides a mock function with given fields: ctx, query, args

func (*PersistenceOp) GetContext

func (_m *PersistenceOp) GetContext(ctx context.Context, dest interface{}, query string, args ...interface{}) error

GetContext provides a mock function with given fields: ctx, dest, query, args

func (*PersistenceOp) NamedExecContext

func (_m *PersistenceOp) NamedExecContext(ctx context.Context, query string, arg interface{}) (sql.Result, error)

NamedExecContext provides a mock function with given fields: ctx, query, arg

func (*PersistenceOp) SelectContext

func (_m *PersistenceOp) SelectContext(ctx context.Context, dest interface{}, query string, args ...interface{}) error

SelectContext provides a mock function with given fields: ctx, dest, query, args

type PersistenceTx

type PersistenceTx struct {
	mock.Mock
}

PersistenceTx is an autogenerated mock type for the PersistenceTx type

func NewPersistenceTx

func NewPersistenceTx(t interface {
	mock.TestingT
	Cleanup(func())
}) *PersistenceTx

NewPersistenceTx creates a new instance of PersistenceTx. 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 (*PersistenceTx) Commit

func (_m *PersistenceTx) Commit() error

Commit provides a mock function with given fields:

func (*PersistenceTx) ExecContext

func (_m *PersistenceTx) ExecContext(ctx context.Context, query string, args ...interface{}) (sql.Result, error)

ExecContext provides a mock function with given fields: ctx, query, args

func (*PersistenceTx) GetContext

func (_m *PersistenceTx) GetContext(ctx context.Context, dest interface{}, query string, args ...interface{}) error

GetContext provides a mock function with given fields: ctx, dest, query, args

func (*PersistenceTx) NamedExecContext

func (_m *PersistenceTx) NamedExecContext(ctx context.Context, query string, arg interface{}) (sql.Result, error)

NamedExecContext provides a mock function with given fields: ctx, query, arg

func (*PersistenceTx) Rollback

func (_m *PersistenceTx) Rollback() error

Rollback provides a mock function with given fields:

func (*PersistenceTx) SelectContext

func (_m *PersistenceTx) SelectContext(ctx context.Context, dest interface{}, query string, args ...interface{}) error

SelectContext provides a mock function with given fields: ctx, dest, query, args

type Transactioner

type Transactioner struct {
	mock.Mock
}

Transactioner is an autogenerated mock type for the Transactioner type

func NewTransactioner

func NewTransactioner(t interface {
	mock.TestingT
	Cleanup(func())
}) *Transactioner

NewTransactioner creates a new instance of Transactioner. 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 (*Transactioner) Begin

Begin provides a mock function with given fields:

func (*Transactioner) PingContext

func (_m *Transactioner) PingContext(ctx context.Context) error

PingContext provides a mock function with given fields: ctx

func (*Transactioner) RollbackUnlessCommitted

func (_m *Transactioner) RollbackUnlessCommitted(ctx context.Context, tx persistence.PersistenceTx) bool

RollbackUnlessCommitted provides a mock function with given fields: ctx, tx

func (*Transactioner) Stats

func (_m *Transactioner) Stats() sql.DBStats

Stats provides a mock function with given fields:

Jump to

Keyboard shortcuts

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