From: Nathan Weinberg Date: Fri, 8 Feb 2019 15:00:08 +0000 (-0500) Subject: mgr/dashboard: Added tab tests to Block menu items X-Git-Tag: v14.1.0~156^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=7a49cfb7182bb956c91bf7f53490014336d657ce;p=ceph-ci.git mgr/dashboard: Added tab tests to Block menu items Fixes: https://tracker.ceph.com/issues/38149 Signed-off-by: Nathan Weinberg --- diff --git a/src/pybind/mgr/dashboard/frontend/e2e/block/images.e2e-spec.ts b/src/pybind/mgr/dashboard/frontend/e2e/block/images.e2e-spec.ts index 19f684ff3e7..f962258f502 100644 --- a/src/pybind/mgr/dashboard/frontend/e2e/block/images.e2e-spec.ts +++ b/src/pybind/mgr/dashboard/frontend/e2e/block/images.e2e-spec.ts @@ -12,8 +12,23 @@ describe('Images page', () => { Helper.checkConsole(); }); - it('should open and show breadcrumb', () => { - page.navigateTo(); - expect(Helper.getBreadcrumbText()).toEqual('Images'); + describe('breadcrumb and tab tests', () => { + beforeAll(() => { + page.navigateTo(); + }); + + it('should open and show breadcrumb', () => { + expect(Helper.getBreadcrumbText()).toEqual('Images'); + }); + + it('should show three tabs', () => { + expect(Helper.getTabsCount()).toEqual(3); + }); + + it('should show text for all tabs', () => { + expect(Helper.getTabText(0)).toEqual('Images'); + expect(Helper.getTabText(1)).toEqual('Trash'); + expect(Helper.getTabText(2)).toEqual('Overall Performance'); + }); }); }); diff --git a/src/pybind/mgr/dashboard/frontend/e2e/block/mirroring.e2e-spec.ts b/src/pybind/mgr/dashboard/frontend/e2e/block/mirroring.e2e-spec.ts index 459524a0fbb..a8f819cc874 100644 --- a/src/pybind/mgr/dashboard/frontend/e2e/block/mirroring.e2e-spec.ts +++ b/src/pybind/mgr/dashboard/frontend/e2e/block/mirroring.e2e-spec.ts @@ -12,8 +12,23 @@ describe('Mirroring page', () => { Helper.checkConsole(); }); - it('should open and show breadcrumb', () => { - page.navigateTo(); - expect(Helper.getBreadcrumbText()).toEqual('Mirroring'); + describe('breadcrumb and tab tests', () => { + beforeAll(() => { + page.navigateTo(); + }); + + it('should open and show breadcrumb', () => { + expect(Helper.getBreadcrumbText()).toEqual('Mirroring'); + }); + + it('should show three tabs', () => { + expect(Helper.getTabsCount()).toEqual(3); + }); + + it('should show text for all tabs', () => { + expect(Helper.getTabText(0)).toEqual('Issues'); + expect(Helper.getTabText(1)).toEqual('Syncing'); + expect(Helper.getTabText(2)).toEqual('Ready'); + }); }); });