@@ -435,33 +435,27 @@ describe('Storage', () => {
435435 delete process . env . STORAGE_EMULATOR_HOST ;
436436 } ) ;
437437
438- it ( 'should set baseUrl to env var STORAGE_EMULATOR_HOST plus standard path ' , ( ) => {
438+ it ( 'should set baseUrl to env var STORAGE_EMULATOR_HOST' , ( ) => {
439439 const storage = new Storage ( {
440440 projectId : PROJECT_ID ,
441441 } ) ;
442442
443443 const calledWith = storage . calledWith_ [ 0 ] ;
444- assert . strictEqual ( calledWith . baseUrl , EMULATOR_HOST + '/storage/v1' ) ;
444+ assert . strictEqual ( calledWith . baseUrl , EMULATOR_HOST ) ;
445445 assert . strictEqual (
446446 calledWith . apiEndpoint ,
447447 'https://internal.benchmark.com/path'
448448 ) ;
449449 } ) ;
450450
451- it ( 'should be overridden by apiEndpoint' , ( ) => {
451+ it ( 'should be overriden by apiEndpoint' , ( ) => {
452452 const storage = new Storage ( {
453453 projectId : PROJECT_ID ,
454454 apiEndpoint : 'https://some.api.com' ,
455455 } ) ;
456456
457457 const calledWith = storage . calledWith_ [ 0 ] ;
458- // NOTE: this used to assert partially the opposite of what the test
459- // says: it checked that baseUrl was _not_ overridden, but apiEndpoint
460- // was.
461- assert . strictEqual (
462- calledWith . baseUrl ,
463- 'https://some.api.com/storage/v1'
464- ) ;
458+ assert . strictEqual ( calledWith . baseUrl , EMULATOR_HOST ) ;
465459 assert . strictEqual ( calledWith . apiEndpoint , 'https://some.api.com' ) ;
466460 } ) ;
467461
@@ -474,13 +468,7 @@ describe('Storage', () => {
474468 } ) ;
475469
476470 const calledWith = storage . calledWith_ [ 0 ] ;
477- // NOTE: this used to assert partially the opposite of what the test
478- // says: it checked that baseUrl was _not_ overridden, but apiEndpoint
479- // was.
480- assert . strictEqual (
481- calledWith . baseUrl ,
482- 'https://internal.benchmark.com/path/storage/v1'
483- ) ;
471+ assert . strictEqual ( calledWith . baseUrl , EMULATOR_HOST ) ;
484472 assert . strictEqual (
485473 calledWith . apiEndpoint ,
486474 'https://internal.benchmark.com/path'
0 commit comments