diff --git a/npm/ng-packs/packages/core/src/lib/tests/config.plugin.spec.ts b/npm/ng-packs/packages/core/src/lib/tests/config.plugin.spec.ts index b9560ddf87..293dd4bf79 100644 --- a/npm/ng-packs/packages/core/src/lib/tests/config.plugin.spec.ts +++ b/npm/ng-packs/packages/core/src/lib/tests/config.plugin.spec.ts @@ -4,11 +4,12 @@ import { NGXS_PLUGINS, NgxsModule, InitState, Store } from '@ngxs/store'; import { environment } from '../../../../../apps/dev-app/src/environments/environment'; import { LAYOUTS } from '../../../../theme-basic/src/public-api'; import { ABP } from '../models'; -import { ConfigPlugin, NGXS_CONFIG_PLUGIN_OPTIONS, addAbpRoutes } from '../plugins'; +import { ConfigPlugin, NGXS_CONFIG_PLUGIN_OPTIONS } from '../plugins'; import { RouterOutletComponent } from '../components'; import { ConfigState } from '../states'; import { CoreModule } from '../core.module'; import { eLayoutType } from '../enums/common'; +import { addAbpRoutes } from '../utils'; addAbpRoutes([ { diff --git a/npm/ng-packs/packages/core/src/lib/tests/locale.provider.spec.ts b/npm/ng-packs/packages/core/src/lib/tests/locale.provider.spec.ts index 3fbcab3493..e82e89d4a0 100644 --- a/npm/ng-packs/packages/core/src/lib/tests/locale.provider.spec.ts +++ b/npm/ng-packs/packages/core/src/lib/tests/locale.provider.spec.ts @@ -30,7 +30,7 @@ describe('LocaleProvider', () => { expect(spectator.get(LOCALE_ID).valueOf()).toBe(localesMapping['en-US'] || 'en-US'); - localizationService.currentLang = 'tr'; + (localizationService as any).currentLang = 'tr'; expect(spectator.get(LOCALE_ID).valueOf()).toBe(localesMapping['tr'] || 'tr'); }); }); diff --git a/npm/ng-packs/packages/core/src/lib/tests/localization.service.spec.ts b/npm/ng-packs/packages/core/src/lib/tests/localization.service.spec.ts index c279fb6da2..8c0dbebb40 100644 --- a/npm/ng-packs/packages/core/src/lib/tests/localization.service.spec.ts +++ b/npm/ng-packs/packages/core/src/lib/tests/localization.service.spec.ts @@ -24,7 +24,7 @@ describe('LocalizationService', () => { describe('#currentLang', () => { it('should be tr', () => { store.selectSnapshot.andCallFake((selector: (state: any, ...states: any[]) => string) => { - return selector({ SessionState: { getLanguage: 'tr' } }); + return selector({ SessionState: { language: 'tr' } }); }); expect(service.currentLang).toBe('tr'); @@ -33,9 +33,7 @@ describe('LocalizationService', () => { describe('#get', () => { it('should be return an observable localization', async () => { - store.select.andCallFake((selector: (state: any, ...states: any[]) => Observable) => { - return selector({ ConfigState: { getLocalization: (keys, ...interpolateParams) => of(keys) } }); - }); + store.select.andReturn(of('AbpTest')); const localization = await service.get('AbpTest').toPromise(); diff --git a/npm/ng-packs/packages/setting-management/src/lib/components/setting-management.component.html b/npm/ng-packs/packages/setting-management/src/lib/components/setting-management.component.html index 58659ff50b..ca2ad18deb 100644 --- a/npm/ng-packs/packages/setting-management/src/lib/components/setting-management.component.html +++ b/npm/ng-packs/packages/setting-management/src/lib/components/setting-management.component.html @@ -2,9 +2,9 @@

{{ 'AbpSettingManagement::Settings' | abpLocalization }}

- +