@@ -15,10 +15,10 @@ const separateBundlePath = path.join(fixtureDir, "separate-directory/bundles/ind
15
15
const separateSourceMapPath = path . join ( fixtureDir , "separate-directory/sourcemaps/index.js.map" ) ;
16
16
const separateBundleContent = fs . readFileSync ( separateBundlePath , "utf-8" ) ;
17
17
18
- const sourceMapUrl = "https://sourcemaps.example.com/foo/index.js.map"
18
+ const sourceMapUrl = "https://sourcemaps.example.com/foo/index.js.map" ;
19
19
20
20
function srcMappingUrl ( url : string ) : string {
21
- return `\n//# sourceMappingURL=${ url } `
21
+ return `\n//# sourceMappingURL=${ url } ` ;
22
22
}
23
23
24
24
describe ( "Resolve source maps" , ( ) => {
@@ -82,7 +82,8 @@ describe("Resolve source maps", () => {
82
82
expect (
83
83
await determineSourceMapPathFromBundle (
84
84
separateBundlePath ,
85
- separateBundleContent + srcMappingUrl ( path . relative ( path . dirname ( separateBundlePath ) , separateSourceMapPath ) ) ,
85
+ separateBundleContent +
86
+ srcMappingUrl ( path . relative ( path . dirname ( separateBundlePath ) , separateSourceMapPath ) ) ,
86
87
logger ,
87
88
undefined
88
89
)
@@ -103,7 +104,7 @@ describe("Resolve source maps", () => {
103
104
} ) ;
104
105
105
106
it ( "should pass the correct values to the resolveSourceMap hook" , async ( ) => {
106
- const hook = jest . fn ( ( ) => separateSourceMapPath )
107
+ const hook = jest . fn ( ( ) => separateSourceMapPath ) ;
107
108
expect (
108
109
await determineSourceMapPathFromBundle (
109
110
separateBundlePath ,
@@ -112,11 +113,11 @@ describe("Resolve source maps", () => {
112
113
hook
113
114
)
114
115
) . toEqual ( separateSourceMapPath ) ;
115
- expect ( hook . mock . calls [ 0 ] ) . toEqual ( [ separateBundlePath , sourceMapUrl ] )
116
+ expect ( hook . mock . calls [ 0 ] ) . toEqual ( [ separateBundlePath , sourceMapUrl ] ) ;
116
117
} ) ;
117
118
118
119
it ( "should pass the correct values to the resolveSourceMap hook when no sourceMappingURL is present" , async ( ) => {
119
- const hook = jest . fn ( ( ) => separateSourceMapPath )
120
+ const hook = jest . fn ( ( ) => separateSourceMapPath ) ;
120
121
expect (
121
122
await determineSourceMapPathFromBundle (
122
123
separateBundlePath ,
@@ -125,7 +126,7 @@ describe("Resolve source maps", () => {
125
126
hook
126
127
)
127
128
) . toEqual ( separateSourceMapPath ) ;
128
- expect ( hook . mock . calls [ 0 ] ) . toEqual ( [ separateBundlePath , undefined ] )
129
+ expect ( hook . mock . calls [ 0 ] ) . toEqual ( [ separateBundlePath , undefined ] ) ;
129
130
} ) ;
130
131
131
132
it ( "should prefer resolveSourceMap result over heuristic results" , async ( ) => {
@@ -161,4 +162,4 @@ describe("Resolve source maps", () => {
161
162
) . toEqual ( adjacentSourceMapPath ) ;
162
163
} ) ;
163
164
} ) ;
164
- } ) ;
165
+ } ) ;
0 commit comments