@@ -41,9 +41,7 @@ describe('v8js.memory.heap.max', function () {
4141 instrumentation . setMeterProvider ( meterProvider ) ;
4242
4343 // act
44- await new Promise ( resolve =>
45- setTimeout ( resolve , MEASUREMENT_INTERVAL * 5 )
46- ) ;
44+ await new Promise ( resolve => setTimeout ( resolve , MEASUREMENT_INTERVAL * 5 ) ) ;
4745 const { resourceMetrics, errors } = await metricReader . collect ( ) ;
4846
4947 // assert
@@ -57,7 +55,11 @@ describe('v8js.memory.heap.max', function () {
5755 x => x . descriptor . name === METRIC_V8JS_MEMORY_HEAP_MAX
5856 ) ;
5957
60- assert . notEqual ( metric , undefined , `${ METRIC_V8JS_MEMORY_HEAP_MAX } not found` ) ;
58+ assert . notEqual (
59+ metric ,
60+ undefined ,
61+ `${ METRIC_V8JS_MEMORY_HEAP_MAX } not found`
62+ ) ;
6163
6264 assert . strictEqual (
6365 metric ! . dataPointType ,
@@ -80,9 +82,7 @@ describe('v8js.memory.heap.max', function () {
8082 instrumentation . setMeterProvider ( meterProvider ) ;
8183
8284 // act
83- await new Promise ( resolve =>
84- setTimeout ( resolve , MEASUREMENT_INTERVAL * 5 )
85- ) ;
85+ await new Promise ( resolve => setTimeout ( resolve , MEASUREMENT_INTERVAL * 5 ) ) ;
8686 const { resourceMetrics, errors } = await metricReader . collect ( ) ;
8787
8888 // assert
@@ -92,10 +92,18 @@ describe('v8js.memory.heap.max', function () {
9292 x => x . descriptor . name === METRIC_V8JS_MEMORY_HEAP_MAX
9393 ) ;
9494
95- assert . notEqual ( metric , undefined , `${ METRIC_V8JS_MEMORY_HEAP_MAX } not found` ) ;
95+ assert . notEqual (
96+ metric ,
97+ undefined ,
98+ `${ METRIC_V8JS_MEMORY_HEAP_MAX } not found`
99+ ) ;
96100
97101 if ( metric ! . dataPointType === DataPointType . GAUGE ) {
98- assert . strictEqual ( metric ! . dataPoints . length , 1 , 'expected exactly one data point (global, not per-space)' ) ;
102+ assert . strictEqual (
103+ metric ! . dataPoints . length ,
104+ 1 ,
105+ 'expected exactly one data point (global, not per-space)'
106+ ) ;
99107 const value = metric ! . dataPoints [ 0 ] . value as number ;
100108 assert . ok ( value > 0 , `expected positive heap_size_limit, got ${ value } ` ) ;
101109 }
@@ -109,9 +117,7 @@ describe('v8js.memory.heap.max', function () {
109117 instrumentation . setMeterProvider ( meterProvider ) ;
110118
111119 // act
112- await new Promise ( resolve =>
113- setTimeout ( resolve , MEASUREMENT_INTERVAL * 5 )
114- ) ;
120+ await new Promise ( resolve => setTimeout ( resolve , MEASUREMENT_INTERVAL * 5 ) ) ;
115121 const { resourceMetrics, errors } = await metricReader . collect ( ) ;
116122
117123 // assert
0 commit comments