@@ -67,7 +67,7 @@ describe('uploadcareLoader', () => {
6767
6868 const t = ( ) => {
6969 uploadcareLoader ( {
70- src : '' ,
70+ src : 'https://example.com ' ,
7171 width : 0 ,
7272 quality : 80
7373 } ) ;
@@ -95,7 +95,7 @@ describe('uploadcareLoader', () => {
9595 } ) ;
9696
9797 test ( 'The loader parses user paramters properly' , ( ) => {
98- const src = 'https:/example.com/image.jpg' ;
98+ const src = 'https:// example.com/image.jpg' ;
9999
100100 addEnvVar ( 'NEXT_PUBLIC_UPLOADCARE_PUBLIC_KEY' , 'test-public-key' ) ;
101101
@@ -108,7 +108,7 @@ describe('uploadcareLoader', () => {
108108 } ) ;
109109
110110 expect ( result ) . toBe (
111- 'https://test-public-key.ucr.io/-/format/auto/-/stretch/off/-/progressive/yes/-/resize/500x/-/quality/normal/https:/example.com/image.jpg'
111+ 'https://test-public-key.ucr.io/-/format/auto/-/stretch/off/-/progressive/yes/-/resize/500x/-/quality/normal/https:// example.com/image.jpg'
112112 ) ;
113113
114114 // Override default params, including resize and quality.
@@ -125,7 +125,7 @@ describe('uploadcareLoader', () => {
125125 } ) ;
126126
127127 expect ( result ) . toBe (
128- 'https://test-public-key.ucr.io/-/format/jpg/-/stretch/on/-/progressive/no/-/resize/1x/-/quality/smart_retina/https:/example.com/image.jpg'
128+ 'https://test-public-key.ucr.io/-/format/jpg/-/stretch/on/-/progressive/no/-/resize/1x/-/quality/smart_retina/https:// example.com/image.jpg'
129129 ) ;
130130
131131 // Add a new parameter (no defaults).
@@ -142,15 +142,15 @@ describe('uploadcareLoader', () => {
142142 } ) ;
143143
144144 expect ( result ) . toBe (
145- 'https://test-public-key.ucr.io/-/format/auto/-/stretch/off/-/progressive/yes/-/resize/500x/-/quality/normal/-/new/parameter/https:/example.com/image.jpg'
145+ 'https://test-public-key.ucr.io/-/format/auto/-/stretch/off/-/progressive/yes/-/resize/500x/-/quality/normal/-/new/parameter/https:// example.com/image.jpg'
146146 ) ;
147147
148148 removeEnvVar ( 'NEXT_PUBLIC_UPLOADCARE_PUBLIC_KEY' ) ;
149149 removeEnvVar ( 'NEXT_PUBLIC_UPLOADCARE_TRANSFORMATION_PARAMETERS' ) ;
150150 } ) ;
151151
152152 test ( "The loader doesn't process SVG and GIF (absolute url)" , ( ) => {
153- const src = 'https:/example.com/image.svg' ;
153+ const src = 'https:// example.com/image.svg' ;
154154
155155 addEnvVar ( 'NEXT_PUBLIC_UPLOADCARE_PUBLIC_KEY' , 'test-public-key' ) ;
156156
@@ -242,7 +242,7 @@ describe('uploadcareLoader', () => {
242242
243243 // Not a jpg image. Should be max 3000 width.
244244
245- let src = 'https:/example.com/image.png' ;
245+ let src = 'https:// example.com/image.png' ;
246246
247247 addEnvVar (
248248 'NEXT_PUBLIC_UPLOADCARE_TRANSFORMATION_PARAMETERS' ,
@@ -256,7 +256,7 @@ describe('uploadcareLoader', () => {
256256 } ) ;
257257
258258 expect ( result ) . toBe (
259- 'https://test-public-key.ucr.io/-/format/auto/-/stretch/off/-/progressive/yes/-/resize/3000x/-/quality/normal/https:/example.com/image.png'
259+ 'https://test-public-key.ucr.io/-/format/auto/-/stretch/off/-/progressive/yes/-/resize/3000x/-/quality/normal/https:// example.com/image.png'
260260 ) ;
261261
262262 // Jpg image by format. Should be max 5000 width.
@@ -273,13 +273,13 @@ describe('uploadcareLoader', () => {
273273 } ) ;
274274
275275 expect ( result ) . toBe (
276- 'https://test-public-key.ucr.io/-/format/jpeg/-/stretch/off/-/progressive/yes/-/resize/5000x/-/quality/normal/https:/example.com/image.png'
276+ 'https://test-public-key.ucr.io/-/format/jpeg/-/stretch/off/-/progressive/yes/-/resize/5000x/-/quality/normal/https:// example.com/image.png'
277277 ) ;
278278
279279 // // Jpg image by extension with auto format.
280280 // // Should be max 5000 width with /format/jpeg/ forced.
281281
282- src = 'https:/example.com/image.jpg' ;
282+ src = 'https:// example.com/image.jpg' ;
283283
284284 addEnvVar (
285285 'NEXT_PUBLIC_UPLOADCARE_TRANSFORMATION_PARAMETERS' ,
@@ -293,7 +293,7 @@ describe('uploadcareLoader', () => {
293293 } ) ;
294294
295295 expect ( result ) . toBe (
296- 'https://test-public-key.ucr.io/-/format/jpeg/-/stretch/off/-/progressive/yes/-/resize/5000x/-/quality/normal/https:/example.com/image.jpg'
296+ 'https://test-public-key.ucr.io/-/format/jpeg/-/stretch/off/-/progressive/yes/-/resize/5000x/-/quality/normal/https:// example.com/image.jpg'
297297 ) ;
298298
299299 removeEnvVar ( 'NEXT_PUBLIC_UPLOADCARE_PUBLIC_KEY' ) ;
0 commit comments