From 3bc726f0c38e039b6dff3b8605d027c60dcf836a Mon Sep 17 00:00:00 2001 From: Patrick Seidensal Date: Mon, 19 Aug 2019 11:47:47 +0200 Subject: [PATCH] mgr/dashboard: migrate E2E filesystems to async/await Fixes: https://tracker.ceph.com/issues/40693 Signed-off-by: Patrick Seidensal --- .../frontend/e2e/filesystems/filesystems.e2e-spec.ts | 12 ++++++------ src/pybind/mgr/dashboard/frontend/e2e/helper.po.ts | 3 +++ 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/src/pybind/mgr/dashboard/frontend/e2e/filesystems/filesystems.e2e-spec.ts b/src/pybind/mgr/dashboard/frontend/e2e/filesystems/filesystems.e2e-spec.ts index 9a90c858580..68b0dfdda65 100644 --- a/src/pybind/mgr/dashboard/frontend/e2e/filesystems/filesystems.e2e-spec.ts +++ b/src/pybind/mgr/dashboard/frontend/e2e/filesystems/filesystems.e2e-spec.ts @@ -7,17 +7,17 @@ describe('Filesystems page', () => { filesystems = new Helper().filesystems; }); - afterEach(() => { - Helper.checkConsole(); + afterEach(async () => { + await Helper.checkConsole(); }); describe('breadcrumb test', () => { - beforeAll(() => { - filesystems.navigateTo(); + beforeAll(async () => { + await filesystems.navigateTo(); }); - it('should open and show breadcrumb', () => { - expect(filesystems.getBreadcrumbText()).toEqual('Filesystems'); + it('should open and show breadcrumb', async () => { + expect(await filesystems.getBreadcrumbText()).toEqual('Filesystems'); }); }); }); diff --git a/src/pybind/mgr/dashboard/frontend/e2e/helper.po.ts b/src/pybind/mgr/dashboard/frontend/e2e/helper.po.ts index b0feafd232e..1671ed1effb 100644 --- a/src/pybind/mgr/dashboard/frontend/e2e/helper.po.ts +++ b/src/pybind/mgr/dashboard/frontend/e2e/helper.po.ts @@ -1,5 +1,6 @@ import { browser } from 'protractor'; import { ImagesPageHelper } from './block/images.po'; +import { FilesystemsPageHelper } from './filesystems/filesystems.po'; import { NfsPageHelper } from './nfs/nfs.po'; import { PoolPageHelper } from './pools/pools.po'; import { BucketsPageHelper } from './rgw/buckets.po'; @@ -21,6 +22,7 @@ export class Helper { daemons: DaemonsPageHelper; users: UsersPageHelper; nfs: NfsPageHelper; + filesystems: FilesystemsPageHelper; constructor() { this.pools = new PoolPageHelper(); @@ -33,6 +35,7 @@ export class Helper { this.daemons = new DaemonsPageHelper(); this.users = new UsersPageHelper(); this.nfs = new NfsPageHelper(); + this.filesystems = new FilesystemsPageHelper(); } /**