@@ -29,21 +29,18 @@ import { Endpoint } from '../../api';
2929import { UserInternal } from '../../model/user' ;
3030import { _castAuth } from './auth_impl' ;
3131import { connectAuthEmulator } from './emulator' ;
32- import { FetchProvider } from '../util/fetch_provider' ;
3332
3433use ( sinonChai ) ;
3534use ( chaiAsPromised ) ;
3635
37- describe . only ( 'core/auth/emulator' , ( ) => {
36+ describe ( 'core/auth/emulator' , ( ) => {
3837 let auth : TestAuth ;
3938 let user : UserInternal ;
4039 let normalEndpoint : fetch . Route ;
4140 let emulatorEndpoint : fetch . Route ;
42- let spy : sinon . SinonSpy ;
4341
4442 beforeEach ( async ( ) => {
4543 auth = await testAuth ( ) ;
46- spy = sinon . spy ( FetchProvider . fetch ( ) ) ;
4744 user = testUser ( _castAuth ( auth ) , 'uid' , 'email' , true ) ;
4845 fetch . setUp ( ) ;
4946 normalEndpoint = mockEndpoint ( Endpoint . DELETE_ACCOUNT , { } ) ;
@@ -96,33 +93,6 @@ describe.only('core/auth/emulator', () => {
9693 'auth/emulator-config-failed'
9794 ) ;
9895 } ) ;
99- it . only ( 'sends the proper value' , async ( ) => {
100- expect ( ( ) => connectAuthEmulator ( auth , 'http://127.0.0.1:2020' ) ) . to . not
101- . throw ;
102- await user . delete ( ) ;
103- expect ( spy ) . to . have . been . called ;
104- expect ( ( ) => connectAuthEmulator ( auth , 'http://127.0.0.1:2021' ) ) . to . throw (
105- FirebaseError ,
106- 'auth/emulator-config-failed'
107- ) ;
108- } ) ;
109-
110- it ( 'subsequent calls update the endpoint appropriately' , async ( ) => {
111- connectAuthEmulator ( auth , 'http://127.0.0.1:2021' ) ;
112- expect ( auth . emulatorConfig ) . to . eql ( {
113- protocol : 'http' ,
114- host : '127.0.0.1' ,
115- port : 2021 ,
116- options : { disableWarnings : false }
117- } ) ;
118- connectAuthEmulator ( auth , 'http://127.0.0.1:2020' ) ;
119- expect ( auth . emulatorConfig ) . to . eql ( {
120- protocol : 'http' ,
121- host : '127.0.0.1' ,
122- port : 2020 ,
123- options : { disableWarnings : false }
124- } ) ;
125- } ) ;
12696
12797 it ( 'subsequent calls update the endpoint appropriately' , async ( ) => {
12898 connectAuthEmulator ( auth , 'http://127.0.0.1:2021' ) ;
0 commit comments