@@ -400,11 +400,12 @@ public function testRefreshTokenValidAppToken() {
400400 $ this ->accessTokenMapper ->expects ($ this ->once ())
401401 ->method ('rotateToken ' )
402402 ->with (
403- $ this ->callback (function (AccessToken $ token ) {
404- return $ token ->getHashedCode () === hash ('sha512 ' , 'random128 ' ) &&
405- $ token ->getEncryptedToken () === 'newEncryptedToken ' ;
406- })
407- );
403+ 21 ,
404+ 'validrefresh ' ,
405+ 'random128 ' ,
406+ 'newEncryptedToken ' ,
407+ false ,
408+ )->willReturn (1 );
408409
409410 $ expected = new JSONResponse ([
410411 'access_token ' => 'random72 ' ,
@@ -509,11 +510,12 @@ public function testRefreshTokenValidAppTokenBasicAuth() {
509510 $ this ->accessTokenMapper ->expects ($ this ->once ())
510511 ->method ('rotateToken ' )
511512 ->with (
512- $ this ->callback (function (AccessToken $ token ) {
513- return $ token ->getHashedCode () === hash ('sha512 ' , 'random128 ' ) &&
514- $ token ->getEncryptedToken () === 'newEncryptedToken ' ;
515- })
516- );
513+ 21 ,
514+ 'validrefresh ' ,
515+ 'random128 ' ,
516+ 'newEncryptedToken ' ,
517+ false ,
518+ )->willReturn (1 );
517519
518520 $ expected = new JSONResponse ([
519521 'access_token ' => 'random72 ' ,
@@ -621,11 +623,12 @@ public function testRefreshTokenExpiredAppToken() {
621623 $ this ->accessTokenMapper ->expects ($ this ->once ())
622624 ->method ('rotateToken ' )
623625 ->with (
624- $ this ->callback (function (AccessToken $ token ) {
625- return $ token ->getHashedCode () === hash ('sha512 ' , 'random128 ' ) &&
626- $ token ->getEncryptedToken () === 'newEncryptedToken ' ;
627- })
628- );
626+ 21 ,
627+ 'validrefresh ' ,
628+ 'random128 ' ,
629+ 'newEncryptedToken ' ,
630+ false ,
631+ )->willReturn (1 );
629632
630633 $ expected = new JSONResponse ([
631634 'access_token ' => 'random72 ' ,
0 commit comments