diff --git a/src/app/shared/mydspace-actions/workspaceitem/workspaceitem-actions.component.spec.ts b/src/app/shared/mydspace-actions/workspaceitem/workspaceitem-actions.component.spec.ts index f786782c05..b0a08a70bb 100644 --- a/src/app/shared/mydspace-actions/workspaceitem/workspaceitem-actions.component.spec.ts +++ b/src/app/shared/mydspace-actions/workspaceitem/workspaceitem-actions.component.spec.ts @@ -157,6 +157,9 @@ authService = jasmine.createSpyObj('authService', { describe('WorkspaceitemActionsComponent', () => { beforeEach(waitForAsync(async () => { + authorizationService = jasmine.createSpyObj('authorizationService', { + isAuthorized: observableOf(true) + }); await TestBed.configureTestingModule({ imports: [ NgbModule, @@ -190,9 +193,6 @@ describe('WorkspaceitemActionsComponent', () => { component = fixture.componentInstance; component.object = mockObject; notificationsServiceStub = TestBed.inject(NotificationsService as any); - authorizationService = jasmine.createSpyObj('authorizationService', { - isAuthorized: observableOf(true) - }); (authService.getAuthenticatedUserFromStore as jasmine.Spy).and.returnValue(observableOf(ePersonMock)); fixture.detectChanges(); });