mocks

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Oct 24, 2026 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MockTaskWorker

type MockTaskWorker[Task any, Result any] struct {
	mock.Mock
}

MockTaskWorker is an autogenerated mock type for the TaskWorker type

func NewMockTaskWorker

func NewMockTaskWorker[Task any, Result any](t interface {
	mock.TestingT
	Cleanup(func())
}) *MockTaskWorker[Task, Result]

NewMockTaskWorker creates a new instance of MockTaskWorker. 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 (*MockTaskWorker[Task, Result]) Complete

func (_mock *MockTaskWorker[Task, Result]) Complete(context1 context.Context, v *Result, v1 *Task) error

Complete provides a mock function for the type MockTaskWorker

func (*MockTaskWorker[Task, Result]) EXPECT

func (_m *MockTaskWorker[Task, Result]) EXPECT() *MockTaskWorker_Expecter[Task, Result]

func (*MockTaskWorker[Task, Result]) Execute

func (_mock *MockTaskWorker[Task, Result]) Execute(context1 context.Context, v *Task) (*Result, error)

Execute provides a mock function for the type MockTaskWorker

func (*MockTaskWorker[Task, Result]) Extend

func (_mock *MockTaskWorker[Task, Result]) Extend(context1 context.Context, v *Task) error

Extend provides a mock function for the type MockTaskWorker

func (*MockTaskWorker[Task, Result]) Get

func (_mock *MockTaskWorker[Task, Result]) Get(context1 context.Context, vs []workflow.Queue) (*Task, error)

Get provides a mock function for the type MockTaskWorker

func (*MockTaskWorker[Task, Result]) Start

func (_mock *MockTaskWorker[Task, Result]) Start(context1 context.Context, vs []workflow.Queue) error

Start provides a mock function for the type MockTaskWorker

type MockTaskWorker_Complete_Call

type MockTaskWorker_Complete_Call[Task any, Result any] struct {
	*mock.Call
}

MockTaskWorker_Complete_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Complete'

func (*MockTaskWorker_Complete_Call[Task, Result]) Return

func (_c *MockTaskWorker_Complete_Call[Task, Result]) Return(err error) *MockTaskWorker_Complete_Call[Task, Result]

func (*MockTaskWorker_Complete_Call[Task, Result]) Run

func (_c *MockTaskWorker_Complete_Call[Task, Result]) Run(run func(context1 context.Context, v *Result, v1 *Task)) *MockTaskWorker_Complete_Call[Task, Result]

func (*MockTaskWorker_Complete_Call[Task, Result]) RunAndReturn

func (_c *MockTaskWorker_Complete_Call[Task, Result]) RunAndReturn(run func(context1 context.Context, v *Result, v1 *Task) error) *MockTaskWorker_Complete_Call[Task, Result]

type MockTaskWorker_Execute_Call

type MockTaskWorker_Execute_Call[Task any, Result any] struct {
	*mock.Call
}

MockTaskWorker_Execute_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Execute'

func (*MockTaskWorker_Execute_Call[Task, Result]) Return

func (_c *MockTaskWorker_Execute_Call[Task, Result]) Return(v1 *Result, err error) *MockTaskWorker_Execute_Call[Task, Result]

func (*MockTaskWorker_Execute_Call[Task, Result]) Run

func (_c *MockTaskWorker_Execute_Call[Task, Result]) Run(run func(context1 context.Context, v *Task)) *MockTaskWorker_Execute_Call[Task, Result]

func (*MockTaskWorker_Execute_Call[Task, Result]) RunAndReturn

func (_c *MockTaskWorker_Execute_Call[Task, Result]) RunAndReturn(run func(context1 context.Context, v *Task) (*Result, error)) *MockTaskWorker_Execute_Call[Task, Result]

type MockTaskWorker_Expecter

type MockTaskWorker_Expecter[Task any, Result any] struct {
	// contains filtered or unexported fields
}

func (*MockTaskWorker_Expecter[Task, Result]) Complete

func (_e *MockTaskWorker_Expecter[Task, Result]) Complete(context1 interface{}, v interface{}, v1 interface{}) *MockTaskWorker_Complete_Call[Task, Result]

Complete is a helper method to define mock.On call

  • context1 context.Context
  • v *Result
  • v1 *Task

