Documentation ¶
Index ¶
- func CompareResourceSpans(expected, actual ptrace.ResourceSpans) error
- func CompareScopeSpans(expected, actual ptrace.ScopeSpans) error
- func CompareSpan(expected, actual ptrace.Span) error
- func CompareSpanEvent(expected, actual ptrace.SpanEvent) error
- func CompareSpanLink(expected, actual ptrace.SpanLink) error
- func CompareTraces(expected, actual ptrace.Traces, options ...CompareTracesOption) error
- type CompareTracesOption
- func IgnoreEndTimestamp() CompareTracesOption
- func IgnoreResourceAttributeValue(attributeName string) CompareTracesOption
- func IgnoreResourceSpansOrder() CompareTracesOption
- func IgnoreScopeSpanInstrumentationScopeAttributeValue(attributeName string) CompareTracesOption
- func IgnoreScopeSpanInstrumentationScopeName() CompareTracesOption
- func IgnoreScopeSpanInstrumentationScopeVersion() CompareTracesOption
- func IgnoreScopeSpansOrder() CompareTracesOption
- func IgnoreSpanAttributeValue(attributeName string) CompareTracesOption
- func IgnoreSpanID() CompareTracesOption
- func IgnoreSpansOrder() CompareTracesOption
- func IgnoreStartTimestamp() CompareTracesOption
- func IgnoreTraceID() CompareTracesOption
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CompareResourceSpans ¶
func CompareResourceSpans(expected, actual ptrace.ResourceSpans) error
CompareResourceSpans compares each part of two given ResourceSpans and returns an error if they don't match. The error describes what didn't match.
func CompareScopeSpans ¶
func CompareScopeSpans(expected, actual ptrace.ScopeSpans) error
CompareScopeSpans compares each part of two given SpanSlices and returns an error if they don't match. The error describes what didn't match.
func CompareSpan ¶
CompareSpan compares each part of two given Span and returns an error if they don't match. The error describes what didn't match.
func CompareSpanEvent ¶ added in v0.71.0
CompareSpanEvent compares each part of two given SpanEvent and returns an error if they don't match. The error describes what didn't match.
func CompareSpanLink ¶ added in v0.71.0
CompareSpanLink compares each part of two given SpanLink and returns an error if they don't match. The error describes what didn't match.
func CompareTraces ¶
func CompareTraces(expected, actual ptrace.Traces, options ...CompareTracesOption) error
CompareTraces compares each part of two given Traces and returns an error if they don't match. The error describes what didn't match.
Types ¶
type CompareTracesOption ¶
type CompareTracesOption interface {
// contains filtered or unexported methods
}
CompareTracesOption can be used to mutate expected and/or actual traces before comparing.
func IgnoreEndTimestamp ¶ added in v0.88.0
func IgnoreEndTimestamp() CompareTracesOption
IgnoreEndTimestamp is a CompareTracesOption that clears EndTimestamp fields on all spans.
func IgnoreResourceAttributeValue ¶
func IgnoreResourceAttributeValue(attributeName string) CompareTracesOption
IgnoreResourceAttributeValue is a CompareTracesOption that removes a resource attribute from all resources.
func IgnoreResourceSpansOrder ¶
func IgnoreResourceSpansOrder() CompareTracesOption
IgnoreResourceSpansOrder is a CompareTracesOption that ignores the order of resource traces/metrics/logs.
func IgnoreScopeSpanInstrumentationScopeAttributeValue ¶ added in v0.100.0
func IgnoreScopeSpanInstrumentationScopeAttributeValue(attributeName string) CompareTracesOption
IgnoreScopeSpanInstrumentationScopeAttributeValue is a CompareTracesOption that clears value of the scope span instrumentation scope name.
func IgnoreScopeSpanInstrumentationScopeName ¶ added in v0.100.0
func IgnoreScopeSpanInstrumentationScopeName() CompareTracesOption
IgnoreScopeSpanInstrumentationScopeName is a CompareTracesOption that clears value of the scope span instrumentation scope name.
func IgnoreScopeSpanInstrumentationScopeVersion ¶ added in v0.100.0
func IgnoreScopeSpanInstrumentationScopeVersion() CompareTracesOption
IgnoreScopeSpanInstrumentationScopeVersion is a CompareTracesOption that clears value of the scope span instrumentation scope version.
func IgnoreScopeSpansOrder ¶
func IgnoreScopeSpansOrder() CompareTracesOption
IgnoreScopeSpansOrder is a CompareTracesOption that ignores the order of instrumentation scope traces/metrics/logs.
func IgnoreSpanAttributeValue ¶ added in v0.88.0
func IgnoreSpanAttributeValue(attributeName string) CompareTracesOption
IgnoreSpanAttributeValue is a CompareTracesOption that clears value of the span attribute.
func IgnoreSpanID ¶ added in v0.88.0
func IgnoreSpanID() CompareTracesOption
IgnoreSpanID is a CompareTracesOption that clears SpanID fields on all spans.
func IgnoreSpansOrder ¶
func IgnoreSpansOrder() CompareTracesOption
IgnoreSpansOrder is a CompareTracesOption that ignores the order of spans.
func IgnoreStartTimestamp ¶ added in v0.88.0
func IgnoreStartTimestamp() CompareTracesOption
IgnoreStartTimestamp is a CompareTracesOption that clears StartTimestamp fields on all spans.
func IgnoreTraceID ¶ added in v0.88.0
func IgnoreTraceID() CompareTracesOption
IgnoreTraceID is a CompareTracesOption that clears TraceID fields on all spans.