mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2026-09-09 18:03:21 +00:00
[ACS-10246] Fix unit test
This commit is contained in:
@@ -67,14 +67,14 @@ const renderDateCell = (dateConfig: DateConfig, value: number | string | Date, t
|
||||
};
|
||||
|
||||
const checkDisplayedDate = (expectedDate: string) => {
|
||||
const displayedDate = testingUtils.getByCSS('span').nativeElement.textContent.trim();
|
||||
const displayedDate = testingUtils.getByCSS('time').nativeElement.textContent.trim();
|
||||
|
||||
expect(displayedDate).toBeTruthy();
|
||||
expect(displayedDate).toBe(expectedDate);
|
||||
};
|
||||
|
||||
const checkDisplayedTooltip = (expectedTooltip: string) => {
|
||||
const displayedTooltip = testingUtils.getByCSS('span').nativeElement.title;
|
||||
const displayedTooltip = testingUtils.getByCSS('time').nativeElement.title;
|
||||
|
||||
expect(displayedTooltip).toBeTruthy();
|
||||
expect(displayedTooltip).toBe(expectedTooltip);
|
||||
@@ -141,7 +141,7 @@ describe('DateCellComponent', () => {
|
||||
expect(component.config().locale).toEqual('en-US');
|
||||
});
|
||||
|
||||
it('should display date and tooltip with defaules values if NO dateConfig or appConfig is provided', () => {
|
||||
it('should display date and tooltip with default values if NO dateConfig or appConfig is provided', () => {
|
||||
appConfigService.config = {
|
||||
dateValues: {}
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user