@camunda/e2e-test-suite 0.0.1199 → 0.0.1200
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.
|
@@ -141,6 +141,7 @@ declare class ModelerCreatePage {
|
|
|
141
141
|
clickMarketPlaceButton(): Promise<void>;
|
|
142
142
|
completeDeploymentEndpointConfiguration(): Promise<void>;
|
|
143
143
|
completePlayConfiguration(): Promise<void>;
|
|
144
|
+
private searchAndClickWebhookConnector;
|
|
144
145
|
clickWebhookMessageStartEventConnectorOption(): Promise<void>;
|
|
145
146
|
clickWebhookIdInput(): Promise<void>;
|
|
146
147
|
clearWebhookIdInput(): Promise<void>;
|
|
@@ -718,22 +718,46 @@ class ModelerCreatePage {
|
|
|
718
718
|
}
|
|
719
719
|
}
|
|
720
720
|
}
|
|
721
|
+
async searchAndClickWebhookConnector() {
|
|
722
|
+
// The change-element popup virtualizes its list: connector templates render
|
|
723
|
+
// below the built-in BPMN start events and are not in the queryable DOM
|
|
724
|
+
// slice until the list is filtered. Type into the popup search box (the
|
|
725
|
+
// same `.djs-popup-search input` selector the bpmn-js/hub e2e tests use)
|
|
726
|
+
// so the Webhook Message Start Event Connector entry is rendered before
|
|
727
|
+
// asserting on it. Use pressSequentially (not fill): fill sets the value in
|
|
728
|
+
// one shot and the single input event can land before bpmn-js attaches its
|
|
729
|
+
// search handler during the popup re-render, leaving the list unfiltered so
|
|
730
|
+
// the off-screen connector entry never becomes visible.
|
|
731
|
+
await (0, test_1.expect)(this.changeElementSearchInput).toBeVisible({ timeout: 30000 });
|
|
732
|
+
await this.changeElementSearchInput.click();
|
|
733
|
+
await this.changeElementSearchInput.fill('');
|
|
734
|
+
await this.changeElementSearchInput.pressSequentially('Webhook', {
|
|
735
|
+
delay: 50,
|
|
736
|
+
});
|
|
737
|
+
await (0, test_1.expect)(this.webhookMessageStartEventConnectorOption).toBeVisible({
|
|
738
|
+
timeout: 90000,
|
|
739
|
+
});
|
|
740
|
+
await this.webhookMessageStartEventConnectorOption.click({ timeout: 90000 });
|
|
741
|
+
}
|
|
721
742
|
async clickWebhookMessageStartEventConnectorOption() {
|
|
722
743
|
const maxRetries = 3;
|
|
723
744
|
for (let retries = 0; retries < maxRetries; retries++) {
|
|
724
745
|
try {
|
|
725
|
-
if (retries
|
|
726
|
-
await this.webhookMessageStartEventConnectorOption.click({
|
|
727
|
-
timeout: 30000,
|
|
728
|
-
});
|
|
729
|
-
}
|
|
730
|
-
else {
|
|
746
|
+
if (retries > 0) {
|
|
731
747
|
await this.page.reload();
|
|
732
|
-
await this.changeTypeButton.click({ force: true, timeout: 30000 });
|
|
733
|
-
await this.webhookMessageStartEventConnectorOption.click({
|
|
734
|
-
timeout: 90000,
|
|
735
|
-
});
|
|
736
748
|
}
|
|
749
|
+
// The marketplace import closes the change-element popup, so it is
|
|
750
|
+
// routinely gone by the time this runs; reopen it against the start
|
|
751
|
+
// event before filtering so the popup search input is present.
|
|
752
|
+
const popupOpen = await this.changeElementSearchInput
|
|
753
|
+
.waitFor({ state: 'visible', timeout: retries > 0 ? 5000 : 2000 })
|
|
754
|
+
.then(() => true)
|
|
755
|
+
.catch(() => false);
|
|
756
|
+
if (!popupOpen) {
|
|
757
|
+
await this.clickStartEventElement();
|
|
758
|
+
await this.changeTypeButton.click({ force: true, timeout: 90000 });
|
|
759
|
+
}
|
|
760
|
+
await this.searchAndClickWebhookConnector();
|
|
737
761
|
return;
|
|
738
762
|
}
|
|
739
763
|
catch (error) {
|