@camunda/e2e-test-suite 0.0.1655 → 0.0.1656

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.
@@ -204,19 +204,32 @@ async function uploadRestConnectorTemplate(page, modelerHomePage) {
204
204
  // The project list is paginated, so a template uploaded by an earlier run can
205
205
  // sit past the first page. Filter the whole project instead of counting rows.
206
206
  const filterInput = page.getByPlaceholder('Filter table');
207
- await filterInput.fill(REST_CONNECTOR_TEMPLATE_RESOURCE);
208
207
  const templateRow = modelerHomePage.rows.filter({
209
208
  hasText: REST_CONNECTOR_TEMPLATE_RESOURCE,
210
209
  });
211
- const alreadyUploaded = await templateRow
212
- .first()
213
- .waitFor({ state: 'visible', timeout: 15000 })
214
- .then(() => true)
215
- .catch(() => false);
216
- if (alreadyUploaded) {
217
- return;
210
+ // Web Modeler renders the table toolbar (and its "Filter table" search box)
211
+ // only when the project has at least one file. A freshly created project
212
+ // shows the project empty state instead, so there is nothing to filter and
213
+ // the template cannot already be there. This is the *project* empty state
214
+ // (camunda-hub self-managed/8.9: App/Pages/Project/EmptyStateBase.jsx), not
215
+ // the folder one ("This folder doesn't have any content yet."), which only
216
+ // renders inside a sub-folder.
217
+ const emptyProject = page.getByText('It all starts with a process application');
218
+ await (0, test_1.expect)(filterInput.or(emptyProject).first()).toBeVisible({
219
+ timeout: 60000,
220
+ });
221
+ if (await filterInput.isVisible()) {
222
+ await filterInput.fill(REST_CONNECTOR_TEMPLATE_RESOURCE);
223
+ const alreadyUploaded = await templateRow
224
+ .first()
225
+ .waitFor({ state: 'visible', timeout: 15000 })
226
+ .then(() => true)
227
+ .catch(() => false);
228
+ if (alreadyUploaded) {
229
+ return;
230
+ }
231
+ await filterInput.fill('');
218
232
  }
219
- await filterInput.fill('');
220
233
  const buffer = await fetchRestConnectorTemplateV13(page);
221
234
  await modelerHomePage.clickDiagramTypeDropdown();
222
235
  await modelerHomePage.clickUploadFilesButton();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camunda/e2e-test-suite",
3
- "version": "0.0.1655",
3
+ "version": "0.0.1656",
4
4
  "description": "End-to-end test helpers for Camunda 8",
5
5
  "repository": {
6
6
  "type": "git",