test: fixed failing date control UI test

This commit is contained in:
Shariq Ansari 2023-01-05 16:41:15 +05:30
parent 28375e8e6e
commit a135ac587c

View file

@ -19,7 +19,7 @@ context("Date Control", () => {
});
}
it("Selecting a date from the datepicker", () => {
it("Selecting a date from the datepicker & check prev & next button", () => {
cy.clear_dialogs();
cy.clear_datepickers();
@ -39,13 +39,7 @@ context("Date Control", () => {
// Verify if the selected date is set the date field
cy.window().its("cur_dialog.fields_dict.date.value").should("be.equal", "2020-01-15");
});
it("Checking next and previous button", () => {
cy.clear_dialogs();
cy.clear_datepickers();
get_dialog({ default: "2020-01-15" }).as("dialog");
cy.get_field("date", "Date").click();
//Clicking on the next button in the datepicker