mocks

package
v0.1.18 Latest Latest
Warning

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

Go to latest
Published: Aug 26, 2026 License: Apache-2.0, MIT Imports: 3 Imported by: 0

Documentation

Overview

Package mocks provides generated package metadata inspection test doubles.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MockInspector

type MockInspector struct {
	mock.Mock
}

MockInspector is an autogenerated mock type for the Inspector type

func NewMockInspector

func NewMockInspector(t interface {
	mock.TestingT
	Cleanup(func())
}) *MockInspector

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

func (_m *MockInspector) EXPECT() *MockInspector_Expecter

func (*MockInspector) Inspect

func (_mock *MockInspector) Inspect(ctx context.Context, format pkgrepo.Format, packagePath string) (pkgrepo.PackageMetadata, error)

Inspect provides a mock function for the type MockInspector

type MockInspector_Expecter

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

func (*MockInspector_Expecter) Inspect

func (_e *MockInspector_Expecter) Inspect(ctx any, format any, packagePath any) *MockInspector_Inspect_Call

Inspect is a helper method to define mock.On call

  • ctx context.Context
  • format pkgrepo.Format
  • packagePath string

type MockInspector_Inspect_Call

type MockInspector_Inspect_Call struct {
	*mock.Call
}

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

func (*MockInspector_Inspect_Call) Return

func (*MockInspector_Inspect_Call) Run

func (_c *MockInspector_Inspect_Call) Run(run func(ctx context.Context, format pkgrepo.Format, packagePath string)) *MockInspector_Inspect_Call

func (*MockInspector_Inspect_Call) RunAndReturn

func (_c *MockInspector_Inspect_Call) RunAndReturn(run func(ctx context.Context, format pkgrepo.Format, packagePath string) (pkgrepo.PackageMetadata, error)) *MockInspector_Inspect_Call

Jump to

Keyboard shortcuts

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