@camunda/e2e-test-suite 0.0.1003 → 0.0.1005

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.
@@ -42,6 +42,7 @@ declare class ModelerCreatePage {
42
42
  readonly firstPlacedElement: Locator;
43
43
  readonly secondPlacedElement: Locator;
44
44
  readonly appendElementButton: Locator;
45
+ readonly appendIndicator: Locator;
45
46
  readonly payloadInput: Locator;
46
47
  readonly marketPlaceButton: Locator;
47
48
  readonly publicHolidayConnectorOption: Locator;
@@ -176,6 +177,7 @@ declare class ModelerCreatePage {
176
177
  clickFirstPlacedElement(): Promise<void>;
177
178
  clickSecondPlacedElement(): Promise<void>;
178
179
  clickSecondElement(): Promise<void>;
180
+ openAppendCreatePad(): Promise<void>;
179
181
  clickAppendElementButton(): Promise<void>;
180
182
  clickMarketPlaceButton(): Promise<void>;
181
183
  clickPublicHolidayConnectorOption(): Promise<void>;
@@ -48,6 +48,7 @@ class ModelerCreatePage {
48
48
  firstPlacedElement;
49
49
  secondPlacedElement;
50
50
  appendElementButton;
51
+ appendIndicator;
51
52
  payloadInput;
52
53
  marketPlaceButton;
53
54
  publicHolidayConnectorOption;
@@ -120,6 +121,10 @@ class ModelerCreatePage {
120
121
  this.appendElementButton = page
121
122
  .locator('[class="djs-create-pad open djs-append-create-pad"]')
122
123
  .first();
124
+ // Every element keeps an indicator overlay in the DOM and hides the ones
125
+ // that do not apply, so match on the visible call-to-action indicator —
126
+ // the one belonging to the currently selected element.
127
+ this.appendIndicator = page.locator('.djs-append-indicator.selected:visible');
123
128
  this.appendTaskButton = page.getByRole('button', { name: 'Append task' });
124
129
  this.changeTypeButton = page.getByRole('button', {
125
130
  name: 'Change element',
@@ -510,6 +515,7 @@ class ModelerCreatePage {
510
515
  else if (parentElement == 'parallelGateway') {
511
516
  await this.clickSecondPlacedGateway();
512
517
  }
518
+ await this.openAppendCreatePad();
513
519
  await this.appendElementButton.hover();
514
520
  await this.appendEndEventButton.click({ timeout: 120000 });
515
521
  }
@@ -883,6 +889,13 @@ class ModelerCreatePage {
883
889
  await this.endEventCanvas.click({ timeout: 60000 });
884
890
  }
885
891
  async clickConnectToOtherElementButton() {
892
+ // 'Connect to other element' is a create-pad entry
893
+ // (`data-entry-id="connect"`), so the pad has to be open before the entry
894
+ // exists at all. The element this is called on already has an outgoing
895
+ // sequence flow, which is exactly the case that no longer auto-opens the
896
+ // pad since improved-canvas 1.11.0 — go through the append indicator
897
+ // first, which is what clickAppendElementButton does (with its retries).
898
+ await this.clickAppendElementButton();
886
899
  await (0, test_1.expect)(this.connectToOtherElementButton).toBeVisible({
887
900
  timeout: 60000,
888
901
  });
@@ -899,11 +912,35 @@ class ModelerCreatePage {
899
912
  await (0, test_1.expect)(this.secondElement).toBeVisible({ timeout: 60000 });
900
913
  await this.secondElement.click({ timeout: 60000 });
901
914
  }
915
+ // Selecting an element does not open the append create pad on its own. The
916
+ // improved canvas gives the selected element a "+" overlay
917
+ // (.djs-append-indicator) instead, and only a mouseenter on that indicator
918
+ // opens the pad. The pad still opens by itself right after an append, and
919
+ // the indicator is hidden while the pad is open, so both lookups are
920
+ // best-effort and this is a no-op in that case.
921
+ async openAppendCreatePad() {
922
+ const padAlreadyOpen = await this.appendElementButton
923
+ .isVisible()
924
+ .catch(() => false);
925
+ if (padAlreadyOpen) {
926
+ return;
927
+ }
928
+ const indicator = this.appendIndicator.first();
929
+ const indicatorShown = await indicator
930
+ .waitFor({ state: 'visible', timeout: 10000 })
931
+ .then(() => true)
932
+ .catch(() => false);
933
+ if (!indicatorShown) {
934
+ return;
935
+ }
936
+ await indicator.hover({ force: true, timeout: 30000 });
937
+ }
902
938
  async clickAppendElementButton() {
903
939
  const maxRetries = 3;
904
940
  for (let retries = 0; retries < maxRetries; retries++) {
905
941
  try {
906
942
  await this.page.waitForTimeout(1000);
943
+ await this.openAppendCreatePad();
907
944
  await (0, test_1.expect)(this.appendElementButton).toBeVisible({ timeout: 10000 });
908
945
  await this.appendElementButton.hover({ force: true });
909
946
  return;
@@ -1117,6 +1154,7 @@ class ModelerCreatePage {
1117
1154
  async clickFirstPlacedGateway() {
1118
1155
  try {
1119
1156
  await this.firstPlacedGateway.click({ timeout: 60000 });
1157
+ await this.openAppendCreatePad();
1120
1158
  await (0, test_1.expect)(this.appendElementButton).toBeVisible({ timeout: 60000 });
1121
1159
  }
1122
1160
  catch (error) {
@@ -1153,6 +1191,7 @@ class ModelerCreatePage {
1153
1191
  await this.page.reload();
1154
1192
  await (0, sleep_1.sleep)(20000);
1155
1193
  await this.clickFirstPlacedElement();
1194
+ await this.openAppendCreatePad();
1156
1195
  await this.appendElementButton.hover();
1157
1196
  }
1158
1197
  await this.clickAppendGatewayButton();
@@ -40,6 +40,7 @@ declare class ModelerCreatePage {
40
40
  readonly firstPlacedElement: Locator;
41
41
  readonly secondPlacedElement: Locator;
42
42
  readonly appendElementButton: Locator;
43
+ readonly appendIndicator: Locator;
43
44
  readonly payloadInput: Locator;
44
45
  readonly marketPlaceButton: Locator;
45
46
  readonly publicHolidayConnectorOption: Locator;
@@ -176,6 +177,7 @@ declare class ModelerCreatePage {
176
177
  clickFirstPlacedElement(): Promise<void>;
177
178
  clickSecondPlacedElement(): Promise<void>;
178
179
  clickSecondElement(): Promise<void>;
180
+ openAppendCreatePad(): Promise<void>;
179
181
  clickAppendElementButton(): Promise<void>;
180
182
  clickMarketPlaceButton(): Promise<void>;
181
183
  clickPublicHolidayConnectorOption(): Promise<void>;
@@ -46,6 +46,7 @@ class ModelerCreatePage {
46
46
  firstPlacedElement;
47
47
  secondPlacedElement;
48
48
  appendElementButton;
49
+ appendIndicator;
49
50
  payloadInput;
50
51
  marketPlaceButton;
51
52
  publicHolidayConnectorOption;
@@ -120,6 +121,7 @@ class ModelerCreatePage {
120
121
  this.appendElementButton = page
121
122
  .locator('[class="djs-create-pad open djs-append-create-pad"]')
122
123
  .first();
124
+ this.appendIndicator = page.locator('.djs-append-indicator.selected');
123
125
  this.appendTaskButton = page.getByRole('button', { name: 'Append task' });
124
126
  this.changeTypeButton = page.getByRole('button', {
125
127
  name: 'Change element',
@@ -513,6 +515,7 @@ class ModelerCreatePage {
513
515
  else if (parentElement == 'parallelGateway') {
514
516
  await this.clickSecondPlacedGateway();
515
517
  }
518
+ await this.openAppendCreatePad();
516
519
  await this.appendElementButton.hover();
517
520
  await this.appendEndEventButton.click({ timeout: 120000 });
518
521
  }
@@ -835,6 +838,13 @@ class ModelerCreatePage {
835
838
  await this.endEventCanvas.click({ timeout: 60000 });
836
839
  }
837
840
  async clickConnectToOtherElementButton() {
841
+ // 'Connect to other element' is a create-pad entry
842
+ // (`data-entry-id="connect"`), so the pad has to be open before the entry
843
+ // exists at all. The element this is called on already has an outgoing
844
+ // sequence flow, which is exactly the case that no longer auto-opens the
845
+ // pad since improved-canvas 1.11.0 — go through the append indicator
846
+ // first, which is what clickAppendElementButton does (with its retries).
847
+ await this.clickAppendElementButton();
838
848
  await (0, test_1.expect)(this.connectToOtherElementButton).toBeVisible({
839
849
  timeout: 60000,
840
850
  });
@@ -851,11 +861,36 @@ class ModelerCreatePage {
851
861
  await (0, test_1.expect)(this.secondElement).toBeVisible({ timeout: 60000 });
852
862
  await this.secondElement.click({ timeout: 60000 });
853
863
  }
864
+ // Selecting an element no longer opens the append create pad on its own.
865
+ // @camunda/improved-canvas gives the selected element a "+" overlay
866
+ // (.djs-append-indicator) instead, and only a mouseenter on that indicator
867
+ // opens the pad (AppendIndicator#_openMenu) — camunda-hub's own e2e suite
868
+ // does exactly this in its `openAppend` cypress command. The pad still opens
869
+ // by itself right after an append, and the indicator hides once the pad is
870
+ // open, so both lookups are best-effort and this is a no-op in that case.
871
+ async openAppendCreatePad() {
872
+ const padAlreadyOpen = await this.appendElementButton
873
+ .isVisible()
874
+ .catch(() => false);
875
+ if (padAlreadyOpen) {
876
+ return;
877
+ }
878
+ const indicator = this.appendIndicator.first();
879
+ const indicatorShown = await indicator
880
+ .waitFor({ state: 'visible', timeout: 10000 })
881
+ .then(() => true)
882
+ .catch(() => false);
883
+ if (!indicatorShown) {
884
+ return;
885
+ }
886
+ await indicator.hover({ force: true, timeout: 30000 });
887
+ }
854
888
  async clickAppendElementButton() {
855
889
  const maxRetries = 3;
856
890
  for (let retries = 0; retries < maxRetries; retries++) {
857
891
  try {
858
892
  await this.page.waitForTimeout(1000);
893
+ await this.openAppendCreatePad();
859
894
  await (0, test_1.expect)(this.appendElementButton).toBeVisible({ timeout: 10000 });
860
895
  await this.appendElementButton.hover({ force: true });
861
896
  return;
@@ -1065,6 +1100,7 @@ class ModelerCreatePage {
1065
1100
  async clickFirstPlacedGateway() {
1066
1101
  try {
1067
1102
  await this.firstPlacedGateway.click({ timeout: 60000 });
1103
+ await this.openAppendCreatePad();
1068
1104
  await (0, test_1.expect)(this.appendElementButton).toBeVisible({ timeout: 60000 });
1069
1105
  }
1070
1106
  catch (error) {
@@ -1101,6 +1137,7 @@ class ModelerCreatePage {
1101
1137
  await this.page.reload();
1102
1138
  await (0, sleep_1.sleep)(20000);
1103
1139
  await this.clickFirstPlacedElement();
1140
+ await this.openAppendCreatePad();
1104
1141
  await this.appendElementButton.hover();
1105
1142
  }
1106
1143
  await this.clickAppendGatewayButton();
@@ -311,10 +311,7 @@ _8_8_1.test.describe('HTO User Flow Tests', () => {
311
311
  await (0, expectTextWithPagination_1.expectTextWithPagination)(page, processName + '2');
312
312
  });
313
313
  });
314
- // Temporarily skipped pending fix PR #3144:
315
- // https://github.com/camunda/c8-cross-component-e2e-tests/pull/3144
316
- // Re-enable in the same change that lands #3144.
317
- _8_8_1.test.skip('Zeebe User Task With Priority', async ({ page, homePage, modelerHomePage, appsPage, modelerCreatePage, taskPanelPage, taskDetailsPage, operateHomePage, operateProcessesPage, operateProcessInstancePage, }) => {
314
+ (0, _8_8_1.test)('Zeebe User Task With Priority', async ({ page, homePage, modelerHomePage, appsPage, modelerCreatePage, taskPanelPage, taskDetailsPage, operateHomePage, operateProcessesPage, operateProcessInstancePage, }) => {
318
315
  const randomName = await (0, _setup_1.generateRandomStringAsync)(3);
319
316
  const processName = 'Zeebe_User_Task_Process_With_Priority' + randomName;
320
317
  const taskName = 'priorityTest' + randomName;
@@ -37,10 +37,7 @@ _8_8_1.test.describe('Smoke Tests', () => {
37
37
  await (0, _setup_1.captureScreenshot)(page, testInfo);
38
38
  await (0, _setup_1.captureFailureVideo)(page, testInfo);
39
39
  });
40
- // Temporarily skipped pending fix PR #3144:
41
- // https://github.com/camunda/c8-cross-component-e2e-tests/pull/3144
42
- // Re-enable in the same change that lands #3144.
43
- _8_8_1.test.skip('Most Common Flow User Flow With All Apps', async ({ page, homePage, modelerHomePage, appsPage, modelerCreatePage, formJsPage, }) => {
40
+ (0, _8_8_1.test)('Most Common Flow User Flow With All Apps', async ({ page, homePage, modelerHomePage, appsPage, modelerCreatePage, formJsPage, }) => {
44
41
  _8_8_1.test.slow();
45
42
  const randomString = useFixedNames
46
43
  ? 'UpgradeTest'
@@ -301,10 +301,7 @@ _8_9_1.test.describe('HTO User Flow Tests', () => {
301
301
  await (0, expectTextWithPagination_1.expectTextWithPagination)(page, processName + '2');
302
302
  });
303
303
  });
304
- // Temporarily skipped pending fix PR #3144:
305
- // https://github.com/camunda/c8-cross-component-e2e-tests/pull/3144
306
- // Re-enable in the same change that lands #3144.
307
- _8_9_1.test.skip('Zeebe User Task With Priority', async ({ page, homePage, modelerHomePage, appsPage, modelerCreatePage, taskPanelPage, taskDetailsPage, operateHomePage, operateProcessesPage, operateProcessInstancePage, }) => {
304
+ (0, _8_9_1.test)('Zeebe User Task With Priority', async ({ page, homePage, modelerHomePage, appsPage, modelerCreatePage, taskPanelPage, taskDetailsPage, operateHomePage, operateProcessesPage, operateProcessInstancePage, }) => {
308
305
  const randomName = await (0, _setup_1.generateRandomStringAsync)(3);
309
306
  const processName = 'Zeebe_User_Task_Process_With_Priority' + randomName;
310
307
  const taskName = 'priorityTest' + randomName;
@@ -36,10 +36,7 @@ _8_9_1.test.describe('Smoke Tests', () => {
36
36
  await (0, _setup_1.captureScreenshot)(page, testInfo);
37
37
  await (0, _setup_1.captureFailureVideo)(page, testInfo);
38
38
  });
39
- // Temporarily skipped pending fix PR #3144:
40
- // https://github.com/camunda/c8-cross-component-e2e-tests/pull/3144
41
- // Re-enable in the same change that lands #3144.
42
- _8_9_1.test.skip('Most Common Flow User Flow With All Apps', async ({ page, homePage, modelerHomePage, appsPage, modelerCreatePage, formJsPage, }) => {
39
+ (0, _8_9_1.test)('Most Common Flow User Flow With All Apps', async ({ page, homePage, modelerHomePage, appsPage, modelerCreatePage, formJsPage, }) => {
43
40
  _8_9_1.test.slow();
44
41
  const randomString = useFixedNames
45
42
  ? 'UpgradeTest'
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camunda/e2e-test-suite",
3
- "version": "0.0.1003",
3
+ "version": "0.0.1005",
4
4
  "description": "End-to-end test helpers for Camunda 8",
5
5
  "repository": {
6
6
  "type": "git",