@@ -7,10 +7,8 @@ import { RouterTestingModule } from '@angular/router/testing';
77import { RouterAuthService } from 'src/app/core/services/router-auth.service' ;
88import { AuthService } from 'src/app/core/services/auth.service' ;
99import { TrackingService } from 'src/app/core/services/tracking.service' ;
10- import { of , throwError } from 'rxjs' ;
10+ import { of } from 'rxjs' ;
1111import { apiEouRes } from 'src/app/core/mock-data/extended-org-user.data' ;
12- import { getElementBySelector , getTextContent } from 'src/app/core/dom-helpers' ;
13- import { VerifyPageState } from './verify.enum' ;
1412import { UserEventService } from 'src/app/core/services/user-event.service' ;
1513
1614describe ( 'VerifyPage' , ( ) => {
@@ -25,7 +23,7 @@ describe('VerifyPage', () => {
2523 beforeEach ( waitForAsync ( ( ) => {
2624 const routerSpy = jasmine . createSpyObj ( 'Router' , [ 'navigate' ] ) ;
2725 const routerAuthServiceSpy = jasmine . createSpyObj ( 'RouterAuthService' , [ 'emailVerify' ] ) ;
28- const authServiceSpy = jasmine . createSpyObj ( 'AuthService' , [ 'newRefreshToken ' ] ) ;
26+ const authServiceSpy = jasmine . createSpyObj ( 'AuthService' , [ 'refreshEou ' ] ) ;
2927 const trackingServiceSpy = jasmine . createSpyObj ( 'TrackingService' , [ 'emailVerified' , 'onSignin' ] ) ;
3028 const userEventServiceSpy = jasmine . createSpyObj ( 'UserEventService' , [ 'logout' ] ) ;
3129
@@ -81,7 +79,7 @@ describe('VerifyPage', () => {
8179 it ( 'should navigate to switch_org route when verification is successful' , ( ) => {
8280 const mockResponse = { refresh_token : 'xyz123' } ;
8381 routerAuthService . emailVerify . and . returnValue ( of ( mockResponse ) ) ;
84- authService . newRefreshToken . and . returnValue ( of ( apiEouRes ) ) ;
82+ authService . refreshEou . and . returnValue ( of ( apiEouRes ) ) ;
8583 fixture . detectChanges ( ) ;
8684 expect ( trackingService . emailVerified ) . toHaveBeenCalledTimes ( 1 ) ;
8785 expect ( trackingService . onSignin ) . toHaveBeenCalledOnceWith ( '[email protected] ' ) ;
0 commit comments