Versions in this module Expand all Collapse all v4 v4.1.0 Jun 12, 2024 v4.0.0 May 11, 2023 Changes in this version + func Any() T + func AnyBool() bool + func AnyBoolSlice() []bool + func AnyComplex128() complex128 + func AnyComplex128Slice() []complex128 + func AnyComplex64() complex64 + func AnyComplex64Slice() []complex64 + func AnyFloat32() float32 + func AnyFloat32Slice() []float32 + func AnyFloat64() float64 + func AnyFloat64Slice() []float64 + func AnyInt() int + func AnyInt16() int16 + func AnyInt16Slice() []int16 + func AnyInt32() int32 + func AnyInt32Slice() []int32 + func AnyInt64() int64 + func AnyInt64Slice() []int64 + func AnyInt8() int8 + func AnyInt8Slice() []int8 + func AnyIntSlice() []int + func AnyInterface() interface + func AnyInterfaceSlice() []interface + func AnyString() string + func AnyStringSlice() []string + func AnyUint() uint + func AnyUint16() uint16 + func AnyUint16Slice() []uint16 + func AnyUint32() uint32 + func AnyUint32Slice() []uint32 + func AnyUint64() uint64 + func AnyUint64Slice() []uint64 + func AnyUint8() uint8 + func AnyUint8Slice() []uint8 + func AnyUintSlice() []uint + func AnyUintptr() uintptr + func AnyUintptrSlice() []uintptr + func ArgThat(matcher ArgumentMatcher) T + func BoolSliceThat(matcher ArgumentMatcher) []bool + func BoolThat(matcher ArgumentMatcher) bool + func Complex128SliceThat(matcher ArgumentMatcher) []complex128 + func Complex128That(matcher ArgumentMatcher) complex128 + func Complex64SliceThat(matcher ArgumentMatcher) []complex64 + func Complex64That(matcher ArgumentMatcher) complex64 + func DumpInvocationsFor(mock Mock) + func Eq(value T) T + func Float32SliceThat(matcher ArgumentMatcher) []float32 + func Float32That(matcher ArgumentMatcher) float32 + func Float64SliceThat(matcher ArgumentMatcher) []float64 + func Float64That(matcher ArgumentMatcher) float64 + func Int16SliceThat(matcher ArgumentMatcher) []int16 + func Int16That(matcher ArgumentMatcher) int16 + func Int32SliceThat(matcher ArgumentMatcher) []int32 + func Int32That(matcher ArgumentMatcher) int32 + func Int64SliceThat(matcher ArgumentMatcher) []int64 + func Int64That(matcher ArgumentMatcher) int64 + func Int8SliceThat(matcher ArgumentMatcher) []int8 + func Int8That(matcher ArgumentMatcher) int8 + func IntSliceThat(matcher ArgumentMatcher) []int + func IntThat(matcher ArgumentMatcher) int + func InterceptMockFailures(f func()) []string + func InterfaceSliceThat(matcher ArgumentMatcher) []interface + func InterfaceThat(matcher ArgumentMatcher) interface + func NotEq(value T) T + func RegisterMatcher(matcher ArgumentMatcher) + func RegisterMockFailHandler(handler FailHandler) + func RegisterMockTestingT(t *testing.T) + func SDumpInvocationsFor(mock Mock) string + func StringSliceThat(matcher ArgumentMatcher) []string + func StringThat(matcher ArgumentMatcher) string + func Uint16SliceThat(matcher ArgumentMatcher) []uint16 + func Uint16That(matcher ArgumentMatcher) uint16 + func Uint32SliceThat(matcher ArgumentMatcher) []uint32 + func Uint32That(matcher ArgumentMatcher) uint32 + func Uint64SliceThat(matcher ArgumentMatcher) []uint64 + func Uint64That(matcher ArgumentMatcher) uint64 + func Uint8SliceThat(matcher ArgumentMatcher) []uint8 + func Uint8That(matcher ArgumentMatcher) uint8 + func UintSliceThat(matcher ArgumentMatcher) []uint + func UintThat(matcher ArgumentMatcher) uint + func UintptrSliceThat(matcher ArgumentMatcher) []uintptr + func UintptrThat(matcher ArgumentMatcher) uintptr + func When(invocation ...interface{}) *ongoingStubbing + type AnyMatcher struct + Type reflect.Type + func NewAnyMatcher(typ reflect.Type) *AnyMatcher + func (matcher *AnyMatcher) FailureMessage() string + func (matcher *AnyMatcher) Matches(param Param) bool + func (matcher *AnyMatcher) String() string + type ArgumentMatcher interface + Matches func(param Param) bool + type AtLeastIntMatcher struct + Value int + func AtLeast(numDesiredInvocations int) *AtLeastIntMatcher + func (matcher *AtLeastIntMatcher) FailureMessage() string + func (matcher *AtLeastIntMatcher) Matches(param Param) bool + func (matcher *AtLeastIntMatcher) String() string + type AtMostIntMatcher struct + Value int + func AtMost(numDesiredInvocations int) *AtMostIntMatcher + func (matcher *AtMostIntMatcher) FailureMessage() string + func (matcher *AtMostIntMatcher) Matches(param Param) bool + func (matcher *AtMostIntMatcher) String() string + type Counter struct + type EqMatcher struct + Value Param + func Never() *EqMatcher + func Once() *EqMatcher + func Times(numDesiredInvocations int) *EqMatcher + func Twice() *EqMatcher + func (matcher *EqMatcher) FailureMessage() string + func (matcher *EqMatcher) Matches(param Param) bool + func (matcher *EqMatcher) String() string + type FailHandler func(message string, callerSkip ...int) + var GlobalFailHandler FailHandler + func BuildTestingTFailHandler(t testingT) FailHandler + type GenericMock struct + func GetGenericMockFrom(mock Mock) *GenericMock + func (genericMock *GenericMock) GetInvocationParams(methodInvocations []MethodInvocation) [][]Param + func (genericMock *GenericMock) Invoke(methodName string, params []Param, returnTypes []reflect.Type) ReturnValues + func (genericMock *GenericMock) Verify(inOrderContext *InOrderContext, invocationCountMatcher InvocationCountMatcher, ...) []MethodInvocation + type InOrderContext struct + type InvocationCountMatcher interface + FailureMessage func() string + Matches func(param Param) bool + type Matcher interface + FailureMessage func() string + Matches func(param Param) bool + type Matchers []ArgumentMatcher + func (matchers Matchers) Matches(params []Param) bool + type MethodInvocation struct + type Mock interface + FailHandler func() FailHandler + SetFailHandler func(FailHandler) + type NotEqMatcher struct + Value Param + func (matcher *NotEqMatcher) FailureMessage() string + func (matcher *NotEqMatcher) Matches(param Param) bool + func (matcher *NotEqMatcher) String() string + type Option interface + Apply func(Mock) + func WithFailHandler(fail FailHandler) Option + func WithT(t testingT) Option + type OptionFunc func(mock Mock) + func (f OptionFunc) Apply(mock Mock) + type Param interface + type ReturnValue interface + type ReturnValues []ReturnValue + type Stubbing struct + func (stubbing *Stubbing) Invoke(params []Param) ReturnValues + type Stubbings []*Stubbing Other modules containing this package github.com/petergtz/pegomock github.com/petergtz/pegomock/v3