Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrNotFound = errors.New("not found")
)
Functions ¶
func RenderPrimitiveValue ¶
Types ¶
type Node ¶
type Option ¶
type Option func(*differ)
func WithCompareNumberAndNumericString ¶
func WithCompareNumberAndNumericString() Option
WithCompareNumberAndNumericString configures differ to compare a number with a numeric string. Differ parses the string to number before comparing their values. e.g. 1.5 == "1.5"
func WithEquateEmpty ¶
func WithEquateEmpty() Option
WithEquateEmpty configures differ to consider all maps/slides with a length of zero and nil to be equal.
func WithIgnoreAddingMapKeys ¶
func WithIgnoreAddingMapKeys() Option
WithIgnoreAddingMapKeys configures differ to ignore all map keys that were added to the second object and missing in the first one.
func WithIgnoreConfig ¶ added in v0.43.0
WithIgnoreConfig configures ignored fields.
type PathStep ¶
type PathStep struct { Type PathStepType MapIndex string SliceIndex int }
type PathStepType ¶
type PathStepType string
const ( MapIndexPathStep PathStepType = "MapIndex" SliceIndexPathStep PathStepType = "SliceIndex" )
type RenderOption ¶
type RenderOption func(*Renderer)
func WithLeftPadding ¶
func WithLeftPadding(p int) RenderOption
func WithMaskPath ¶
func WithMaskPath(prefix string) RenderOption
type Renderer ¶
type Renderer struct {
// contains filtered or unexported fields
}
func NewRenderer ¶
func NewRenderer(opts ...RenderOption) *Renderer
type Result ¶
type Result struct {
// contains filtered or unexported fields
}
func DiffUnstructureds ¶
func DiffUnstructureds(x, y unstructured.Unstructured, key string, opts ...Option) (*Result, error)
DiffUnstructureds calculates the diff between two unstructured objects.
Click to show internal directories.
Click to hide internal directories.