Back to

Package mocktrace

Latest Go to latest

The latest major version is .

Published: Jan 20, 2020 | License: MIT | Module:


type MockSpan

type MockSpan struct {
	OperationName string
	FinishErr     error
	Finished      bool
	Tags          []trace.Tag
	Logs          []trace.LogField

MockSpan .

func (*MockSpan) Finish

func (m *MockSpan) Finish(perr *error)

Finish .

func (*MockSpan) Follow

func (m *MockSpan) Follow(serviceName string, operationName string) trace.Trace

Follow .

func (*MockSpan) Fork

func (m *MockSpan) Fork(serviceName string, operationName string) trace.Trace

Fork .

func (*MockSpan) SetLog

func (m *MockSpan) SetLog(logs ...trace.LogField) trace.Trace

SetLog .

func (*MockSpan) SetTag

func (m *MockSpan) SetTag(tags ...trace.Tag) trace.Trace

SetTag .

func (*MockSpan) SetTitle

func (m *MockSpan) SetTitle(title string)

SetTitle .

func (*MockSpan) TraceID

func (m *MockSpan) TraceID() string

TraceID .

func (*MockSpan) Visit

func (m *MockSpan) Visit(fn func(k, v string))

Visit .

type MockTrace

type MockTrace struct {
	Spans []*MockSpan

MockTrace .

func (*MockTrace) Extract

func (m *MockTrace) Extract(format interface{}, carrier interface{}) (trace.Trace, error)

Extract .

func (*MockTrace) Inject

func (m *MockTrace) Inject(t trace.Trace, format interface{}, carrier interface{}) error

Inject .

func (*MockTrace) New

func (m *MockTrace) New(operationName string, opts ...trace.Option) trace.Trace

New .

Package Files

Documentation was rendered with GOOS=linux and GOARCH=amd64.

Jump to identifier

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to identifier