@camunda/e2e-test-suite 0.0.236 → 0.0.238

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -20,6 +20,7 @@ import { ConnectorSettingsPage } from '../pages/SM-8.9/ConnectorSettingsPage';
20
20
  import { ConnectorMarketplacePage } from '../pages/SM-8.9/ConnectorMarketplacePage';
21
21
  import { OCIdentityHomePage } from '../pages/SM-8.9/OCIdentityHomePage';
22
22
  import { OCIdentityMappingRulesPage } from '../pages/SM-8.9/OCIdentityMappingRulesPage';
23
+ import { OCIdentityClusterVariablesPage } from '../pages/SM-8.9/OCIdentityClusterVariablesPage';
23
24
  import { ConsoleHomePage } from '../pages/SM-8.9/ConsoleHomePage';
24
25
  import { OptimizeDashboardPage } from '../pages/SM-8.9/OptimizeDashboardPage';
25
26
  import { TaskProcessesPage } from '../pages/SM-8.9/TaskProcessesPage';
@@ -58,6 +59,7 @@ type PlaywrightFixtures = {
58
59
  connectorMarketplacePage: ConnectorMarketplacePage;
59
60
  ocIdentityHomePage: OCIdentityHomePage;
60
61
  ocIdentityMappingRulesPage: OCIdentityMappingRulesPage;
62
+ ocIdentityClusterVariablesPage: OCIdentityClusterVariablesPage;
61
63
  consoleHomePage: ConsoleHomePage;
62
64
  optimizeDashboardPage: OptimizeDashboardPage;
63
65
  taskProcessesPage: TaskProcessesPage;
@@ -27,6 +27,7 @@ const ConnectorSettingsPage_1 = require("../pages/SM-8.9/ConnectorSettingsPage")
27
27
  const ConnectorMarketplacePage_1 = require("../pages/SM-8.9/ConnectorMarketplacePage");
28
28
  const OCIdentityHomePage_1 = require("../pages/SM-8.9/OCIdentityHomePage");
29
29
  const OCIdentityMappingRulesPage_1 = require("../pages/SM-8.9/OCIdentityMappingRulesPage");
30
+ const OCIdentityClusterVariablesPage_1 = require("../pages/SM-8.9/OCIdentityClusterVariablesPage");
30
31
  const ConsoleHomePage_1 = require("../pages/SM-8.9/ConsoleHomePage");
31
32
  const OptimizeDashboardPage_1 = require("../pages/SM-8.9/OptimizeDashboardPage");
32
33
  const TaskProcessesPage_1 = require("../pages/SM-8.9/TaskProcessesPage");
@@ -128,6 +129,9 @@ const test = test_1.test.extend({
128
129
  ocIdentityMappingRulesPage: async ({ page }, use) => {
129
130
  await use(new OCIdentityMappingRulesPage_1.OCIdentityMappingRulesPage(page));
130
131
  },
132
+ ocIdentityClusterVariablesPage: async ({ page }, use) => {
133
+ await use(new OCIdentityClusterVariablesPage_1.OCIdentityClusterVariablesPage(page));
134
+ },
131
135
  ocIdentityRolesPage: async ({ page }, use) => {
132
136
  await use(new OCIdentityRolesPage_1.OCIdentityRolesPage(page));
133
137
  },
@@ -0,0 +1,20 @@
1
+ import { Page, Locator } from '@playwright/test';
2
+ export declare class OCIdentityClusterVariablesPage {
3
+ private page;
4
+ readonly variablesList: Locator;
5
+ readonly editVariableButton: (variableName: string) => Locator;
6
+ readonly editVariableModal: Locator;
7
+ readonly variableValueField: Locator;
8
+ readonly saveVariableButton: Locator;
9
+ readonly closeEditVariableModal: Locator;
10
+ readonly cancelButton: Locator;
11
+ readonly variableRow: (variableName: string) => Locator;
12
+ readonly monacoEditor: Locator;
13
+ readonly monacoEditorTextArea: Locator;
14
+ readonly successMessage: Locator;
15
+ readonly editMenuItem: Locator;
16
+ constructor(page: Page);
17
+ editVariable(variableName: string, newValue: string): Promise<void>;
18
+ assertVariableExists(variableName: string): Promise<void>;
19
+ assertVariableValue(variableName: string, expectedValue: string): Promise<void>;
20
+ }
@@ -0,0 +1,69 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.OCIdentityClusterVariablesPage = void 0;
4
+ const test_1 = require("@playwright/test");
5
+ class OCIdentityClusterVariablesPage {
6
+ page;
7
+ variablesList;
8
+ editVariableButton;
9
+ editVariableModal;
10
+ variableValueField;
11
+ saveVariableButton;
12
+ closeEditVariableModal;
13
+ cancelButton;
14
+ variableRow;
15
+ monacoEditor;
16
+ monacoEditorTextArea;
17
+ successMessage;
18
+ editMenuItem;
19
+ constructor(page) {
20
+ this.page = page;
21
+ this.variablesList = page.locator('table.cds--data-table');
22
+ this.variableRow = (variableName) => this.variablesList
23
+ .locator('tbody')
24
+ .getByRole('row')
25
+ .filter({ hasText: variableName });
26
+ this.editVariableButton = (variableName) => this.variableRow(variableName).getByRole('button', { name: 'Options' });
27
+ this.editVariableModal = page.getByRole('dialog', {
28
+ name: /Edit.*variable/i,
29
+ });
30
+ this.variableValueField = this.editVariableModal.getByRole('textbox', {
31
+ name: 'Editor content',
32
+ });
33
+ this.saveVariableButton = this.editVariableModal.locator('.cds--modal-footer button.cds--btn--primary');
34
+ this.closeEditVariableModal = this.editVariableModal.getByRole('button', {
35
+ name: 'Close',
36
+ });
37
+ this.cancelButton = this.editVariableModal.getByRole('button', {
38
+ name: 'Cancel',
39
+ });
40
+ this.monacoEditor = this.editVariableModal.locator('.monaco-editor');
41
+ this.monacoEditorTextArea = this.monacoEditor.locator('textarea.inputarea');
42
+ this.successMessage = this.page.getByText('Cluster variable updated');
43
+ this.editMenuItem = this.page
44
+ .locator('button[role="menuitem"]')
45
+ .filter({ hasText: /^Edit$/ });
46
+ }
47
+ async editVariable(variableName, newValue) {
48
+ await this.editVariableButton(variableName).click();
49
+ await (0, test_1.expect)(this.editMenuItem).toBeVisible();
50
+ await this.editMenuItem.click();
51
+ await (0, test_1.expect)(this.variableValueField).toBeVisible();
52
+ await (0, test_1.expect)(this.monacoEditor).toBeVisible();
53
+ await this.monacoEditor.click();
54
+ await this.monacoEditorTextArea.clear();
55
+ await this.monacoEditorTextArea.fill(newValue);
56
+ await (0, test_1.expect)(this.saveVariableButton).toBeEnabled();
57
+ await this.saveVariableButton.click();
58
+ await (0, test_1.expect)(this.successMessage).toBeVisible();
59
+ await (0, test_1.expect)(this.editVariableModal).toBeHidden();
60
+ }
61
+ async assertVariableExists(variableName) {
62
+ await (0, test_1.expect)(this.variableRow(variableName)).toBeVisible();
63
+ }
64
+ async assertVariableValue(variableName, expectedValue) {
65
+ const row = this.variableRow(variableName);
66
+ await (0, test_1.expect)(row).toContainText(expectedValue);
67
+ }
68
+ }
69
+ exports.OCIdentityClusterVariablesPage = OCIdentityClusterVariablesPage;
@@ -7,6 +7,7 @@ declare class OCIdentityHomePage {
7
7
  readonly tenantsTab: Locator;
8
8
  readonly rolesTab: Locator;
9
9
  readonly authorizationsTab: Locator;
10
+ readonly clusterVariablesTab: Locator;
10
11
  readonly licenseKeyTagNonProduction: Locator;
11
12
  readonly licenseKeyTagNonCommercial: Locator;
12
13
  readonly licenseKeyTagProduction: Locator;
@@ -17,5 +18,6 @@ declare class OCIdentityHomePage {
17
18
  clickAuthorizationsTab(): Promise<void>;
18
19
  clickRolesTab(): Promise<void>;
19
20
  clickGroupsTab(): Promise<void>;
21
+ clickClusterVariablesTab(): Promise<void>;
20
22
  }
21
23
  export { OCIdentityHomePage };
@@ -11,6 +11,7 @@ class OCIdentityHomePage {
11
11
  tenantsTab;
12
12
  rolesTab;
13
13
  authorizationsTab;
14
+ clusterVariablesTab;
14
15
  licenseKeyTagNonProduction;
15
16
  licenseKeyTagNonCommercial;
16
17
  licenseKeyTagProduction;
@@ -41,6 +42,10 @@ class OCIdentityHomePage {
41
42
  .getByRole('banner')
42
43
  .locator('a')
43
44
  .filter({ hasText: /^Authorizations$/ });
45
+ this.clusterVariablesTab = page
46
+ .getByRole('banner')
47
+ .locator('a')
48
+ .filter({ hasText: /Cluster variables/i });
44
49
  this.licenseKeyTagNonProduction = page
45
50
  .getByText('Non-production license')
46
51
  .first();
@@ -68,5 +73,9 @@ class OCIdentityHomePage {
68
73
  await (0, expectLocatorWithRetry_1.expectLocatorWithRetry)(this.page, this.groupsTab);
69
74
  await this.groupsTab.click({ timeout: 30000 });
70
75
  }
76
+ async clickClusterVariablesTab() {
77
+ await (0, expectLocatorWithRetry_1.expectLocatorWithRetry)(this.page, this.clusterVariablesTab);
78
+ await this.clusterVariablesTab.click({ timeout: 30000 });
79
+ }
71
80
  }
72
81
  exports.OCIdentityHomePage = OCIdentityHomePage;
@@ -15,7 +15,7 @@ _8_10_1.test.describe('Cluster Variables User Flows', () => {
15
15
  _8_10_1.test.beforeAll(async () => {
16
16
  authToken = await (0, apiHelpers_1.authSaasAPI)();
17
17
  await (0, apiHelpers_1.createGlobalClusterVariable)(authToken);
18
- jsonClusterVariableValue = JSON.parse(process.env.CLUSTER_VARIABLE_JSON);
18
+ jsonClusterVariableValue = JSON.parse(process.env.CLUSTER_VARIABLE_JSON_VALUE);
19
19
  });
20
20
  _8_10_1.test.beforeEach(async ({ page, appsPage, loginPage }, testInfo) => {
21
21
  await (0, UtilitiesPage_1.loginWithRetry)(page, loginPage, testUser, (testInfo.workerIndex + 1) * 1000);
@@ -29,10 +29,9 @@ _8_10_1.test.describe('Cluster Variables User Flows', () => {
29
29
  _8_10_1.test.describe('Global cluster variable', () => {
30
30
  (0, _8_10_1.test)('User deploys a process and accesses global cluster variable on Tasklist', async ({ appsPage, operateHomePage, operateProcessesPage, operateProcessInstancePage, taskPanelPage, taskDetailsPage, }) => {
31
31
  _8_10_1.test.slow();
32
- const [processKey] = await Promise.all([
33
- (0, apiHelpers_1.deployProcess)('./resources/cluster_variables/cluster_variable_global_scope.bpmn', authToken),
34
- (0, apiHelpers_1.deployProcess)('./resources/cluster_variables/preview_cluster_variables.form', authToken),
35
- ]);
32
+ await (0, apiHelpers_1.deployProcess)('./resources/cluster_variables/preview_cluster_variables.form', authToken);
33
+ await (0, sleep_1.sleep)(2000);
34
+ const processKey = await (0, apiHelpers_1.deployProcess)('./resources/cluster_variables/cluster_variable_global_scope.bpmn', authToken);
36
35
  if (processKey == null) {
37
36
  throw new Error('Failed to deploy process or missing processDefinitionKey');
38
37
  }
@@ -16,8 +16,7 @@ _8_10_1.test.describe('Navigation Tests', () => {
16
16
  await (0, _setup_1.captureScreenshot)(page, testInfo);
17
17
  await (0, _setup_1.captureFailureVideo)(page, testInfo);
18
18
  });
19
- //Skipped due to bug: Tasklist
20
- _8_10_1.test.skip('Basic Navigation', async ({ homePage, appsPage, modelerHomePage, operateHomePage, optimizeHomePage, taskPanelPage, ocIdentityHomePage, }) => {
19
+ (0, _8_10_1.test)('Basic Navigation', async ({ homePage, appsPage, modelerHomePage, operateHomePage, optimizeHomePage, taskPanelPage, ocIdentityHomePage, }) => {
21
20
  await _8_10_1.test.step('Assert Web Modeler Navigation', async () => {
22
21
  await appsPage.clickCamundaApps();
23
22
  await appsPage.clickModeler();
@@ -15,6 +15,7 @@ const OptimizeCollectionsPage_1 = require("../../pages/8.10/OptimizeCollectionsP
15
15
  const OptimizeReportPage_1 = require("../../pages/8.10/OptimizeReportPage");
16
16
  const expectLocatorWithRetry_1 = require("../../utils/assertionHelpers/expectLocatorWithRetry");
17
17
  const users_1 = require("../../utils/users");
18
+ const sleep_1 = require("../../utils/sleep");
18
19
  const testUser = (0, users_1.getTestUser)('thirteenthUser');
19
20
  _8_10_1.test.describe.configure({ mode: 'parallel' });
20
21
  _8_10_1.test.describe('Smoke Tests', () => {
@@ -26,8 +27,7 @@ _8_10_1.test.describe('Smoke Tests', () => {
26
27
  await (0, _setup_1.captureScreenshot)(page, testInfo);
27
28
  await (0, _setup_1.captureFailureVideo)(page, testInfo);
28
29
  });
29
- //Skipped due to bug: Tasklist
30
- _8_10_1.test.skip('Most Common Flow User Flow With All Apps', async ({ page, homePage, modelerHomePage, appsPage, modelerCreatePage, }) => {
30
+ (0, _8_10_1.test)('Most Common Flow User Flow With All Apps', async ({ page, homePage, modelerHomePage, appsPage, modelerCreatePage, formJsPage, }) => {
31
31
  const randomString = await (0, _setup_1.generateRandomStringAsync)(3);
32
32
  const formName = 'New form' + randomString;
33
33
  const processName = 'Zeebe_User_Task_Process' + randomString;
@@ -49,6 +49,8 @@ _8_10_1.test.describe('Smoke Tests', () => {
49
49
  await modelerHomePage.clickFormOption();
50
50
  await modelerHomePage.enterFormName(formName);
51
51
  await modelerHomePage.assertFormBreadcrumbVisible(formName);
52
+ await formJsPage.deployForm(clusterName);
53
+ await (0, sleep_1.sleep)(5000);
52
54
  });
53
55
  await _8_10_1.test.step('Add A BPMN Template To The Project', async () => {
54
56
  await modelerHomePage.clickProjectBreadcrumb();
@@ -3,14 +3,90 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const SM_8_9_1 = require("../../fixtures/SM-8.9");
4
4
  const _setup_1 = require("../../test-setup.js");
5
5
  const apiHelpers_1 = require("../../utils/apiHelpers");
6
+ const sleep_1 = require("../../utils/sleep");
7
+ const randomName_1 = require("../../utils/randomName");
8
+ const CLUSTER_VAR_NAMES = {
9
+ ORIGINAL_JSON: 'ORIGINAL_API_INFO',
10
+ UPDATABLE_JSON: 'UPDATABLE_API_INFO',
11
+ ORIGINAL_STRING: 'ORIGINAL_APP_VERSION',
12
+ UPDATABLE_STRING: 'UPDATABLE_APP_VERSION',
13
+ };
14
+ function getConfigByType(type) {
15
+ const configs = {
16
+ JSON: {
17
+ processName: 'Cluster Variable Original JSON',
18
+ processNameUpdatable: 'Cluster Variable Updatable JSON',
19
+ taskName: 'Preview JSON cluster variables',
20
+ originalVariableName: CLUSTER_VAR_NAMES.ORIGINAL_JSON,
21
+ updatableVariableName: CLUSTER_VAR_NAMES.UPDATABLE_JSON,
22
+ originalValue: originalJsonClusterVariableValue,
23
+ operateVariableName: 'URL',
24
+ randomValuePrefix: 'https://updated.api.com',
25
+ },
26
+ String: {
27
+ processName: 'Cluster Variable Original String',
28
+ processNameUpdatable: 'Cluster Variable Updatable String',
29
+ taskName: 'Preview String cluster variable',
30
+ originalVariableName: CLUSTER_VAR_NAMES.ORIGINAL_STRING,
31
+ updatableVariableName: CLUSTER_VAR_NAMES.UPDATABLE_STRING,
32
+ originalValue: originalStringClusterVariableValue,
33
+ operateVariableName: 'APP_VERSION_VALUE',
34
+ randomValuePrefix: 'v3.0.0-updated',
35
+ },
36
+ };
37
+ return configs[type];
38
+ }
6
39
  let authToken;
7
- let jsonClusterVariableValue;
40
+ let originalJsonClusterVariableValue;
41
+ let originalStringClusterVariableValue;
42
+ let jsonProcessKeyDisplay;
43
+ let jsonProcessKeyUpdate;
44
+ let stringProcessKeyDisplay;
45
+ let stringProcessKeyUpdate;
8
46
  SM_8_9_1.test.describe.configure({ mode: 'parallel' });
9
47
  SM_8_9_1.test.describe('Cluster Variables User Flows', () => {
10
48
  SM_8_9_1.test.beforeAll(async () => {
11
49
  authToken = await (0, apiHelpers_1.authSmAPI)();
12
- await (0, apiHelpers_1.createGlobalClusterVariable)(authToken);
13
- jsonClusterVariableValue = JSON.parse(process.env.CLUSTER_VARIABLE_JSON);
50
+ await Promise.all([
51
+ (0, apiHelpers_1.createJsonClusterVariable)(authToken, 'sm', CLUSTER_VAR_NAMES.ORIGINAL_JSON, process.env.CLUSTER_VARIABLE_JSON_VALUE),
52
+ (0, apiHelpers_1.createJsonClusterVariable)(authToken, 'sm', CLUSTER_VAR_NAMES.UPDATABLE_JSON, process.env.CLUSTER_VARIABLE_JSON_VALUE),
53
+ (0, apiHelpers_1.createStringClusterVariable)(authToken, 'sm', CLUSTER_VAR_NAMES.ORIGINAL_STRING, process.env.CLUSTER_VARIABLE_STRING_VALUE),
54
+ (0, apiHelpers_1.createStringClusterVariable)(authToken, 'sm', CLUSTER_VAR_NAMES.UPDATABLE_STRING, process.env.CLUSTER_VARIABLE_STRING_VALUE),
55
+ ]);
56
+ originalJsonClusterVariableValue = JSON.parse(process.env.CLUSTER_VARIABLE_JSON_VALUE);
57
+ originalStringClusterVariableValue =
58
+ process.env.CLUSTER_VARIABLE_STRING_VALUE;
59
+ const deployments = [
60
+ {
61
+ path: './resources/cluster_variables/cluster_variable_json_readonly.bpmn',
62
+ assignTo: 'jsonProcessKeyDisplay',
63
+ },
64
+ {
65
+ path: './resources/cluster_variables/cluster_variable_json_mutable.bpmn',
66
+ assignTo: 'jsonProcessKeyUpdate',
67
+ },
68
+ {
69
+ path: './resources/cluster_variables/cluster_variable_json_form.form',
70
+ assignTo: null,
71
+ },
72
+ {
73
+ path: './resources/cluster_variables/cluster_variable_string_readonly.bpmn',
74
+ assignTo: 'stringProcessKeyDisplay',
75
+ },
76
+ {
77
+ path: './resources/cluster_variables/cluster_variable_string_mutable.bpmn',
78
+ assignTo: 'stringProcessKeyUpdate',
79
+ },
80
+ {
81
+ path: './resources/cluster_variables/cluster_variable_string_form.form',
82
+ assignTo: null,
83
+ },
84
+ ];
85
+ const deploymentResults = await Promise.all(deployments.map((d) => (0, apiHelpers_1.deployProcess)(d.path, authToken)));
86
+ jsonProcessKeyDisplay = deploymentResults[0];
87
+ jsonProcessKeyUpdate = deploymentResults[1];
88
+ stringProcessKeyDisplay = deploymentResults[3];
89
+ stringProcessKeyUpdate = deploymentResults[4];
14
90
  });
15
91
  SM_8_9_1.test.beforeEach(async ({ navigationPage }, testInfo) => {
16
92
  await navigationPage.goToOperate((testInfo.workerIndex + 1) * 1000);
@@ -20,41 +96,95 @@ SM_8_9_1.test.describe('Cluster Variables User Flows', () => {
20
96
  await (0, _setup_1.captureFailureVideo)(page, testInfo);
21
97
  });
22
98
  SM_8_9_1.test.describe('Global cluster variable', () => {
23
- (0, SM_8_9_1.test)('User deploys a process and accesses global cluster variable on Tasklist', async ({ operateHomePage, operateProcessesPage, operateProcessInstancePage, navigationPage, taskPanelPage, taskDetailsPage, }) => {
24
- SM_8_9_1.test.slow();
25
- const [processKey] = await Promise.all([
26
- (0, apiHelpers_1.deployProcess)('./resources/cluster_variables/cluster_variable_global_scope.bpmn', authToken),
27
- (0, apiHelpers_1.deployProcess)('./resources/cluster_variables/preview_cluster_variables.form', authToken),
28
- ]);
29
- if (processKey == null) {
30
- throw new Error('Failed to deploy process or missing processDefinitionKey');
31
- }
32
- const instanceKey = await (0, apiHelpers_1.createProcessInstance)(String(processKey), authToken);
33
- await SM_8_9_1.test.step('User can access the process on operate', async () => {
34
- await operateHomePage.clickProcessesTab();
35
- await operateProcessesPage.applyMoreFilters('Process Instance Key(s)', String(instanceKey));
36
- await operateProcessesPage.clickProcessInstanceLink(`Cluster Variable Global scope - API INFO`);
37
- await operateProcessInstancePage.assertActiveTokenIsPresent();
99
+ const testConfigs = [
100
+ {
101
+ type: 'JSON',
102
+ processKeyDisplay: () => jsonProcessKeyDisplay,
103
+ processKeyUpdate: () => jsonProcessKeyUpdate,
104
+ },
105
+ {
106
+ type: 'String',
107
+ processKeyDisplay: () => stringProcessKeyDisplay,
108
+ processKeyUpdate: () => stringProcessKeyUpdate,
109
+ },
110
+ ];
111
+ for (const config of testConfigs) {
112
+ (0, SM_8_9_1.test)(`User views ${config.type} cluster variable in Tasklist from readonly process and completes task`, async ({ navigationPage, operateHomePage, operateProcessesPage, operateProcessInstancePage, taskPanelPage, taskDetailsPage, }) => {
113
+ SM_8_9_1.test.slow();
114
+ const derived = getConfigByType(config.type);
115
+ const instanceKey = await (0, apiHelpers_1.createProcessInstance)(String(config.processKeyDisplay()), authToken);
116
+ await SM_8_9_1.test.step('User can access the process on operate', async () => {
117
+ await operateHomePage.clickProcessesTab();
118
+ await operateProcessesPage.applyMoreFilters('Process Instance Key(s)', String(instanceKey));
119
+ await operateProcessesPage.clickProcessInstanceLink(derived.processName);
120
+ await operateProcessInstancePage.assertActiveTokenIsPresent();
121
+ });
122
+ await SM_8_9_1.test.step(`User can view the process with ${config.type} cluster variable on tasklist`, async () => {
123
+ await navigationPage.goToTasklist();
124
+ await (0, sleep_1.sleep)(5000);
125
+ await taskPanelPage.openTask(derived.taskName);
126
+ await taskDetailsPage.clickAssignToMeButton();
127
+ });
128
+ await SM_8_9_1.test.step(`User can view the value of ${config.type} cluster variable and complete the task`, async () => {
129
+ if (config.type === 'JSON') {
130
+ for (const value of Object.values(derived.originalValue)) {
131
+ await taskDetailsPage.assertTextIsPresent(String(value));
132
+ }
133
+ }
134
+ else {
135
+ await taskDetailsPage.assertTextIsPresent(String(derived.originalValue));
136
+ }
137
+ await taskDetailsPage.clickCompleteTaskButton();
138
+ });
139
+ await SM_8_9_1.test.step('User can assert the process is completed on Operate', async () => {
140
+ await navigationPage.goToOperate();
141
+ await operateHomePage.clickProcessesTab();
142
+ await operateProcessesPage.clickProcessCompletedCheckbox();
143
+ await operateProcessesPage.applyMoreFilters('Process Instance Key(s)', String(instanceKey));
144
+ await operateProcessesPage.clickProcessInstanceLink(derived.processName);
145
+ await operateProcessInstancePage.assertProcessCompleteStatusWithRetry();
146
+ });
38
147
  });
39
- await SM_8_9_1.test.step('User can view the process with cluster variables on tasklist', async () => {
40
- await navigationPage.goToTasklist();
41
- await taskPanelPage.openTask(`Preview cluster variables form`);
42
- await taskDetailsPage.clickAssignToMeButton();
148
+ }
149
+ for (const config of testConfigs) {
150
+ (0, SM_8_9_1.test)(`User updates ${config.type} cluster variable in Admin UI and verifies changes in Operate`, async ({ navigationPage, ocIdentityHomePage, ocIdentityClusterVariablesPage, operateHomePage, operateProcessesPage, operateProcessInstancePage, }) => {
151
+ SM_8_9_1.test.slow();
152
+ const derived = getConfigByType(config.type);
153
+ const randomRawValue = await (0, randomName_1.randomNameAgregator)(derived.randomValuePrefix);
154
+ const newValue = config.type === 'JSON'
155
+ ? JSON.stringify({
156
+ endpoint: randomRawValue,
157
+ timeout_ms: '5000',
158
+ array: ['updated_item1', 'updated_item2'],
159
+ })
160
+ : JSON.stringify(randomRawValue);
161
+ await SM_8_9_1.test.step('User navigates to Admin UI', async () => {
162
+ await navigationPage.goToOCIdentity();
163
+ });
164
+ await SM_8_9_1.test.step('User navigates to Cluster Variables tab', async () => {
165
+ await ocIdentityHomePage.clickClusterVariablesTab();
166
+ });
167
+ await SM_8_9_1.test.step(`User verifies ${config.type} cluster variable exists`, async () => {
168
+ await ocIdentityClusterVariablesPage.assertVariableExists(derived.updatableVariableName);
169
+ });
170
+ await SM_8_9_1.test.step(`User updates the ${config.type} cluster variable value`, async () => {
171
+ await ocIdentityClusterVariablesPage.editVariable(derived.updatableVariableName, newValue);
172
+ });
173
+ await SM_8_9_1.test.step(`User creates a process instance with the updated ${config.type} cluster variable`, async () => {
174
+ const instanceKey = await (0, apiHelpers_1.createProcessInstance)(String(config.processKeyUpdate()), authToken);
175
+ await SM_8_9_1.test.step('User navigates to the process instance on Operate', async () => {
176
+ await navigationPage.goToOperate();
177
+ await operateHomePage.clickProcessesTab();
178
+ await operateProcessesPage.clickProcessCompletedCheckbox();
179
+ await operateProcessesPage.applyMoreFilters('Process Instance Key(s)', String(instanceKey));
180
+ await operateProcessesPage.clickProcessInstanceLink(derived.processNameUpdatable);
181
+ await operateProcessInstancePage.assertProcessCompleteStatusWithRetry();
182
+ });
183
+ await SM_8_9_1.test.step(`User verifies the updated ${config.type} cluster variable value is present in process variables`, async () => {
184
+ await operateProcessInstancePage.assertProcessVariableContainsText(derived.operateVariableName, randomRawValue);
185
+ });
186
+ });
43
187
  });
44
- await SM_8_9_1.test.step('User can view the values of cluster variables and complete the task', async () => {
45
- for (const [, value] of Object.entries(jsonClusterVariableValue)) {
46
- await taskDetailsPage.assertTextIsPresent(String(value));
47
- }
48
- await taskDetailsPage.clickCompleteTaskButton();
49
- });
50
- await SM_8_9_1.test.step('User can assert the process is completed on Operate', async () => {
51
- await navigationPage.goToOperate();
52
- await operateHomePage.clickProcessesTab();
53
- await operateProcessesPage.clickProcessCompletedCheckbox();
54
- await operateProcessesPage.applyMoreFilters('Process Instance Key(s)', String(instanceKey));
55
- await operateProcessesPage.clickProcessInstanceLink(`Cluster Variable Global scope - API INFO`);
56
- await operateProcessInstancePage.assertProcessCompleteStatusWithRetry();
57
- });
58
- });
188
+ }
59
189
  });
60
190
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camunda/e2e-test-suite",
3
- "version": "0.0.236",
3
+ "version": "0.0.238",
4
4
  "description": "End-to-end test helpers for Camunda 8",
5
5
  "repository": {
6
6
  "type": "git",