From 586cb8893dd22b618108301560fc6c4d167c13b0 Mon Sep 17 00:00:00 2001 From: jasquat Date: Thu, 9 Nov 2023 14:59:35 -0500 Subject: [PATCH] attempting to fix broken cypress test by waiting for page to load before clearing w/ burnettk --- spiffworkflow-frontend/cypress/e2e/process_groups.cy.js | 5 +++-- spiffworkflow-frontend/src/components/ProcessGroupForm.tsx | 1 + 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/spiffworkflow-frontend/cypress/e2e/process_groups.cy.js b/spiffworkflow-frontend/cypress/e2e/process_groups.cy.js index 415efce7..413d8e7e 100644 --- a/spiffworkflow-frontend/cypress/e2e/process_groups.cy.js +++ b/spiffworkflow-frontend/cypress/e2e/process_groups.cy.js @@ -20,8 +20,9 @@ describe('process-groups', () => { cy.contains(`Process Group: ${groupDisplayName}`); cy.getBySel('edit-process-group-button').click(); - cy.get('input[name=display_name]').clear(); - cy.get('input[name=display_name]').type(newGroupDisplayName); + cy.wait(1000); // wait for the page to load before clearing the field + cy.getBySel('process-group-display-name-input').clear(); + cy.getBySel('process-group-display-name-input').type(newGroupDisplayName); cy.contains('Submit').click(); cy.contains(`Process Group: ${newGroupDisplayName}`); diff --git a/spiffworkflow-frontend/src/components/ProcessGroupForm.tsx b/spiffworkflow-frontend/src/components/ProcessGroupForm.tsx index 6a5d9801..d02d61f8 100644 --- a/spiffworkflow-frontend/src/components/ProcessGroupForm.tsx +++ b/spiffworkflow-frontend/src/components/ProcessGroupForm.tsx @@ -109,6 +109,7 @@ export default function ProcessGroupForm({ const textInputs = [