From 6f0a50b60c34f2990707fc03cdbba8fdabe3816e Mon Sep 17 00:00:00 2001 From: burnettk Date: Fri, 4 Nov 2022 17:37:32 -0400 Subject: [PATCH] fix label and comment artificial slowdown --- spiffworkflow-frontend/cypress/e2e/process_groups.cy.js | 2 +- spiffworkflow-frontend/cypress/e2e/process_instances.cy.js | 7 +++++++ spiffworkflow-frontend/src/components/ProcessGroupForm.tsx | 2 +- 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/spiffworkflow-frontend/cypress/e2e/process_groups.cy.js b/spiffworkflow-frontend/cypress/e2e/process_groups.cy.js index 9e9740848..629b18c67 100644 --- a/spiffworkflow-frontend/cypress/e2e/process_groups.cy.js +++ b/spiffworkflow-frontend/cypress/e2e/process_groups.cy.js @@ -30,7 +30,7 @@ describe('process-groups', () => { newGroupDisplayName ); - cy.contains('Delete Process Group').click(); + cy.contains('Delete').click(); cy.contains('Are you sure'); cy.getBySel('modal-confirmation-dialog').find('.cds--btn--danger').click(); cy.url().should('include', `process-groups`); diff --git a/spiffworkflow-frontend/cypress/e2e/process_instances.cy.js b/spiffworkflow-frontend/cypress/e2e/process_instances.cy.js index a2fcb2668..62fe3cbcd 100644 --- a/spiffworkflow-frontend/cypress/e2e/process_instances.cy.js +++ b/spiffworkflow-frontend/cypress/e2e/process_instances.cy.js @@ -43,6 +43,13 @@ const updateBpmnPythonScriptWithMonaco = ( cy.contains('Launch Editor').click(); // sometimes, Loading... appears for more than 4 seconds. not sure why. cy.contains('Loading...').should('not.exist'); + + // the delay 30 is because, at some point, monaco started automatically + // adding a second double quote when we type a double quote. when it does + // that, there is a race condition where it sometimes gets in more text + // before the second double quote appears because the robot is typing faster + // than a human being could, so we artificially slow it down to make it more + // human. cy.get('.monaco-editor textarea:first') .click() .focused() // change subject to currently focused element diff --git a/spiffworkflow-frontend/src/components/ProcessGroupForm.tsx b/spiffworkflow-frontend/src/components/ProcessGroupForm.tsx index 99db3434a..128a13c0c 100644 --- a/spiffworkflow-frontend/src/components/ProcessGroupForm.tsx +++ b/spiffworkflow-frontend/src/components/ProcessGroupForm.tsx @@ -162,7 +162,7 @@ export default function ProcessGroupForm({ );