func (*MockTaskWorker_Expecter[Task, Result]) Execute

func (_e *MockTaskWorker_Expecter[Task, Result]) Execute(context1 interface{}, v interface{}) *MockTaskWorker_Execute_Call[Task, Result]

Execute is a helper method to define mock.On call

  • context1 context.Context
  • v *Task

func (*MockTaskWorker_Expecter[Task, Result]) Extend

func (_e *MockTaskWorker_Expecter[Task, Result]) Extend(context1 interface{}, v interface{}) *MockTaskWorker_Extend_Call[Task, Result]

Extend is a helper method to define mock.On call

  • context1 context.Context
  • v *Task

func (*MockTaskWorker_Expecter[Task, Result]) Get

func (_e *MockTaskWorker_Expecter[Task, Result]) Get(context1 interface{}, vs interface{}) *MockTaskWorker_Get_Call[Task, Result]

Get is a helper method to define mock.On call

  • context1 context.Context
  • vs []workflow.Queue

func (*MockTaskWorker_Expecter[Task, Result]) Start

func (_e *MockTaskWorker_Expecter[Task, Result]) Start(context1 interface{}, vs interface{}) *MockTaskWorker_Start_Call[Task, Result]

Start is a helper method to define mock.On call

  • context1 context.Context
  • vs []workflow.Queue

type MockTaskWorker_Extend_Call

type MockTaskWorker_Extend_Call[Task any, Result any] struct {
	*mock.Call
}

MockTaskWorker_Extend_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Extend'

func (*MockTaskWorker_Extend_Call[Task, Result]) Return

func (_c *MockTaskWorker_Extend_Call[Task, Result]) Return(err error) *MockTaskWorker_Extend_Call[Task, Result]

func (*MockTaskWorker_Extend_Call[Task, Result]) Run

func (_c *MockTaskWorker_Extend_Call[Task, Result]) Run(run func(context1 context.Context, v *Task)) *MockTaskWorker_Extend_Call[Task, Result]

func (*MockTaskWorker_Extend_Call[Task, Result]) RunAndReturn

func (_c *MockTaskWorker_Extend_Call[Task, Result]) RunAndReturn(run func(context1 context.Context, v *Task) error) *MockTaskWorker_Extend_Call[Task, Result]

type MockTaskWorker_Get_Call

type MockTaskWorker_Get_Call[Task any, Result any] struct {
	*mock.Call
}

MockTaskWorker_Get_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Get'

func (*MockTaskWorker_Get_Call[Task, Result]) Return

func (_c *MockTaskWorker_Get_Call[Task, Result]) Return(v *Task, err error) *MockTaskWorker_Get_Call[Task, Result]

func (*MockTaskWorker_Get_Call[Task, Result]) Run

func (_c *MockTaskWorker_Get_Call[Task, Result]) Run(run func(context1 context.Context, vs []workflow.Queue)) *MockTaskWorker_Get_Call[Task, Result]

func (*MockTaskWorker_Get_Call[Task, Result]) RunAndReturn

func (_c *MockTaskWorker_Get_Call[Task, Result]) RunAndReturn(run func(context1 context.Context, vs []workflow.Queue) (*Task, error)) *MockTaskWorker_Get_Call[Task, Result]

type MockTaskWorker_Start_Call

type MockTaskWorker_Start_Call[Task any, Result any] struct {
	*mock.Call
}

MockTaskWorker_Start_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Start'

func (*MockTaskWorker_Start_Call[Task, Result]) Return

func (_c *MockTaskWorker_Start_Call[Task, Result]) Return(err error) *MockTaskWorker_Start_Call[Task, Result]

func (*MockTaskWorker_Start_Call[Task, Result]) Run

func (_c *MockTaskWorker_Start_Call[Task, Result]) Run(run func(context1 context.Context, vs []workflow.Queue)) *MockTaskWorker_Start_Call[Task, Result]

func (*MockTaskWorker_Start_Call[Task, Result]) RunAndReturn

func (_c *MockTaskWorker_Start_Call[Task, Result]) RunAndReturn(run func(context1 context.Context, vs []workflow.Queue) error) *MockTaskWorker_Start_Call[Task, Result]

Jump to

Keyboard shortcuts

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