diff --git a/src/app/community-page/sections/sub-com-col-section/sub-com-col-section.component.spec.ts b/src/app/community-page/sections/sub-com-col-section/sub-com-col-section.component.spec.ts index 818ea9365a..101159c4fa 100644 --- a/src/app/community-page/sections/sub-com-col-section/sub-com-col-section.component.spec.ts +++ b/src/app/community-page/sections/sub-com-col-section/sub-com-col-section.component.spec.ts @@ -14,7 +14,7 @@ describe('SubComColSectionComponent', () => { activatedRoute.parent = new ActivatedRouteStub(); await TestBed.configureTestingModule({ - declarations: [SubComColSectionComponent], + imports: [SubComColSectionComponent], providers: [ { provide: ActivatedRoute, useValue: activatedRoute }, ] diff --git a/src/app/core/coar-notify/notify-info/notify-info.component.spec.ts b/src/app/core/coar-notify/notify-info/notify-info.component.spec.ts index fbb200b9ab..666b808122 100644 --- a/src/app/core/coar-notify/notify-info/notify-info.component.spec.ts +++ b/src/app/core/coar-notify/notify-info/notify-info.component.spec.ts @@ -14,8 +14,7 @@ describe('NotifyInfoComponent', () => { notifyInfoServiceSpy = jasmine.createSpyObj('NotifyInfoService', ['getCoarLdnLocalInboxUrls']); await TestBed.configureTestingModule({ - imports: [TranslateModule.forRoot()], - declarations: [NotifyInfoComponent], + imports: [TranslateModule.forRoot(), NotifyInfoComponent], providers: [ { provide: NotifyInfoService, useValue: notifyInfoServiceSpy } ] diff --git a/src/app/item-page/simple/notify-requests-status/notify-requests-status-component/notify-requests-status.component.spec.ts b/src/app/item-page/simple/notify-requests-status/notify-requests-status-component/notify-requests-status.component.spec.ts index b3c3c2ce0e..3263830b9d 100644 --- a/src/app/item-page/simple/notify-requests-status/notify-requests-status-component/notify-requests-status.component.spec.ts +++ b/src/app/item-page/simple/notify-requests-status/notify-requests-status-component/notify-requests-status.component.spec.ts @@ -21,8 +21,7 @@ describe('NotifyRequestsStatusComponent', () => { getNotifyRequestsStatus:() => createSuccessfulRemoteDataObject$(mock) }; TestBed.configureTestingModule({ - imports: [TranslateModule.forRoot()], - declarations: [NotifyRequestsStatusComponent], + imports: [TranslateModule.forRoot(), NotifyRequestsStatusComponent], providers: [ { provide: NotifyRequestsStatusDataService, useValue: notifyInfoServiceSpy } ] diff --git a/src/app/item-page/simple/notify-requests-status/request-status-alert-box/request-status-alert-box.component.spec.ts b/src/app/item-page/simple/notify-requests-status/request-status-alert-box/request-status-alert-box.component.spec.ts index 55ee9e05a1..2457d1a340 100644 --- a/src/app/item-page/simple/notify-requests-status/request-status-alert-box/request-status-alert-box.component.spec.ts +++ b/src/app/item-page/simple/notify-requests-status/request-status-alert-box/request-status-alert-box.component.spec.ts @@ -25,8 +25,7 @@ describe('RequestStatusAlertBoxComponent', () => { beforeEach(async () => { await TestBed.configureTestingModule({ - imports: [TranslateModule.forRoot()], - declarations: [RequestStatusAlertBoxComponent] + imports: [TranslateModule.forRoot(), RequestStatusAlertBoxComponent] }).compileComponents(); }); diff --git a/src/app/item-page/simple/qa-event-notification/qa-event-notification.component.spec.ts b/src/app/item-page/simple/qa-event-notification/qa-event-notification.component.spec.ts index 4623a129ef..92fedddced 100644 --- a/src/app/item-page/simple/qa-event-notification/qa-event-notification.component.spec.ts +++ b/src/app/item-page/simple/qa-event-notification/qa-event-notification.component.spec.ts @@ -37,8 +37,7 @@ describe('QaEventNotificationComponent', () => { getSourcesByTarget: () => objPL }; await TestBed.configureTestingModule({ - imports: [CommonModule, TranslateModule.forRoot()], - declarations: [QaEventNotificationComponent, SplitPipe], + imports: [CommonModule, TranslateModule.forRoot(), QaEventNotificationComponent, SplitPipe], providers: [ { provide: QualityAssuranceSourceDataService, useValue: qualityAssuranceSourceDataServiceStub }, { provide: RequestService, useValue: {} }, diff --git a/src/app/my-dspace-page/my-dspace-qa-events-notifications/my-dspace-qa-events-notifications.component.spec.ts b/src/app/my-dspace-page/my-dspace-qa-events-notifications/my-dspace-qa-events-notifications.component.spec.ts index df86e39726..2d73de47ea 100644 --- a/src/app/my-dspace-page/my-dspace-qa-events-notifications/my-dspace-qa-events-notifications.component.spec.ts +++ b/src/app/my-dspace-page/my-dspace-qa-events-notifications/my-dspace-qa-events-notifications.component.spec.ts @@ -18,7 +18,7 @@ describe('MyDspaceQaEventsNotificationsComponent', () => { getSources: () => obj }; await TestBed.configureTestingModule({ - declarations: [MyDspaceQaEventsNotificationsComponent], + imports: [MyDspaceQaEventsNotificationsComponent], providers: [ { provide: QualityAssuranceSourceDataService, useValue: qualityAssuranceSourceDataServiceStub } ] diff --git a/src/app/process-page/overview/table/process-overview-table.component.spec.ts b/src/app/process-page/overview/table/process-overview-table.component.spec.ts index 94711cf8cc..70af9827c2 100644 --- a/src/app/process-page/overview/table/process-overview-table.component.spec.ts +++ b/src/app/process-page/overview/table/process-overview-table.component.spec.ts @@ -124,8 +124,8 @@ describe('ProcessOverviewTableComponent', () => { init(); void TestBed.configureTestingModule({ - declarations: [ProcessOverviewTableComponent, NgbCollapse], - imports: [TranslateModule.forRoot(), RouterTestingModule.withRoutes([]), VarDirective], + declarations: [NgbCollapse], + imports: [TranslateModule.forRoot(), RouterTestingModule.withRoutes([]), VarDirective, ProcessOverviewTableComponent], providers: [ { provide: ProcessOverviewService, useValue: processOverviewService }, { provide: ProcessDataService, useValue: processService }, diff --git a/src/app/quality-assurance-notifications-pages/quality-assurance-source-page-component/quality-assurance-source-page.component.spec.ts b/src/app/quality-assurance-notifications-pages/quality-assurance-source-page-component/quality-assurance-source-page.component.spec.ts index 1714848fd3..c51fe96a87 100644 --- a/src/app/quality-assurance-notifications-pages/quality-assurance-source-page-component/quality-assurance-source-page.component.spec.ts +++ b/src/app/quality-assurance-notifications-pages/quality-assurance-source-page-component/quality-assurance-source-page.component.spec.ts @@ -9,7 +9,7 @@ describe('QualityAssuranceSourcePageComponent', () => { beforeEach(async () => { await TestBed.configureTestingModule({ - declarations: [QualityAssuranceSourcePageComponent], + imports: [QualityAssuranceSourcePageComponent], schemas: [NO_ERRORS_SCHEMA] }) .compileComponents(); diff --git a/src/app/shared/comcol/sections/comcol-browse-by/comcol-browse-by.component.spec.ts b/src/app/shared/comcol/sections/comcol-browse-by/comcol-browse-by.component.spec.ts index 6da49a0c6c..c16d3faccc 100644 --- a/src/app/shared/comcol/sections/comcol-browse-by/comcol-browse-by.component.spec.ts +++ b/src/app/shared/comcol/sections/comcol-browse-by/comcol-browse-by.component.spec.ts @@ -40,9 +40,8 @@ describe('ComcolBrowseByComponent', () => { themeService = getMockThemeService(); await TestBed.configureTestingModule({ - imports: [BrowseBySwitcherComponent], - declarations: [ComcolBrowseByComponent, - DynamicComponentLoaderDirective], + imports: [BrowseBySwitcherComponent, ComcolBrowseByComponent], + declarations: [DynamicComponentLoaderDirective], providers: [ BrowseByTestComponent, { provide: ActivatedRoute, useValue: activatedRoute }, diff --git a/src/app/shared/comcol/sections/comcol-search-section/comcol-search-section.component.spec.ts b/src/app/shared/comcol/sections/comcol-search-section/comcol-search-section.component.spec.ts index d454cec830..cb8dc25333 100644 --- a/src/app/shared/comcol/sections/comcol-search-section/comcol-search-section.component.spec.ts +++ b/src/app/shared/comcol/sections/comcol-search-section/comcol-search-section.component.spec.ts @@ -15,7 +15,7 @@ describe('ComcolSearchSectionComponent', () => { route = new ActivatedRouteStub(); await TestBed.configureTestingModule({ - declarations: [ComcolSearchSectionComponent], + imports: [ComcolSearchSectionComponent], providers: [ { provide: APP_CONFIG, useValue: environment }, { provide: ActivatedRoute, useValue: route }, diff --git a/src/app/shared/search/advanced-search/advanced-search.component.spec.ts b/src/app/shared/search/advanced-search/advanced-search.component.spec.ts index d5959d71dc..a9342ddbfb 100644 --- a/src/app/shared/search/advanced-search/advanced-search.component.spec.ts +++ b/src/app/shared/search/advanced-search/advanced-search.component.spec.ts @@ -33,8 +33,7 @@ describe('AdvancedSearchComponent', () => { }; beforeEach(async () => { await TestBed.configureTestingModule({ - declarations: [AdvancedSearchComponent], - imports: [FormsModule, RouterTestingModule, TranslateModule.forRoot(), BrowserAnimationsModule, ReactiveFormsModule, BrowserOnlyMockPipe], + imports: [FormsModule, RouterTestingModule, TranslateModule.forRoot(), BrowserAnimationsModule, ReactiveFormsModule, BrowserOnlyMockPipe, AdvancedSearchComponent], providers: [ FormBuilder, { provide: APP_CONFIG, useValue: environment }, diff --git a/src/app/shared/starts-with/starts-with-loader.component.spec.ts b/src/app/shared/starts-with/starts-with-loader.component.spec.ts index f59ed7cde4..71d33c7502 100644 --- a/src/app/shared/starts-with/starts-with-loader.component.spec.ts +++ b/src/app/shared/starts-with/starts-with-loader.component.spec.ts @@ -31,10 +31,10 @@ describe('StartsWithLoaderComponent', () => { void TestBed.configureTestingModule({ imports: [ TranslateModule.forRoot(), - StartsWithTextComponent + StartsWithTextComponent, + StartsWithLoaderComponent ], - declarations: [StartsWithLoaderComponent, - DynamicComponentLoaderDirective], + declarations: [DynamicComponentLoaderDirective], providers: [ { provide: PaginationService, useValue: paginationService }, { provide: ActivatedRoute, useValue: route }, diff --git a/src/app/submission/sections/section-coar-notify/section-coar-notify.component.spec.ts b/src/app/submission/sections/section-coar-notify/section-coar-notify.component.spec.ts index c8e21a72f4..c5a9500387 100644 --- a/src/app/submission/sections/section-coar-notify/section-coar-notify.component.spec.ts +++ b/src/app/submission/sections/section-coar-notify/section-coar-notify.component.spec.ts @@ -63,8 +63,7 @@ describe('SubmissionSectionCoarNotifyComponent', () => { }); await TestBed.configureTestingModule({ - imports: [TranslateModule.forRoot()], - declarations: [SubmissionSectionCoarNotifyComponent], + imports: [TranslateModule.forRoot(), SubmissionSectionCoarNotifyComponent], providers: [ { provide: LdnServicesService, useValue: ldnServicesService }, { provide: CoarNotifyConfigDataService, useValue: coarNotifyConfigDataService },