github.com/yandex/pandora@v0.5.32/core/aggregator/netsample/test.go (about) 1 package netsample 2 3 import ( 4 "context" 5 6 "github.com/yandex/pandora/core" 7 ) 8 9 type TestAggregator struct { 10 Samples []*Sample 11 } 12 13 var _ Aggregator = &TestAggregator{} 14 15 func (t *TestAggregator) Run(ctx context.Context, _ core.AggregatorDeps) error { 16 <-ctx.Done() 17 return nil 18 } 19 20 func (t *TestAggregator) Report(s *Sample) { 21 t.Samples = append(t.Samples, s) 22 }