validatormocks

package
v0.5.1 Latest Latest
Warning

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

Go to latest
Published: Jul 4, 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 MockRegistry

type MockRegistry struct {
	mock.Mock
}

MockRegistry is an autogenerated mock type for the Registry type

func NewMockRegistry

func NewMockRegistry(t interface {
	mock.TestingT
	Cleanup(func())
}) *MockRegistry

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

func (_m *MockRegistry) EXPECT() *MockRegistry_Expecter

func (*MockRegistry) Parse

func (_mock *MockRegistry) Parse(s string, s1 string) ([]options.SchemaOption, error)

Parse provides a mock function for the type MockRegistry

func (*MockRegistry) Register

func (_mock *MockRegistry) Register(tag validator.Tag)

Register provides a mock function for the type MockRegistry

func (*MockRegistry) Validators

func (_mock *MockRegistry) Validators() []validator.Tag

Validators provides a mock function for the type MockRegistry

type MockRegistry_Expecter

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

func (*MockRegistry_Expecter) Parse

func (_e *MockRegistry_Expecter) Parse(s interface{}, s1 interface{}) *MockRegistry_Parse_Call

Parse is a helper method to define mock.On call

  • s string
  • s1 string

func (*MockRegistry_Expecter) Register

func (_e *MockRegistry_Expecter) Register(tag interface{}) *MockRegistry_Register_Call

Register is a helper method to define mock.On call

  • tag validator.Tag

func (*MockRegistry_Expecter) Validators

Validators is a helper method to define mock.On call

type MockRegistry_Parse_Call

type MockRegistry_Parse_Call struct {
	*mock.Call
}

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

func (*MockRegistry_Parse_Call) Return

func (_c *MockRegistry_Parse_Call) Return(schemaOptions []options.SchemaOption, err error) *MockRegistry_Parse_Call

func (*MockRegistry_Parse_Call) Run

func (*MockRegistry_Parse_Call) RunAndReturn

func (_c *MockRegistry_Parse_Call) RunAndReturn(run func(s string, s1 string) ([]options.SchemaOption, error)) *MockRegistry_Parse_Call

type MockRegistry_Register_Call

type MockRegistry_Register_Call struct {
	*mock.Call
}

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

func (*MockRegistry_Register_Call) Return

func (*MockRegistry_Register_Call) Run

func (*MockRegistry_Register_Call) RunAndReturn

func (_c *MockRegistry_Register_Call) RunAndReturn(run func(tag validator.Tag)) *MockRegistry_Register_Call

type MockRegistry_Validators_Call

type MockRegistry_Validators_Call struct {
	*mock.Call
}

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

func (*MockRegistry_Validators_Call) Return

func (*MockRegistry_Validators_Call) Run

func (*MockRegistry_Validators_Call) RunAndReturn

type MockTag added in v0.5.1

type MockTag struct {
	mock.Mock
}

MockTag is an autogenerated mock type for the Tag type

func NewMockTag added in v0.5.1

func NewMockTag(t interface {
	mock.TestingT
	Cleanup(func())
}) *MockTag

NewMockTag creates a new instance of MockTag. 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 (*MockTag) EXPECT added in v0.5.1

func (_m *MockTag) EXPECT() *MockTag_Expecter

func (*MockTag) Parse added in v0.5.1

func (_mock *MockTag) Parse(value string, as string) ([]options.SchemaOption, error)

Parse provides a mock function for the type MockTag

func (*MockTag) Tag added in v0.5.1

func (_mock *MockTag) Tag() string

Tag provides a mock function for the type MockTag

func (*MockTag) Usage added in v0.5.1

func (_mock *MockTag) Usage() string

Usage provides a mock function for the type MockTag

type MockTag_Expecter added in v0.5.1

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

func (*MockTag_Expecter) Parse added in v0.5.1

func (_e *MockTag_Expecter) Parse(value interface{}, as interface{}) *MockTag_Parse_Call

Parse is a helper method to define mock.On call

  • value string
  • as string

func (*MockTag_Expecter) Tag added in v0.5.1

Tag is a helper method to define mock.On call

func (*MockTag_Expecter) Usage added in v0.5.1

func (_e *MockTag_Expecter) Usage() *MockTag_Usage_Call

Usage is a helper method to define mock.On call

type MockTag_Parse_Call added in v0.5.1

type MockTag_Parse_Call struct {
	*mock.Call
}

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

func (*MockTag_Parse_Call) Return added in v0.5.1

func (_c *MockTag_Parse_Call) Return(schemaOptions []options.SchemaOption, err error) *MockTag_Parse_Call

func (*MockTag_Parse_Call) Run added in v0.5.1

func (_c *MockTag_Parse_Call) Run(run func(value string, as string)) *MockTag_Parse_Call

func (*MockTag_Parse_Call) RunAndReturn added in v0.5.1

func (_c *MockTag_Parse_Call) RunAndReturn(run func(value string, as string) ([]options.SchemaOption, error)) *MockTag_Parse_Call

type MockTag_Tag_Call added in v0.5.1

type MockTag_Tag_Call struct {
	*mock.Call
}

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

func (*MockTag_Tag_Call) Return added in v0.5.1

func (_c *MockTag_Tag_Call) Return(s string) *MockTag_Tag_Call

func (*MockTag_Tag_Call) Run added in v0.5.1

func (_c *MockTag_Tag_Call) Run(run func()) *MockTag_Tag_Call

func (*MockTag_Tag_Call) RunAndReturn added in v0.5.1

func (_c *MockTag_Tag_Call) RunAndReturn(run func() string) *MockTag_Tag_Call

type MockTag_Usage_Call added in v0.5.1

type MockTag_Usage_Call struct {
	*mock.Call
}

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

func (*MockTag_Usage_Call) Return added in v0.5.1

func (*MockTag_Usage_Call) Run added in v0.5.1

func (_c *MockTag_Usage_Call) Run(run func()) *MockTag_Usage_Call

func (*MockTag_Usage_Call) RunAndReturn added in v0.5.1

func (_c *MockTag_Usage_Call) RunAndReturn(run func() string) *MockTag_Usage_Call

Jump to

Keyboard shortcuts

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