mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[ACA-4089] Add new method in DatePickerCalendarPage
* Add selectDateRange()
This commit is contained in:
committed by
GitHub
parent
278c28c684
commit
a3771a70bd
@@ -71,4 +71,13 @@ export class DatePickerCalendarPage {
|
||||
async checkDatePickerIsNotDisplayed(): Promise<void> {
|
||||
await BrowserVisibility.waitUntilElementIsNotVisible(this.datePicker);
|
||||
}
|
||||
|
||||
async selectDateRange(startDay: number, endDay: number): Promise<void> {
|
||||
const startDayElement = element(by.cssContainingText(`div.mat-calendar-body-cell-content.mat-focus-indicator`, `${startDay}`));
|
||||
const endDayElement = element(by.cssContainingText(`div.mat-calendar-body-cell-content.mat-focus-indicator`, `${endDay}`));
|
||||
await this.checkDatePickerIsDisplayed();
|
||||
await BrowserActions.click(startDayElement);
|
||||
await BrowserActions.click(endDayElement);
|
||||
await this.checkDatePickerIsNotDisplayed();
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user