mocks

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Sep 11, 2026 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Overview

Package mocks contains generated test doubles for MCP adapter ports.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MockInvocationResolver

type MockInvocationResolver struct {
	mock.Mock
}

MockInvocationResolver is an autogenerated mock type for the InvocationResolver type

func NewMockInvocationResolver

func NewMockInvocationResolver(t interface {
	mock.TestingT
	Cleanup(func())
}) *MockInvocationResolver

NewMockInvocationResolver creates a new instance of MockInvocationResolver. 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 (*MockInvocationResolver) EXPECT

func (*MockInvocationResolver) Resolve

func (_mock *MockInvocationResolver) Resolve(ctx context.Context) (authz.Subject, error)

Resolve provides a mock function for the type MockInvocationResolver

type MockInvocationResolver_Expecter

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

func (*MockInvocationResolver_Expecter) Resolve

Resolve is a helper method to define mock.On call

  • ctx context.Context

type MockInvocationResolver_Resolve_Call

type MockInvocationResolver_Resolve_Call struct {
	*mock.Call
}

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

func (*MockInvocationResolver_Resolve_Call) Return

func (*MockInvocationResolver_Resolve_Call) Run

func (*MockInvocationResolver_Resolve_Call) RunAndReturn

type MockService

type MockService struct {
	mock.Mock
}

MockService is an autogenerated mock type for the Service type

func NewMockService

func NewMockService(t interface {
	mock.TestingT
	Cleanup(func())
}) *MockService

NewMockService creates a new instance of MockService. 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 (*MockService) Describe

func (_mock *MockService) Describe(name codemode.CapabilityName) (codemode.Description, error)

Describe provides a mock function for the type MockService

func (*MockService) EXPECT

func (_m *MockService) EXPECT() *MockService_Expecter

func (*MockService) Execute

func (_mock *MockService) Execute(ctx context.Context, subject authz.Subject, program codemode.Program) (any, error)

Execute provides a mock function for the type MockService

func (*MockService) Search

func (_mock *MockService) Search(query string) (codemode.SearchResponse, error)

Search provides a mock function for the type MockService

type MockService_Describe_Call

type MockService_Describe_Call struct {
	*mock.Call
}

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

func (*MockService_Describe_Call) Return

func (*MockService_Describe_Call) Run

func (*MockService_Describe_Call) RunAndReturn

type MockService_Execute_Call

type MockService_Execute_Call struct {
	*mock.Call
}

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

func (*MockService_Execute_Call) Return

func (*MockService_Execute_Call) Run

func (*MockService_Execute_Call) RunAndReturn

func (_c *MockService_Execute_Call) RunAndReturn(run func(ctx context.Context, subject authz.Subject, program codemode.Program) (any, error)) *MockService_Execute_Call

type MockService_Expecter

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

func (*MockService_Expecter) Describe

Describe is a helper method to define mock.On call

  • name codemode.CapabilityName

func (*MockService_Expecter) Execute

func (_e *MockService_Expecter) Execute(ctx any, subject any, program any) *MockService_Execute_Call

Execute is a helper method to define mock.On call

  • ctx context.Context
  • subject authz.Subject
  • program codemode.Program

func (*MockService_Expecter) Search

Search is a helper method to define mock.On call

  • query string

type MockService_Search_Call

type MockService_Search_Call struct {
	*mock.Call
}

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

func (*MockService_Search_Call) Return

func (*MockService_Search_Call) Run

func (_c *MockService_Search_Call) Run(run func(query string)) *MockService_Search_Call

func (*MockService_Search_Call) RunAndReturn

Jump to

Keyboard shortcuts

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