@@ -10,26 +10,26 @@ describe('findDefaultSdkInitFile', () => {
10
10
} ) ;
11
11
12
12
it . each ( [ 'ts' , 'js' , 'mjs' , 'cjs' , 'mts' , 'cts' ] ) (
13
- 'should return the server file with .%s extension if it exists' ,
13
+ 'should return the server file path with .%s extension if it exists' ,
14
14
ext => {
15
15
vi . spyOn ( fs , 'existsSync' ) . mockImplementation ( filePath => {
16
16
return ! ( filePath instanceof URL ) && filePath . includes ( `sentry.server.config.${ ext } ` ) ;
17
17
} ) ;
18
18
19
19
const result = findDefaultSdkInitFile ( 'server' ) ;
20
- expect ( result ) . toBe ( ` sentry.server.config.${ ext } `) ;
20
+ expect ( result ) . toMatch ( `packages/nuxt/ sentry.server.config.${ ext } `) ;
21
21
} ,
22
22
) ;
23
23
24
24
it . each ( [ 'ts' , 'js' , 'mjs' , 'cjs' , 'mts' , 'cts' ] ) (
25
- 'should return the client file with .%s extension if it exists' ,
25
+ 'should return the client file path with .%s extension if it exists' ,
26
26
ext => {
27
27
vi . spyOn ( fs , 'existsSync' ) . mockImplementation ( filePath => {
28
28
return ! ( filePath instanceof URL ) && filePath . includes ( `sentry.client.config.${ ext } ` ) ;
29
29
} ) ;
30
30
31
31
const result = findDefaultSdkInitFile ( 'client' ) ;
32
- expect ( result ) . toBe ( ` sentry.client.config.${ ext } `) ;
32
+ expect ( result ) . toMatch ( `packages/nuxt/ sentry.client.config.${ ext } `) ;
33
33
} ,
34
34
) ;
35
35
@@ -47,7 +47,7 @@ describe('findDefaultSdkInitFile', () => {
47
47
expect ( result ) . toBeUndefined ( ) ;
48
48
} ) ;
49
49
50
- it ( 'should return the server config file if server.config and instrument exist' , ( ) => {
50
+ it ( 'should return the server config file path if server.config and instrument exist' , ( ) => {
51
51
vi . spyOn ( fs , 'existsSync' ) . mockImplementation ( filePath => {
52
52
return (
53
53
! ( filePath instanceof URL ) &&
@@ -56,6 +56,6 @@ describe('findDefaultSdkInitFile', () => {
56
56
} ) ;
57
57
58
58
const result = findDefaultSdkInitFile ( 'server' ) ;
59
- expect ( result ) . toBe ( ' sentry.server.config.js') ;
59
+ expect ( result ) . toMatch ( 'packages/nuxt/ sentry.server.config.js') ;
60
60
} ) ;
61
61
} ) ;
0 commit comments