From adeadfe53566ce6383dfd544646d76e883386cfc Mon Sep 17 00:00:00 2001 From: OZGCloud <ozgcloud@mgm-tp.com> Date: Sat, 2 Jul 2022 20:02:40 +0200 Subject: [PATCH] OZG-2339 OZG-2691 add e2e test --- .../navigation/navigation.e2e-spec.ts | 38 +++++++++++++++++++ .../navigation/navigation.e2e-spec.ts | 14 +++++++ 2 files changed, 52 insertions(+) create mode 100644 goofy-client/apps/goofy-e2e/src/integration/einheitlicher-ansprechpartner/navigation/navigation.e2e-spec.ts diff --git a/goofy-client/apps/goofy-e2e/src/integration/einheitlicher-ansprechpartner/navigation/navigation.e2e-spec.ts b/goofy-client/apps/goofy-e2e/src/integration/einheitlicher-ansprechpartner/navigation/navigation.e2e-spec.ts new file mode 100644 index 0000000000..c0fcd0535b --- /dev/null +++ b/goofy-client/apps/goofy-e2e/src/integration/einheitlicher-ansprechpartner/navigation/navigation.e2e-spec.ts @@ -0,0 +1,38 @@ +import { NavigationE2EComponent } from 'apps/goofy-e2e/src/components/navigation/navigation.e2e.component'; +import { VorgangListE2EComponent } from 'apps/goofy-e2e/src/components/vorgang/vorgang-list.e2e.component'; +import { MainPage, waitForSpinnerToDisappear } from 'apps/goofy-e2e/src/page-objects/main.po'; +import { dropCollections } from 'apps/goofy-e2e/src/support/cypress-helper'; +import { exist, notExist } from 'apps/goofy-e2e/src/support/cypress.util'; +import { loginAsEmil } from 'apps/goofy-e2e/src/support/user-util'; + +describe('Navigation', () => { + const mainPage: MainPage = new MainPage(); + const vorgangList: VorgangListE2EComponent = mainPage.getVorgangList(); + + const navigation: NavigationE2EComponent = mainPage.getNavigation(); + + before(() => { + loginAsEmil(); + + waitForSpinnerToDisappear(); + exist(vorgangList.getRoot()); + }) + + after(() => { + dropCollections(); + }) + + describe('navigation item myVorgaenge', () => { + + it('should not exists', () => { + notExist(navigation.getMyVorgaengeItem()); + }) + }) + + describe('navigation item allVorgaenge', () => { + + it('should exists', () => { + exist(navigation.getAllVorgaengeItem()); + }) + }) +}) \ No newline at end of file diff --git a/goofy-client/apps/goofy-e2e/src/integration/main-tests/navigation/navigation.e2e-spec.ts b/goofy-client/apps/goofy-e2e/src/integration/main-tests/navigation/navigation.e2e-spec.ts index 8f5b997336..ea0f9b68a5 100644 --- a/goofy-client/apps/goofy-e2e/src/integration/main-tests/navigation/navigation.e2e-spec.ts +++ b/goofy-client/apps/goofy-e2e/src/integration/main-tests/navigation/navigation.e2e-spec.ts @@ -36,6 +36,20 @@ describe('Navigation', () => { dropCollections(); }) + describe('navigation item myVorgaenge', () => { + + it('should exists', () => { + exist(navigation.getMyVorgaengeItem()); + }) + }) + + describe('navigation item allVorgaenge', () => { + + it('should exists', () => { + exist(navigation.getAllVorgaengeItem()); + }) + }) + describe('click on my vorgaenge', () => { it('should hide not to user assigned vorgaenge', () => { -- GitLab