@@ -251,9 +251,8 @@ describe('init', () => {
251251 globalThis . process = {
252252 env : {
253253 SENTRY_SPOTLIGHT : 'true' ,
254- } ,
255- // eslint-disable-next-line @typescript-eslint/no-explicit-any
256- } as any ;
254+ } as Record < string , string > ,
255+ } as NodeJS . Process ;
257256
258257 // @ts -expect-error this is fine for testing
259258 const initAndBindSpy = vi . spyOn ( SentryCore , 'initAndBind' ) . mockImplementationOnce ( ( ) => { } ) ;
@@ -271,9 +270,8 @@ describe('init', () => {
271270 globalThis . process = {
272271 env : {
273272 SENTRY_SPOTLIGHT : 'false' ,
274- } ,
275- // eslint-disable-next-line @typescript-eslint/no-explicit-any
276- } as any ;
273+ } as Record < string , string > ,
274+ } as NodeJS . Process ;
277275
278276 // @ts -expect-error this is fine for testing
279277 const initAndBindSpy = vi . spyOn ( SentryCore , 'initAndBind' ) . mockImplementationOnce ( ( ) => { } ) ;
@@ -291,9 +289,8 @@ describe('init', () => {
291289 globalThis . process = {
292290 env : {
293291 SENTRY_SPOTLIGHT : 'true' ,
294- } ,
295- // eslint-disable-next-line @typescript-eslint/no-explicit-any
296- } as any ;
292+ } as Record < string , string > ,
293+ } as NodeJS . Process ;
297294
298295 // @ts -expect-error this is fine for testing
299296 const initAndBindSpy = vi . spyOn ( SentryCore , 'initAndBind' ) . mockImplementationOnce ( ( ) => { } ) ;
@@ -312,9 +309,8 @@ describe('init', () => {
312309 globalThis . process = {
313310 env : {
314311 SENTRY_SPOTLIGHT : 'http://env:5678/stream' ,
315- } ,
316- // eslint-disable-next-line @typescript-eslint/no-explicit-any
317- } as any ;
312+ } as Record < string , string > ,
313+ } as NodeJS . Process ;
318314
319315 // @ts -expect-error this is fine for testing
320316 const initAndBindSpy = vi . spyOn ( SentryCore , 'initAndBind' ) . mockImplementationOnce ( ( ) => { } ) ;
@@ -332,9 +328,8 @@ describe('init', () => {
332328 globalThis . process = {
333329 env : {
334330 SENTRY_SPOTLIGHT : 'http://env:5678/stream' ,
335- } ,
336- // eslint-disable-next-line @typescript-eslint/no-explicit-any
337- } as any ;
331+ } as Record < string , string > ,
332+ } as NodeJS . Process ;
338333
339334 // @ts -expect-error this is fine for testing
340335 const initAndBindSpy = vi . spyOn ( SentryCore , 'initAndBind' ) . mockImplementationOnce ( ( ) => { } ) ;
@@ -347,23 +342,22 @@ describe('init', () => {
347342 expect ( spotlightIntegration ) . toBeDefined ( ) ;
348343 } ) ;
349344
350- it ( 'respects priority order: SENTRY_SPOTLIGHT over PUBLIC_SENTRY_SPOTLIGHT ' , ( ) => {
345+ it ( 'respects priority order: PUBLIC_SENTRY_SPOTLIGHT over SENTRY_SPOTLIGHT ' , ( ) => {
351346 originalProcess = globalThis . process ;
352347 globalThis . process = {
353348 env : {
354- SENTRY_SPOTLIGHT : 'true' ,
355- PUBLIC_SENTRY_SPOTLIGHT : 'false' ,
356- } ,
357- // eslint-disable-next-line @typescript-eslint/no-explicit-any
358- } as any ;
349+ PUBLIC_SENTRY_SPOTLIGHT : 'true' ,
350+ SENTRY_SPOTLIGHT : 'false' ,
351+ } as Record < string , string > ,
352+ } as NodeJS . Process ;
359353
360354 // @ts -expect-error this is fine for testing
361355 const initAndBindSpy = vi . spyOn ( SentryCore , 'initAndBind' ) . mockImplementationOnce ( ( ) => { } ) ;
362356 const options = getDefaultBrowserOptions ( { dsn : PUBLIC_DSN , spotlight : undefined } ) ;
363357 init ( options ) ;
364358
365359 const optionsPassed = initAndBindSpy . mock . calls [ 0 ] ?. [ 1 ] ;
366- // Spotlight integration should be added (SENTRY_SPOTLIGHT =true wins)
360+ // Spotlight integration should be added (PUBLIC_SENTRY_SPOTLIGHT =true wins)
367361 const spotlightIntegration = optionsPassed ?. integrations . find ( ( i : Integration ) => i . name === 'SpotlightBrowser' ) ;
368362 expect ( spotlightIntegration ) . toBeDefined ( ) ;
369363 } ) ;
@@ -373,9 +367,8 @@ describe('init', () => {
373367 globalThis . process = {
374368 env : {
375369 NEXT_PUBLIC_SENTRY_SPOTLIGHT : 'true' ,
376- } ,
377- // eslint-disable-next-line @typescript-eslint/no-explicit-any
378- } as any ;
370+ } as Record < string , string > ,
371+ } as NodeJS . Process ;
379372
380373 // @ts -expect-error this is fine for testing
381374 const initAndBindSpy = vi . spyOn ( SentryCore , 'initAndBind' ) . mockImplementationOnce ( ( ) => { } ) ;
0 commit comments