@camunda/e2e-test-suite 0.0.711 → 0.0.713

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.
@@ -63,7 +63,9 @@ class ClusterPage {
63
63
  this.confirmDeleteInput = page.getByRole('textbox', {
64
64
  name: 'Type the word DELETE to confirm',
65
65
  });
66
- this.dangerDeleteButton = page.getByRole('button', { name: 'danger Delete' });
66
+ this.dangerDeleteButton = page
67
+ .getByRole('dialog')
68
+ .getByRole('button', { name: 'Delete' });
67
69
  this.testClusterLink = page.getByRole('link', { name: 'Test Cluster' });
68
70
  this.connectorSecretsTab = page.getByRole('tab', {
69
71
  name: 'Connector Secrets',
@@ -40,7 +40,7 @@ class OperateProcessInstancePage {
40
40
  }
41
41
  async completedIconAssertion() {
42
42
  let retryCount = 0;
43
- const maxRetries = 6;
43
+ const maxRetries = 8;
44
44
  while (retryCount < maxRetries) {
45
45
  try {
46
46
  await (0, test_1.expect)(this.completedIcon).toBeVisible({
@@ -47,8 +47,10 @@ c8Run_8_9_1.test.describe('API tests for V2 @tasklistV2', () => {
47
47
  }).toPass({ ...constants_1.defaultAssertionOptions, timeout: 120000 });
48
48
  });
49
49
  (0, c8Run_8_9_1.test)('Get a inbound connectors list', async ({ request }) => {
50
- const connectorsInboundList = await request.get(process.env.C8RUN_CONNECTORS_API_URL_LATEST + '/inbound');
51
- await (0, apiHelpers_1.assertResponseStatus)(connectorsInboundList, 200);
50
+ await (0, test_1.expect)(async () => {
51
+ const connectorsInboundList = await request.get(process.env.C8RUN_CONNECTORS_API_URL_LATEST + '/inbound');
52
+ await (0, apiHelpers_1.assertResponseStatus)(connectorsInboundList, 200);
53
+ }).toPass({ ...constants_1.defaultAssertionOptions, timeout: 120000 });
52
54
  });
53
55
  (0, c8Run_8_9_1.test)('Search for tasks', async ({ request }) => {
54
56
  const taskList = await request.post('/v2/user-tasks/search');
@@ -274,18 +274,35 @@ exports.validateMcpServerHealth = validateMcpServerHealth;
274
274
  // Guards against the c8Run startup race where the connectors runtime on :8086
275
275
  // comes up later than Zeebe/Operate, leaving process instances stuck "active"
276
276
  // and webhook endpoints unregistered.
277
- async function waitForConnectorsReady(baseUrl = process.env.C8RUN_CONNECTORS_API_URL_LATEST, timeoutMs = 120000) {
277
+ async function waitForConnectorsReady(baseUrl = process.env.C8RUN_CONNECTORS_API_URL_LATEST, timeoutMs = 300000) {
278
278
  if (!baseUrl) {
279
279
  throw new Error('waitForConnectorsReady: missing connectors API URL ' +
280
280
  '(C8RUN_CONNECTORS_API_URL_LATEST).');
281
281
  }
282
282
  const healthEndpoint = `${baseUrl}/actuator/health`;
283
283
  apiRequestContext = await getApiRequestContext();
284
+ // Require several consecutive healthy responses so we proceed only once the
285
+ // runtime has settled, not on a transient early 200 that flips back while
286
+ // connector job workers are still subscribing.
287
+ const requiredConsecutive = 3;
288
+ let consecutiveHealthy = 0;
284
289
  await (0, test_1.expect)(async () => {
285
- const response = await apiRequestContext.get(healthEndpoint, {
286
- timeout: 10000,
287
- });
288
- (0, test_1.expect)(response.status()).toBe(200);
290
+ let response;
291
+ try {
292
+ response = await apiRequestContext.get(healthEndpoint, {
293
+ timeout: 10000,
294
+ });
295
+ }
296
+ catch (error) {
297
+ consecutiveHealthy = 0;
298
+ throw error;
299
+ }
300
+ if (response.status() !== 200) {
301
+ consecutiveHealthy = 0;
302
+ throw new Error(`connectors runtime health returned ${response.status()}`);
303
+ }
304
+ consecutiveHealthy += 1;
305
+ (0, test_1.expect)(consecutiveHealthy).toBeGreaterThanOrEqual(requiredConsecutive);
289
306
  }).toPass({ intervals: [5000, 10000, 15000], timeout: timeoutMs });
290
307
  }
291
308
  exports.waitForConnectorsReady = waitForConnectorsReady;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camunda/e2e-test-suite",
3
- "version": "0.0.711",
3
+ "version": "0.0.713",
4
4
  "description": "End-to-end test helpers for Camunda 8",
5
5
  "repository": {
6
6
  "type": "git",