@camunda/e2e-test-suite 0.0.875 → 0.0.877

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.
@@ -222,26 +222,23 @@ class TaskDetailsPage {
222
222
  });
223
223
  }
224
224
  async assertPdfPreviewViewerExists() {
225
- const containers = this.page.locator('[class="fjs-documentPreview-single-document-container"]');
226
- const firstPdfViewer = containers
227
- .first()
228
- .locator('.fjs-documentPreview-pdf-viewer');
229
- const lastPdfViewer = containers
230
- .last()
231
- .locator('.fjs-documentPreview-pdf-viewer');
225
+ // Documents render in the order the platform created them, which is not
226
+ // the upload order, so the PDF can sit in any container - including a
227
+ // middle one. Scope the viewer lookup to every document container instead
228
+ // of only the first and the last one.
229
+ const pdfViewer = this.page
230
+ .locator('.fjs-documentPreview-document-container')
231
+ .locator('.fjs-documentPreview-pdf-viewer')
232
+ .first();
232
233
  // The PDF viewer can take longer to mount on AWS clusters; if the first
233
234
  // wait misses, reload once and give the second wait more headroom before
234
235
  // failing the test.
235
236
  try {
236
- await (0, test_1.expect)(firstPdfViewer.or(lastPdfViewer)).toBeVisible({
237
- timeout: 60000,
238
- });
237
+ await (0, test_1.expect)(pdfViewer).toBeVisible({ timeout: 60000 });
239
238
  }
240
239
  catch {
241
240
  await this.page.reload();
242
- await (0, test_1.expect)(firstPdfViewer.or(lastPdfViewer)).toBeVisible({
243
- timeout: 90000,
244
- });
241
+ await (0, test_1.expect)(pdfViewer).toBeVisible({ timeout: 90000 });
245
242
  }
246
243
  }
247
244
  async clickSubmitButton() {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camunda/e2e-test-suite",
3
- "version": "0.0.875",
3
+ "version": "0.0.877",
4
4
  "description": "End-to-end test helpers for Camunda 8",
5
5
  "repository": {
6
6
  "type": "git",