File tree Expand file tree Collapse file tree 1 file changed +7
-4
lines changed
packages/core/src/test/credentials Expand file tree Collapse file tree 1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -529,12 +529,15 @@ describe('Auth', function () {
529529 const newCreds = { ...initialCreds , accessKey : 'y' , secretKey : 'y' }
530530 await UserCredentialsUtils . generateCredentialsFile ( newCreds )
531531 const contentAfter = await fs . readFileText ( getCredentialsFilename ( ) )
532- const statAfter = await fs . stat ( getCredentialsFilename ( ) )
533532
534- assert . ok ( contentBefore !== contentAfter )
533+ assert . notDeepStrictEqual ( contentBefore , contentAfter )
535534
536- await waitUntil ( async ( ) => statBefore !== ( await fs . stat ( getCredentialsFilename ( ) ) ) , { timeout : 5000 } )
537- assert . notDeepStrictEqual ( statBefore , statAfter , 'Credentials file update failed' )
535+ const updated = await waitUntil ( async ( ) => statBefore !== ( await fs . stat ( getCredentialsFilename ( ) ) ) , {
536+ timeout : 20000 ,
537+ interval : 1000 ,
538+ truthy : true ,
539+ } )
540+ assert . ok ( updated , 'Credentials file update failed' )
538541
539542 assert . deepStrictEqual ( await conn . getCredentials ( ) , {
540543 accessKeyId : newCreds . accessKey ,
You can’t perform that action at this time.
0 commit comments