From 4bacd9ff13b712e34e30f7c7f8c06cc57944a7a8 Mon Sep 17 00:00:00 2001 From: OZGCloud <ozgcloud@mgm-tp.com> Date: Tue, 16 May 2023 09:09:17 +0200 Subject: [PATCH] OZG-3808 OZG-3807 wait before click; add missing message change; adjust deprecated function --- .../wiedervorlage-attachment.e2e-spec.ts | 2 +- .../wiedervorlage/wiedervorlage.erledigen.e2e-spec.ts | 3 ++- goofy-client/libs/tech-shared/src/lib/tech.util.ts | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/goofy-client/apps/goofy-e2e/src/integration/main-tests/wiedervorlage-attachment/wiedervorlage-attachment.e2e-spec.ts b/goofy-client/apps/goofy-e2e/src/integration/main-tests/wiedervorlage-attachment/wiedervorlage-attachment.e2e-spec.ts index 02e4aac9dc..f3f8141722 100644 --- a/goofy-client/apps/goofy-e2e/src/integration/main-tests/wiedervorlage-attachment/wiedervorlage-attachment.e2e-spec.ts +++ b/goofy-client/apps/goofy-e2e/src/integration/main-tests/wiedervorlage-attachment/wiedervorlage-attachment.e2e-spec.ts @@ -264,7 +264,7 @@ describe('Wiedervorlage attachments', () => { waitForSpinnerToDisappear(); notContainClass(wiedervorlageContainer.getStatusDot(), 'erledigt'); - contains(snackBar.getMessage(), `Die Wiedervorlage ${WIEDERVORLAGE_WITH_ATTACHMENTS_BETREFF} wurde erledigt`); + contains(snackBar.getMessage(), `Die Wiedervorlage ${WIEDERVORLAGE_WITH_ATTACHMENTS_BETREFF} wurde wiedereröffnet`); }) it('should close snackBar on close', () => { diff --git a/goofy-client/apps/goofy-e2e/src/integration/main-tests/wiedervorlage/wiedervorlage.erledigen.e2e-spec.ts b/goofy-client/apps/goofy-e2e/src/integration/main-tests/wiedervorlage/wiedervorlage.erledigen.e2e-spec.ts index c8faf0611d..155bdfea85 100644 --- a/goofy-client/apps/goofy-e2e/src/integration/main-tests/wiedervorlage/wiedervorlage.erledigen.e2e-spec.ts +++ b/goofy-client/apps/goofy-e2e/src/integration/main-tests/wiedervorlage/wiedervorlage.erledigen.e2e-spec.ts @@ -34,7 +34,7 @@ import { WiedervorlageE2E } from '../../../model/wiedervorlage'; import { MainPage, waitForSpinnerToDisappear, waitforSpinnerToAppear } from '../../../page-objects/main.po'; import { VorgangPage } from '../../../page-objects/vorgang.po'; import { WiedervorlagePage } from '../../../page-objects/wiedervorlage.po'; -import { dropCollections } from '../../../support/cypress-helper'; +import { dropCollections, wait } from '../../../support/cypress-helper'; import { containClass, contains, exist, notContainClass, notExist } from '../../../support/cypress.util'; import { loginAsSabine } from '../../../support/user-util'; import { createVorgang, initVorgang, objectIds } from '../../../support/vorgang-util'; @@ -131,6 +131,7 @@ describe('Wiedervorlage erledigen/wiedereroeffnen', () => { const wiedervorlage: WiedervorlageInVorgangE2EComponent = wiedervorlageContainerInVorgang.getWiedervorlage(wiedervorlageZumWiedereroeffnen.betreff); it('should open wiedervorlage on click', () => { + wait(1000); wiedervorlage.getLink().click(); waitForSpinnerToDisappear(); diff --git a/goofy-client/libs/tech-shared/src/lib/tech.util.ts b/goofy-client/libs/tech-shared/src/lib/tech.util.ts index 2e0eedf68e..79f5c796f4 100644 --- a/goofy-client/libs/tech-shared/src/lib/tech.util.ts +++ b/goofy-client/libs/tech-shared/src/lib/tech.util.ts @@ -64,7 +64,7 @@ export function sleep(delayInMs: number) { } export function getFirstLetter(value: string): string { - return isNil(value) ? null : value.substr(0, 1); + return isNil(value) ? null : value.substring(0, 1); } export function isNotEmpty(value: any): boolean { -- GitLab