Skip to content

Commit

Permalink
fix some more
Browse files Browse the repository at this point in the history
  • Loading branch information
atoulme committed Jan 12, 2025
1 parent 3fe97f1 commit b234edf
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions tests/general/container_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -237,16 +237,17 @@ func TestNonDefaultGIDCanAccessJavaInAgentBundle(t *testing.T) {
}

metricsFound := map[string]struct{}{}
m := tc.OTLPReceiverSink.AllMetrics()[len(tc.OTLPReceiverSink.AllMetrics())-1]
for i := 0; i < m.ResourceMetrics().Len(); i++ {
rm := m.ResourceMetrics().At(i)
for j := 0; j < rm.ScopeMetrics().Len(); j++ {
sm := rm.ScopeMetrics().At(j)
for k := 0; k < sm.Metrics().Len(); k++ {
metric := sm.Metrics().At(k)
for _, m := range tc.OTLPReceiverSink.AllMetrics() {
for i := 0; i < m.ResourceMetrics().Len(); i++ {
rm := m.ResourceMetrics().At(i)
for j := 0; j < rm.ScopeMetrics().Len(); j++ {
sm := rm.ScopeMetrics().At(j)
for k := 0; k < sm.Metrics().Len(); k++ {
metric := sm.Metrics().At(k)

if metric.Name() == "counter.amq.TotalConnectionsCount" || metric.Name() == "jmx_memory.committed" {
metricsFound[metric.Name()] = struct{}{}
if metric.Name() == "counter.amq.TotalConnectionsCount" || metric.Name() == "jmx_memory.committed" {
metricsFound[metric.Name()] = struct{}{}
}
}
}
}
Expand Down

0 comments on commit b234edf

Please sign in to comment.