From ddecdf0beab8353b55867d0c79bdc921d007e8e8 Mon Sep 17 00:00:00 2001 From: Raju Udava <86527202+dstala@users.noreply.github.com> Date: Mon, 19 Jun 2023 17:34:21 +0530 Subject: [PATCH] test: shared grid view, link count verification Signed-off-by: Raju Udava <86527202+dstala@users.noreply.github.com> --- tests/playwright/pages/Dashboard/common/Cell/index.ts | 2 +- tests/playwright/tests/db/viewGridShare.spec.ts | 10 +++++++--- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/tests/playwright/pages/Dashboard/common/Cell/index.ts b/tests/playwright/pages/Dashboard/common/Cell/index.ts index 2b941cb987..c21c756bc6 100644 --- a/tests/playwright/pages/Dashboard/common/Cell/index.ts +++ b/tests/playwright/pages/Dashboard/common/Cell/index.ts @@ -276,7 +276,7 @@ export class CellPageObject extends BasePage { }: CellProps & { count?: number; type?: 'hm' | 'bt' | 'mm'; - value: string[]; + value?: string[]; verifyChildList?: boolean; options?: { singular?: string; plural?: string }; }) { diff --git a/tests/playwright/tests/db/viewGridShare.spec.ts b/tests/playwright/tests/db/viewGridShare.spec.ts index 487a765b60..a4e02daa23 100644 --- a/tests/playwright/tests/db/viewGridShare.spec.ts +++ b/tests/playwright/tests/db/viewGridShare.spec.ts @@ -94,7 +94,11 @@ test.describe('Shared view', () => { // verify virtual records for (const record of expectedVirtualRecordsByDb) { - await sharedPage.grid.cell.verifyVirtualCell({ ...record, verifyChildList: true }); + await sharedPage.grid.cell.verifyVirtualCell({ + ...record, + options: { singular: 'Customer', plural: 'Customers' }, + verifyChildList: true, + }); } /** @@ -284,8 +288,8 @@ const expectedVirtualRecords = [ ]; const sqliteExpectedVirtualRecords = [ - { index: 0, columnHeader: 'Customer List', count: 1, value: ['2'] }, - { index: 1, columnHeader: 'Customer List', count: 1, value: ['1'] }, + { index: 0, columnHeader: 'Customer List', count: 1, type: 'hm' }, + { index: 1, columnHeader: 'Customer List', count: 1, type: 'hm' }, { index: 0, columnHeader: 'City', count: 1, type: 'bt', value: ['Davao'] }, { index: 1, columnHeader: 'City', count: 1, type: 'bt', value: ['Nagareyama'] }, ];