From 098fd5df7f76f387b4bf5d599362d8c42d5e7ba9 Mon Sep 17 00:00:00 2001 From: Nandini Chandra Date: Tue, 15 Aug 2023 00:35:29 -0500 Subject: [PATCH] [RFR] Update selector for Application import form (#670) * Update a few methods in assessment class Signed-off-by: Nandini Chandra * Update a few methods in assessment class Signed-off-by: Nandini Chandra * Update selectors on Application import form Signed-off-by: Nandini Chandra --------- Signed-off-by: Nandini Chandra --- cypress/e2e/views/applicationinventory.view.ts | 3 +++ cypress/utils/utils.ts | 3 ++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/cypress/e2e/views/applicationinventory.view.ts b/cypress/e2e/views/applicationinventory.view.ts index 2e5dea72c..3c163c947 100644 --- a/cypress/e2e/views/applicationinventory.view.ts +++ b/cypress/e2e/views/applicationinventory.view.ts @@ -73,3 +73,6 @@ export const copyAssessmentTableTd = ".pf-m-compact> tbody > tr > td"; export const copyAssessmentTableTr = ".pf-m-compact> tbody > tr"; export const copyAssessmentPagination = "#bulk-copy-assessment-review-pagination-top"; export const copyAssessmentModal = "div.pf-v5-c-modal-box"; + +// Fields related to application import +export const appImportForm = "form.pf-v5-c-form"; diff --git a/cypress/utils/utils.ts b/cypress/utils/utils.ts index 88e72b33a..e507699c6 100644 --- a/cypress/utils/utils.ts +++ b/cypress/utils/utils.ts @@ -56,6 +56,7 @@ import { date, createEntitiesCheckbox, topKebabMenu, + appImportForm, } from "../e2e/views/applicationinventory.view"; import { closeSuccessNotification, @@ -659,7 +660,7 @@ export function importApplication(fileName: string, disableAutoCreation?: boolea enabled ? cy.log("Button is disabled") : cy.get(createEntitiesCheckbox).uncheck(); }); - cy.get("form.pf-c-form", { timeout: 5 * SEC }) + cy.get(appImportForm, { timeout: 5 * SEC }) .find("button") .contains("Import") .trigger("click");