Skip to content

Commit e42deea

Browse files
committed
mix format
1 parent 19c0b2d commit e42deea

File tree

1 file changed

+53
-8
lines changed

1 file changed

+53
-8
lines changed

test/otel_metric_tests.exs

Lines changed: 53 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,9 @@ defmodule OtelMetricTests do
1717
@fields Record.extract(:sum, from_lib: "opentelemetry_experimental/include/otel_metrics.hrl")
1818
Record.defrecordp(:sum, @fields)
1919

20-
@fields Record.extract(:histogram, from_lib: "opentelemetry_experimental/include/otel_metrics.hrl")
20+
@fields Record.extract(:histogram,
21+
from_lib: "opentelemetry_experimental/include/otel_metrics.hrl"
22+
)
2123
Record.defrecordp(:histogram, @fields)
2224

2325
setup do
@@ -111,9 +113,31 @@ defmodule OtelMetricTests do
111113
assert_receive {:metric,
112114
metric(
113115
name: :histogram_a,
114-
data: histogram(aggregation_temporality: :temporality_cumulative,
115-
datapoints: [{:histogram_datapoint, %{}, _, _, 1, 1, [0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0],
116-
[0.0, 5.0, 10.0, 25.0, 50.0, 75.0, 100.0, 250.0, 500.0, 750.0, 1000.0, 2500.0, 5000.0, 7500.0, 10000.0], [], 0, 1, 1}])
116+
data:
117+
histogram(
118+
aggregation_temporality: :temporality_cumulative,
119+
datapoints: [
120+
{:histogram_datapoint, %{}, _, _, 1, 1,
121+
[0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0],
122+
[
123+
0.0,
124+
5.0,
125+
10.0,
126+
25.0,
127+
50.0,
128+
75.0,
129+
100.0,
130+
250.0,
131+
500.0,
132+
750.0,
133+
1000.0,
134+
2500.0,
135+
5000.0,
136+
7500.0,
137+
10000.0
138+
], [], 0, 1, 1}
139+
]
140+
)
117141
)}
118142

119143
Histogram.record(:histogram_a, 10)
@@ -123,10 +147,31 @@ defmodule OtelMetricTests do
123147
assert_receive {:metric,
124148
metric(
125149
name: :histogram_a,
126-
data: histogram(aggregation_temporality: :temporality_cumulative,
127-
datapoints: [{:histogram_datapoint, %{}, _, _, 2, 11, [0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0],
128-
[0.0, 5.0, 10.0, 25.0, 50.0, 75.0, 100.0, 250.0, 500.0, 750.0, 1000.0, 2500.0, 5000.0, 7500.0, 10000.0], [], 0, 1, 10}])
150+
data:
151+
histogram(
152+
aggregation_temporality: :temporality_cumulative,
153+
datapoints: [
154+
{:histogram_datapoint, %{}, _, _, 2, 11,
155+
[0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0],
156+
[
157+
0.0,
158+
5.0,
159+
10.0,
160+
25.0,
161+
50.0,
162+
75.0,
163+
100.0,
164+
250.0,
165+
500.0,
166+
750.0,
167+
1000.0,
168+
2500.0,
169+
5000.0,
170+
7500.0,
171+
10000.0
172+
], [], 0, 1, 10}
173+
]
174+
)
129175
)}
130176
end
131-
132177
end

0 commit comments

Comments
 (0)