@@ -438,22 +438,37 @@ describe('openSenseMap API Routes: /users', function () {
438438 } ) ;
439439
440440 it ( 'should allow to refresh jwt using the refresh token' , function ( ) {
441- return chakram . post ( `${ BASE_URL } /users/refresh-auth` , { 'token' : refreshToken } )
441+ return chakram
442+ . post (
443+ `${ BASE_URL } /users/refresh-auth` ,
444+ { token : refreshToken }
445+ )
442446 . then ( function ( response ) {
443447 expect ( response ) . to . have . status ( 200 ) ;
444- expect ( response ) . to . have . header ( 'content-type' , 'application/json; charset=utf-8' ) ;
448+ expect ( response ) . to . have . header (
449+ 'content-type' ,
450+ 'application/json; charset=utf-8'
451+ ) ;
445452 expect ( response . body . token ) . to . exist ;
446453 expect ( response . body . refreshToken ) . to . exist ;
447454
448455 const jwt = response . body . token ;
449456
450- return chakram . get ( `${ BASE_URL } /users/me` , { headers : { 'Authorization' : `Bearer ${ jwt } ` } } ) ;
457+ return chakram . get ( `${ BASE_URL } /users/me` , {
458+ headers : { Authorization : `Bearer ${ jwt } ` }
459+ } ) ;
451460 } )
452461 . then ( function ( response ) {
453462 expect ( response ) . to . have . status ( 200 ) ;
454- expect ( response ) . to . have . header ( 'content-type' , 'application/json; charset=utf-8' ) ;
463+ expect ( response ) . to . have . header (
464+ 'content-type' ,
465+ 'application/json; charset=utf-8'
466+ ) ;
455467 expect ( response ) . to . have . schema ( getUserSchema ) ;
456- expect ( response ) . to . comprise . of . json ( { code :
'Ok' , data :
{ me :
{ email :
'[email protected] ' } } } ) ; 468+ expect ( response ) . to . comprise . of . json ( {
469+ code : 'Ok' ,
470+ data :
{ me :
{ email :
'[email protected] ' } } 471+ } ) ;
457472
458473 return chakram . wait ( ) ;
459474 } ) ;
0 commit comments