Skip to content

Commit d360208

Browse files
committed
fix(tests): providing bg locale for date-util test spec
1 parent 5d9cd91 commit d360208

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

projects/igniteui-angular/src/lib/date-common/util/date-time.util.spec.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,19 @@
11
import { DateTimeUtil } from './date-time.util';
22
import { DatePart, DatePartInfo } from '../../directives/date-time-editor/date-time-editor.common';
33
import { DataType } from '../../data-operations/data-util';
4+
import localeBg from "@angular/common/locales/bg";
5+
import { registerLocaleData } from '@angular/common';
6+
47

58
const reduceToDictionary = (parts: DatePartInfo[]) => parts.reduce((obj, x) => {
69
obj[x.type] = x;
710
return obj;
811
}, {});
912

1013
describe(`DateTimeUtil Unit tests`, () => {
14+
15+
registerLocaleData(localeBg);
16+
1117
describe('Date Time Parsing', () => {
1218
it('should correctly parse all date time parts (base)', () => {
1319
let result = DateTimeUtil.parseDateTimeFormat('dd/MM/yyyy HH:mm:ss:SS a');

0 commit comments

Comments
 (0)