From 11b719b8b05b65e68f54859443e7b7a9ce370e33 Mon Sep 17 00:00:00 2001 From: Romuald Caplier Date: Thu, 19 Sep 2024 16:51:32 +0200 Subject: [PATCH] fix test --- .../import-record/import-record.component.spec.ts | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/libs/feature/editor/src/lib/components/import-record/import-record.component.spec.ts b/libs/feature/editor/src/lib/components/import-record/import-record.component.spec.ts index 9d7923e61b..09430bde77 100644 --- a/libs/feature/editor/src/lib/components/import-record/import-record.component.spec.ts +++ b/libs/feature/editor/src/lib/components/import-record/import-record.component.spec.ts @@ -2,11 +2,11 @@ import { ComponentFixture, TestBed } from '@angular/core/testing' import { ImportRecordComponent } from './import-record.component' import { ChangeDetectionStrategy, ChangeDetectorRef } from '@angular/core' import { Router } from '@angular/router' -import { TranslateService } from '@ngx-translate/core' +import { TranslateModule, TranslateService } from '@ngx-translate/core' import { NotificationsService } from '@geonetwork-ui/feature/notifications' import { RecordsRepositoryInterface } from '@geonetwork-ui/common/domain/repository/records-repository.interface' import { of, throwError } from 'rxjs' -import { MockBuilder, MockProviders } from 'ng-mocks' +import { MockBuilder, MockComponent, MockModule, MockProviders } from 'ng-mocks' describe('ImportRecordComponent', () => { let component: ImportRecordComponent @@ -22,6 +22,10 @@ describe('ImportRecordComponent', () => { beforeEach(async () => { await TestBed.configureTestingModule({ + imports: [ + MockComponent(ImportRecordComponent), + MockModule(TranslateModule.forRoot()), + ], providers: [ MockProviders( Router,