@@ -17,8 +17,10 @@ import PingType from "../../../src/core/pings";
1717const sandbox = sinon . createSandbox ( ) ;
1818
1919describe ( "LabeledMetric" , function ( ) {
20+ const testAppId = `gleanjs.test.${ this . title } ` ;
21+
2022 beforeEach ( async function ( ) {
21- await Glean . testResetGlean ( "gleanjs.unit.test" ) ;
23+ await Glean . testResetGlean ( testAppId ) ;
2224 // Disable ping uploading for it not to interfere with this tests.
2325 sandbox . stub ( Glean [ "pingUploader" ] , "triggerUpload" ) . callsFake ( ( ) => Promise . resolve ( ) ) ;
2426 } ) ;
@@ -34,7 +36,7 @@ describe("LabeledMetric", function() {
3436 sendIfEmpty : false ,
3537 } ) ;
3638
37- const labeledCounterMetric = new LabeledMetricType < CounterMetricType > (
39+ const labeledCounterMetric = new LabeledMetricType (
3840 {
3941 category : "telemetry" ,
4042 name : "labeled_counter_metric" ,
@@ -79,7 +81,7 @@ describe("LabeledMetric", function() {
7981 sendIfEmpty : false ,
8082 } ) ;
8183
82- const labeledCounterMetric = new LabeledMetricType < CounterMetricType > (
84+ const labeledCounterMetric = new LabeledMetricType (
8385 {
8486 category : "telemetry" ,
8587 name : "labeled_counter_metric" ,
@@ -126,7 +128,7 @@ describe("LabeledMetric", function() {
126128 } ) ;
127129
128130 it ( "test __other__ label without predefined labels" , async function ( ) {
129- const labeledCounterMetric = new LabeledMetricType < CounterMetricType > (
131+ const labeledCounterMetric = new LabeledMetricType (
130132 {
131133 category : "telemetry" ,
132134 name : "labeled_counter_metric" ,
@@ -151,7 +153,7 @@ describe("LabeledMetric", function() {
151153 } ) ;
152154
153155 it ( "test __other__ label without predefined labels before Glean initialization" , async function ( ) {
154- const labeledCounterMetric = new LabeledMetricType < CounterMetricType > (
156+ const labeledCounterMetric = new LabeledMetricType (
155157 {
156158 category : "telemetry" ,
157159 name : "labeled_counter_metric" ,
@@ -181,7 +183,7 @@ describe("LabeledMetric", function() {
181183 } ) ;
182184
183185 it ( "Ensure invalid labels on labeled counter go to __other__" , async function ( ) {
184- const labeledCounterMetric = new LabeledMetricType < CounterMetricType > (
186+ const labeledCounterMetric = new LabeledMetricType (
185187 {
186188 category : "telemetry" ,
187189 name : "labeled_counter_metric" ,
@@ -203,7 +205,7 @@ describe("LabeledMetric", function() {
203205 } ) ;
204206
205207 it ( "Ensure invalid labels on labeled boolean go to __other__" , async function ( ) {
206- const labeledBooleanMetric = new LabeledMetricType < BooleanMetricType > (
208+ const labeledBooleanMetric = new LabeledMetricType (
207209 {
208210 category : "telemetry" ,
209211 name : "labeled_boolean_metric" ,
@@ -225,7 +227,7 @@ describe("LabeledMetric", function() {
225227 } ) ;
226228
227229 it ( "Ensure invalid labels on labeled string go to __other__" , async function ( ) {
228- const labeledStringMetric = new LabeledMetricType < StringMetricType > (
230+ const labeledStringMetric = new LabeledMetricType (
229231 {
230232 category : "telemetry" ,
231233 name : "labeled_string_metric" ,
@@ -247,7 +249,7 @@ describe("LabeledMetric", function() {
247249 } ) ;
248250
249251 it ( "test labeled string metric type" , async function ( ) {
250- const labeledStringMetric = new LabeledMetricType < StringMetricType > (
252+ const labeledStringMetric = new LabeledMetricType (
251253 {
252254 category : "telemetry" ,
253255 name : "labeled_string_metric" ,
@@ -269,7 +271,7 @@ describe("LabeledMetric", function() {
269271 } ) ;
270272
271273 it ( "test labeled boolean metric type" , async function ( ) {
272- const metric = new LabeledMetricType < BooleanMetricType > (
274+ const metric = new LabeledMetricType (
273275 {
274276 category : "telemetry" ,
275277 name : "labeled_bool" ,
@@ -291,7 +293,7 @@ describe("LabeledMetric", function() {
291293 } ) ;
292294
293295 it ( "dynamic labels regex mismatch" , async function ( ) {
294- const labeledCounterMetric = new LabeledMetricType < CounterMetricType > (
296+ const labeledCounterMetric = new LabeledMetricType (
295297 {
296298 category : "telemetry" ,
297299 name : "labeled_counter_metric" ,
@@ -320,7 +322,7 @@ describe("LabeledMetric", function() {
320322 } ) ;
321323
322324 it ( "dynamic labels regex allowed" , async function ( ) {
323- const labeledCounterMetric = new LabeledMetricType < CounterMetricType > (
325+ const labeledCounterMetric = new LabeledMetricType (
324326 {
325327 category : "telemetry" ,
326328 name : "labeled_counter_metric" ,
@@ -350,7 +352,7 @@ describe("LabeledMetric", function() {
350352 } ) ;
351353
352354 it ( "seen labels get reloaded across initializations" , async function ( ) {
353- const labeledCounterMetric = new LabeledMetricType < CounterMetricType > (
355+ const labeledCounterMetric = new LabeledMetricType (
354356 {
355357 category : "telemetry" ,
356358 name : "labeled_metric" ,
0 commit comments