Versions in this module Expand all Collapse all v1 v1.2.0 Feb 21, 2017 Changes in this version + var CSVColumnParser = func(s string) []byte + var ErrCancelled = errors.New("canceling query due to user request") + func NewErrorResult(err error) driver.Result + func NewResult(lastInsertID int64, rowsAffected int64) driver.Result + type Argument interface + Match func(driver.Value) bool + func AnyArg() Argument + type ExpectedBegin struct + func (e *ExpectedBegin) String() string + func (e *ExpectedBegin) WillDelayFor(duration time.Duration) *ExpectedBegin + func (e *ExpectedBegin) WillReturnError(err error) *ExpectedBegin + type ExpectedClose struct + func (e *ExpectedClose) String() string + func (e *ExpectedClose) WillReturnError(err error) *ExpectedClose + type ExpectedCommit struct + func (e *ExpectedCommit) String() string + func (e *ExpectedCommit) WillReturnError(err error) *ExpectedCommit + type ExpectedExec struct + func (e *ExpectedExec) String() string + func (e *ExpectedExec) WillDelayFor(duration time.Duration) *ExpectedExec + func (e *ExpectedExec) WillReturnError(err error) *ExpectedExec + func (e *ExpectedExec) WillReturnResult(result driver.Result) *ExpectedExec + func (e *ExpectedExec) WithArgs(args ...driver.Value) *ExpectedExec + type ExpectedPrepare struct + func (e *ExpectedPrepare) ExpectExec() *ExpectedExec + func (e *ExpectedPrepare) ExpectQuery() *ExpectedQuery + func (e *ExpectedPrepare) String() string + func (e *ExpectedPrepare) WillDelayFor(duration time.Duration) *ExpectedPrepare + func (e *ExpectedPrepare) WillReturnCloseError(err error) *ExpectedPrepare + func (e *ExpectedPrepare) WillReturnError(err error) *ExpectedPrepare + type ExpectedQuery struct + func (e *ExpectedQuery) String() string + func (e *ExpectedQuery) WillDelayFor(duration time.Duration) *ExpectedQuery + func (e *ExpectedQuery) WillReturnError(err error) *ExpectedQuery + func (e *ExpectedQuery) WillReturnRows(rows ...*Rows) *ExpectedQuery + func (e *ExpectedQuery) WithArgs(args ...driver.Value) *ExpectedQuery + type ExpectedRollback struct + func (e *ExpectedRollback) String() string + func (e *ExpectedRollback) WillReturnError(err error) *ExpectedRollback + type Rows struct + func NewRows(columns []string) *Rows + func (r *Rows) AddRow(values ...driver.Value) *Rows + func (r *Rows) CloseError(err error) *Rows + func (r *Rows) FromCSVString(s string) *Rows + func (r *Rows) RowError(row int, err error) *Rows + type Sqlmock interface + ExpectBegin func() *ExpectedBegin + ExpectClose func() *ExpectedClose + ExpectCommit func() *ExpectedCommit + ExpectExec func(sqlRegexStr string) *ExpectedExec + ExpectPrepare func(sqlRegexStr string) *ExpectedPrepare + ExpectQuery func(sqlRegexStr string) *ExpectedQuery + ExpectRollback func() *ExpectedRollback + ExpectationsWereMet func() error + MatchExpectationsInOrder func(bool) + func New() (*sql.DB, Sqlmock, error) + func NewWithDSN(dsn string) (*sql.DB, Sqlmock, error)