From 7707c31b89a330a76c3f275866cf41933b01408c Mon Sep 17 00:00:00 2001 From: alokhyland Date: Tue, 18 Jun 2024 22:01:57 +0530 Subject: [PATCH] resolved test case 6 --- .../features/step_definitions/search.js | 2 ++ .../pages/ui/browser/document_permissions.js | 8 +++++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/packages/nuxeo-web-ui-ftest/features/step_definitions/search.js b/packages/nuxeo-web-ui-ftest/features/step_definitions/search.js index df4b954e4b..27c5421c73 100644 --- a/packages/nuxeo-web-ui-ftest/features/step_definitions/search.js +++ b/packages/nuxeo-web-ui-ftest/features/step_definitions/search.js @@ -228,11 +228,13 @@ Then(/^I share my "(.+)" search with (.+)/, async function (searchName, username await permissionButton.waitForVisible(); console.log('permissionButton',permissionButton) await permissionButton.click(); + console.log('permissionButtonClick') await permissionView.setPermissions(username, { permission: 'Read', timeFrame: 'permanent', notify: false, }); + console.log('permissionView setprmission done') const createPermissionButton = await permissionView.createPermissionButton; console.log('createPermissionButton11111',createPermissionButton) await createPermissionButton.waitForVisible(); diff --git a/packages/nuxeo-web-ui-ftest/pages/ui/browser/document_permissions.js b/packages/nuxeo-web-ui-ftest/pages/ui/browser/document_permissions.js index 29dd62d6f4..f1c9bc497d 100644 --- a/packages/nuxeo-web-ui-ftest/pages/ui/browser/document_permissions.js +++ b/packages/nuxeo-web-ui-ftest/pages/ui/browser/document_permissions.js @@ -93,6 +93,7 @@ export default class DocumentPermissions extends BasePage { } async setPermissions(name, opts) { + console.log('inside set permission 1') opts = opts || {}; const permission = opts.permission || ''; const timeFrame = opts.timeFrame || ''; @@ -101,18 +102,23 @@ export default class DocumentPermissions extends BasePage { const { notify } = opts; if (name) { await this.setFieldValue('userGroup', name); + console.log('inside set permission 2') } await this.setFieldValue('right', permission); + console.log('inside set permission 3') const timeButton = await this.timeFrameButton; - console.log('timeButton', timeButton) + console.log('inside set permission 4', timeButton) await timeButton.click(); + console.log('inside set permission 5') if (timeFrame === 'datebased') { await this.setFieldValue('begin', begin); + console.log('inside set permission 6') if (end) { await this.setFieldValue('end', end); } } await this.setFieldValue('notify', notify); + console.log('inside set permission 7') } async editPermissions(opts) {