fix cypress tests

This commit is contained in:
jasquat 2023-04-14 10:00:06 -04:00
parent 0aa0698557
commit abd748e0bd
No known key found for this signature in database
2 changed files with 6 additions and 2 deletions

View File

@ -90,7 +90,9 @@ describe('tasks', () => {
cy.get('.is-visible .cds--modal-close').click();
cy.navigateToHome();
cy.contains('Tasks').should('exist');
// look for somethig to make sure the homepage has loaded
cy.contains('Waiting for me').should('exist');
// FIXME: this will probably need a better way to link to the proper form that we want
cy.contains('Go').click();

View File

@ -467,7 +467,9 @@ export default function ReactDiagramEditor({
return;
}
diagramModelerToUse.importXML(diagramXMLToDisplay).then(() => {
diagramModelerToUse.get('canvas').zoom('fit-viewport');
if (diagramType === 'bpmn' || diagramType === 'readonly') {
diagramModelerToUse.get('canvas').zoom('fit-viewport');
}
});
alreadyImportedXmlRef.current = true;