This is an automated email from the ASF dual-hosted git repository. tenthe pushed a commit to branch fix-e2e-tests in repository https://gitbox.apache.org/repos/asf/streampipes.git
commit 5e6154ff9a66bf2198443c7ec04db59f38c525f7 Author: Philipp Zehnder <[email protected]> AuthorDate: Mon Jul 27 11:48:11 2026 +0000 test: update adapter code dialog test --- ui/cypress/support/utils/connect/ConnectBtns.ts | 8 ++++++++ ui/cypress/tests/connect/compact/uiConfiguration.spec.ts | 9 +++++---- .../adapter-code-dialog/adapter-code-dialog.component.html | 8 +++++++- 3 files changed, 20 insertions(+), 5 deletions(-) diff --git a/ui/cypress/support/utils/connect/ConnectBtns.ts b/ui/cypress/support/utils/connect/ConnectBtns.ts index 1d2dcf1d58..a6d0cc8fc6 100644 --- a/ui/cypress/support/utils/connect/ConnectBtns.ts +++ b/ui/cypress/support/utils/connect/ConnectBtns.ts @@ -151,6 +151,14 @@ export class ConnectBtns { return cy.dataCy('show-code-checkbox'); } + public static showAdapterCode() { + return cy.dataCy('show-adapter-code', { timeout: 10000 }); + } + + public static closeAdapterCodeDialog() { + return cy.dataCy('close-adapter-code-dialog', { timeout: 10000 }); + } + public static deleteAdapterAndAssociatedPipelineConfirmation() { return cy.dataCy( 'delete-adapter-and-associated-pipelines-confirmation', diff --git a/ui/cypress/tests/connect/compact/uiConfiguration.spec.ts b/ui/cypress/tests/connect/compact/uiConfiguration.spec.ts index 78f771a9d6..29187cbbb4 100644 --- a/ui/cypress/tests/connect/compact/uiConfiguration.spec.ts +++ b/ui/cypress/tests/connect/compact/uiConfiguration.spec.ts @@ -35,12 +35,13 @@ describe('Test Compact Adapters', () => { .build(); ConnectUtils.addAdapter(adapterInput); + ConnectUtils.startAdapter(adapterInput); - // Validate code editor in start dialog - ConnectBtns.showCodeCheckbox().click(); + // Validate code editor from adapter overview context menu + GeneralUtils.openMenuForRow(adapterInput.adapterName); + ConnectBtns.showAdapterCode().click(); validateCodeEditor(); - - ConnectUtils.startAdapter(adapterInput); + ConnectBtns.closeAdapterCodeDialog().click(); // Validate code editor in adapter details GeneralUtils.openMenuForRow(adapterInput.adapterName); diff --git a/ui/src/app/connect/dialog/adapter-code-dialog/adapter-code-dialog.component.html b/ui/src/app/connect/dialog/adapter-code-dialog/adapter-code-dialog.component.html index 8bcce8d4d0..89023dd15d 100644 --- a/ui/src/app/connect/dialog/adapter-code-dialog/adapter-code-dialog.component.html +++ b/ui/src/app/connect/dialog/adapter-code-dialog/adapter-code-dialog.component.html @@ -30,7 +30,13 @@ </div> <mat-divider></mat-divider> <div class="sp-dialog-actions"> - <button mat-button mat-flat-button class="mat-basic" (click)="close()"> + <button + mat-button + mat-flat-button + class="mat-basic" + data-cy="close-adapter-code-dialog" + (click)="close()" + > {{ 'Close' | translate }} </button> </div>
