@@ -163,7 +163,7 @@ describe('internal api', () => {
163
163
const error = new Error ( 'oops, something went wrong' ) ;
164
164
stub ( client , 'exchangeToken' ) . returns ( Promise . reject ( error ) ) ;
165
165
166
- const token = await getToken ( appCheck as AppCheckService ) ;
166
+ const token = await getToken ( appCheck as AppCheckService , false , true ) ;
167
167
168
168
expect ( reCAPTCHASpy ) . to . be . called ;
169
169
expect ( token ) . to . deep . equal ( {
@@ -186,7 +186,7 @@ describe('internal api', () => {
186
186
const error = new Error ( 'oops, something went wrong' ) ;
187
187
stub ( client , 'exchangeToken' ) . returns ( Promise . reject ( error ) ) ;
188
188
189
- const token = await getToken ( appCheck as AppCheckService ) ;
189
+ const token = await getToken ( appCheck as AppCheckService , false , true ) ;
190
190
191
191
expect ( token ) . to . deep . equal ( {
192
192
token : formatDummyToken ( defaultTokenErrorData ) ,
@@ -208,7 +208,7 @@ describe('internal api', () => {
208
208
const reCAPTCHASpy = stubGetRecaptchaToken ( '' , false ) ;
209
209
const exchangeTokenStub = stub ( client , 'exchangeToken' ) ;
210
210
211
- const token = await getToken ( appCheck as AppCheckService ) ;
211
+ const token = await getToken ( appCheck as AppCheckService , false , true ) ;
212
212
213
213
expect ( reCAPTCHASpy ) . to . be . called ;
214
214
expect ( exchangeTokenStub ) . to . not . be . called ;
@@ -290,7 +290,6 @@ describe('internal api', () => {
290
290
} ) ;
291
291
292
292
it ( 'calls 3P error handler if there is an error getting a token' , async ( ) => {
293
- stub ( console , 'error' ) ;
294
293
const appCheck = initializeAppCheck ( app , {
295
294
provider : new ReCaptchaV3Provider ( FAKE_SITE_KEY ) ,
296
295
isTokenAutoRefreshEnabled : true
@@ -314,7 +313,6 @@ describe('internal api', () => {
314
313
} ) ;
315
314
316
315
it ( 'ignores listeners that throw' , async ( ) => {
317
- stub ( console , 'error' ) ;
318
316
const appCheck = initializeAppCheck ( app , {
319
317
provider : new ReCaptchaV3Provider ( FAKE_SITE_KEY ) ,
320
318
isTokenAutoRefreshEnabled : true
0 commit comments