Documentation
¶
Index ¶
- Constants
- func Dump(t *testing.T, v any, opts ...Option)
- func Register(v any, opts ...Option)
- type Dumper
- type Masker
- type Option
- func CmpOpts(opts ...cmp.Option) Option
- func Colors(colors bool) Option
- func Env(name string) Option
- func File(name string) Option
- func IgnoreFields(fields ...string) Option
- func IgnorePaths(paths ...string) Option
- func IgnorePatterns(patterns ...string) Option
- func MaskFields(mask string, fields []string) Option
- func MaskPaths(mask string, paths []string) Option
- func Transformers(p ...func([]byte) ([]byte, error)) Option
- func Validate(vs ...Validator) Option
- type Registry
- type Validator
Constants ¶
View Source
const UUIDPattern = `[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[1-5][a-fA-F0-9]{3}-[89abAB][a-fA-F0-9]{3}-[a-fA-F0-9]{12}`
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Dumper ¶
type Dumper struct {
// contains filtered or unexported fields
}
type Masker ¶
type Masker struct {
// contains filtered or unexported fields
}
Define a struct for a Masker
func (*Masker) MaskFields ¶
MaskFields is a method on Masker that masks certain fields
type Option ¶
type Option func(o *options)
Define a function type Option that takes a pointer to an options struct
func IgnoreFields ¶
IgnoreFields is an Option that ignores certain fields
func IgnorePaths ¶
IgnorePaths is an Option that ignores certain paths
func IgnorePatterns ¶
func MaskFields ¶
MaskFields is an Option that masks certain fields
func Transformers ¶
Transformers is an Option that adds a transformer function
type Registry ¶
type Registry struct {
// contains filtered or unexported fields
}
func NewRegistry ¶
func NewRegistry() *Registry
Click to show internal directories.
Click to hide internal directories.