Skip to content

Commit

Permalink
sort extensions when sorting pipelines for testing determinism
Browse files Browse the repository at this point in the history
  • Loading branch information
Canuteson committed Feb 17, 2022
1 parent 56554ea commit fe219ae
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions pkg/traces/config_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1687,7 +1687,9 @@ func sortPipelines(cfg *config.Config) {
var (
exp = tracePipeline.Exporters
recv = tracePipeline.Receivers
ext = cfg.Service.Extensions
)
sort.Slice(exp, func(i, j int) bool { return exp[i].String() > exp[j].String() })
sort.Slice(recv, func(i, j int) bool { return recv[i].String() > recv[j].String() })
sort.Slice(ext, func(i, j int) bool { return ext[i].String() > ext[j].String() })
}

0 comments on commit fe219ae

Please sign in to comment.