mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-07 10:04:11 +00:00
[DURACOM-191] fix some tests
This commit is contained in:
@@ -69,6 +69,7 @@ import { TruncatePipe } from '../../../../shared/utils/truncate.pipe';
|
||||
import { ThemedThumbnailComponent } from '../../../../thumbnail/themed-thumbnail.component';
|
||||
import { GenericItemPageFieldComponent } from '../../field-components/specific-field/generic/generic-item-page-field.component';
|
||||
import { ThemedItemPageTitleFieldComponent } from '../../field-components/specific-field/title/themed-item-page-field.component';
|
||||
import { ThemedMetadataRepresentationListComponent } from '../../metadata-representation-list/themed-metadata-representation-list.component';
|
||||
import { TabbedRelatedEntitiesSearchComponent } from '../../related-entities/tabbed-related-entities-search/tabbed-related-entities-search.component';
|
||||
import { RelatedItemsComponent } from '../../related-items/related-items-component';
|
||||
import { ItemComponent } from './item.component';
|
||||
@@ -198,6 +199,7 @@ export function getItemPageFieldsTest(mockItem: Item, component) {
|
||||
ThemedThumbnailComponent,
|
||||
RelatedItemsComponent,
|
||||
TabbedRelatedEntitiesSearchComponent,
|
||||
ThemedMetadataRepresentationListComponent,
|
||||
],
|
||||
},
|
||||
add: { changeDetection: ChangeDetectionStrategy.Default },
|
||||
|
@@ -6,6 +6,7 @@ import { ActivatedRoute } from '@angular/router';
|
||||
|
||||
import { APP_CONFIG } from '../../../../../config/app-config.interface';
|
||||
import { environment } from '../../../../../environments/environment.test';
|
||||
import { ThemedSearchComponent } from '../../../search/themed-search.component';
|
||||
import { ActivatedRouteStub } from '../../../testing/active-router.stub';
|
||||
import { ComcolSearchSectionComponent } from './comcol-search-section.component';
|
||||
|
||||
@@ -24,7 +25,13 @@ describe('ComcolSearchSectionComponent', () => {
|
||||
{ provide: APP_CONFIG, useValue: environment },
|
||||
{ provide: ActivatedRoute, useValue: route },
|
||||
],
|
||||
}).compileComponents();
|
||||
})
|
||||
.overrideComponent(ComcolSearchSectionComponent, {
|
||||
remove: {
|
||||
imports: [ThemedSearchComponent],
|
||||
},
|
||||
})
|
||||
.compileComponents();
|
||||
|
||||
fixture = TestBed.createComponent(ComcolSearchSectionComponent);
|
||||
component = fixture.componentInstance;
|
||||
|
@@ -22,8 +22,7 @@ describe('NotificationBoxComponent', () => {
|
||||
};
|
||||
|
||||
await TestBed.configureTestingModule({
|
||||
imports: [TranslateModule.forRoot()],
|
||||
declarations: [NotificationBoxComponent],
|
||||
imports: [TranslateModule.forRoot(), NotificationBoxComponent],
|
||||
})
|
||||
.compileComponents();
|
||||
|
||||
|
Reference in New Issue
Block a user