fix(editor): Add workflows to the store when fetching current page (#13583)

This commit is contained in:
Milorad FIlipović
2025-02-28 11:53:42 +01:00
committed by GitHub
parent 727f6f3c0e
commit c4f3293778
3 changed files with 22 additions and 0 deletions

View File

@@ -1,9 +1,11 @@
import { WorkflowSharingModal } from '../pages';
import { WorkflowPage as WorkflowPageClass } from '../pages/workflow';
import { WorkflowsPage as WorkflowsPageClass } from '../pages/workflows';
import { getUniqueWorkflowName } from '../utils/workflowUtils';
const WorkflowsPage = new WorkflowsPageClass();
const WorkflowPage = new WorkflowPageClass();
const workflowSharingModal = new WorkflowSharingModal();
const multipleWorkflowsCount = 5;
@@ -138,4 +140,10 @@ describe('Workflows', () => {
cy.url().should('include', 'sort=lastCreated');
cy.url().should('include', 'pageSize=25');
});
it('should be able to share workflows from workflows list', () => {
WorkflowsPage.getters.workflowCardActions('Empty State Card Workflow').click();
WorkflowsPage.getters.workflowActionItem('share').click();
workflowSharingModal.getters.modal().should('be.visible');
});
});

View File

@@ -35,6 +35,7 @@ export class WorkflowsPage extends BasePage {
this.getters.workflowActivator(workflowName).findChildByTestId('workflow-activator-status'),
workflowCardActions: (workflowName: string) =>
this.getters.workflowCard(workflowName).findChildByTestId('workflow-card-actions'),
workflowActionItem: (action: string) => cy.getByTestId(`action-${action}`).filter(':visible'),
workflowDeleteButton: () =>
cy.getByTestId('action-toggle-dropdown').filter(':visible').contains('Delete'),
workflowMoveButton: () =>