mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-07 10:04:11 +00:00
fix DsDynamicLookupRelationExternalSourceTabComponent tests
This commit is contained in:
@@ -15,6 +15,8 @@ import { ItemDataService } from '../../../../../../../core/data/item-data.servic
|
|||||||
import { NotificationsService } from '../../../../../../notifications/notifications.service';
|
import { NotificationsService } from '../../../../../../notifications/notifications.service';
|
||||||
import { createSuccessfulRemoteDataObject$ } from '../../../../../../remote-data.utils';
|
import { createSuccessfulRemoteDataObject$ } from '../../../../../../remote-data.utils';
|
||||||
import { createPaginatedList } from '../../../../../../testing/utils.test';
|
import { createPaginatedList } from '../../../../../../testing/utils.test';
|
||||||
|
import { NoopAnimationsModule } from '@angular/platform-browser/animations';
|
||||||
|
import { SearchResultsComponent } from '../../../../../../search/search-results/search-results.component';
|
||||||
|
|
||||||
describe('DsDynamicLookupRelationExternalSourceTabComponent', () => {
|
describe('DsDynamicLookupRelationExternalSourceTabComponent', () => {
|
||||||
let component: ExternalSourceEntryImportModalComponent;
|
let component: ExternalSourceEntryImportModalComponent;
|
||||||
@@ -67,7 +69,13 @@ describe('DsDynamicLookupRelationExternalSourceTabComponent', () => {
|
|||||||
beforeEach(waitForAsync(() => {
|
beforeEach(waitForAsync(() => {
|
||||||
init();
|
init();
|
||||||
TestBed.configureTestingModule({
|
TestBed.configureTestingModule({
|
||||||
imports: [TranslateModule.forRoot(), RouterTestingModule.withRoutes([]), NgbModule, ExternalSourceEntryImportModalComponent],
|
imports: [
|
||||||
|
TranslateModule.forRoot(),
|
||||||
|
RouterTestingModule.withRoutes([]),
|
||||||
|
NgbModule,
|
||||||
|
ExternalSourceEntryImportModalComponent,
|
||||||
|
NoopAnimationsModule
|
||||||
|
],
|
||||||
providers: [
|
providers: [
|
||||||
{ provide: LookupRelationService, useValue: lookupRelationService },
|
{ provide: LookupRelationService, useValue: lookupRelationService },
|
||||||
{ provide: SelectableListService, useValue: selectService },
|
{ provide: SelectableListService, useValue: selectService },
|
||||||
@@ -76,7 +84,11 @@ describe('DsDynamicLookupRelationExternalSourceTabComponent', () => {
|
|||||||
{ provide: NgbActiveModal, useValue: modalStub }
|
{ provide: NgbActiveModal, useValue: modalStub }
|
||||||
],
|
],
|
||||||
schemas: [NO_ERRORS_SCHEMA]
|
schemas: [NO_ERRORS_SCHEMA]
|
||||||
}).compileComponents();
|
})
|
||||||
|
.overrideComponent(ExternalSourceEntryImportModalComponent, {
|
||||||
|
remove: { imports: [SearchResultsComponent]}
|
||||||
|
})
|
||||||
|
.compileComponents();
|
||||||
}));
|
}));
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
|
Reference in New Issue
Block a user