mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
[ACA-4307] Move Process task JSON mapping e2e process and task names to ADF resource file (#6778)
* [ACA-4307] Move Process task JSON mapping e2e process and task names to ADF resource file * * Moved display widget methods to ADF testing pack
This commit is contained in:
@@ -17,13 +17,15 @@
|
||||
|
||||
import { FormFields } from '../form-fields';
|
||||
import { by, element, Locator } from 'protractor';
|
||||
import { BrowserVisibility } from '../../../utils/public-api';
|
||||
import { BrowserVisibility, BrowserActions } from '../../../utils/public-api';
|
||||
import { EditJsonDialog } from '../../../dialog/public-api';
|
||||
|
||||
export class DisplayValueWidgetPage {
|
||||
|
||||
formFields: FormFields = new FormFields();
|
||||
labelLocator: Locator = by.css("label[class*='adf-label']");
|
||||
inputLocator: Locator = by.css('input');
|
||||
editJsonDialog = new EditJsonDialog();
|
||||
|
||||
getFieldLabel(fieldId): Promise<string> {
|
||||
return this.formFields.getFieldLabel(fieldId, this.labelLocator);
|
||||
@@ -51,4 +53,19 @@ export class DisplayValueWidgetPage {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
async clickOnDisplayJsonValueWidget(fieldId: string) {
|
||||
const jsonButton = element(by.css(`adf-form-field div[id='field-${fieldId}-container'] button`));
|
||||
await BrowserActions.click(jsonButton);
|
||||
await this.editJsonDialog.checkDialogIsDisplayed();
|
||||
}
|
||||
|
||||
async getDisplayJsonValueDialogContent(): Promise<any> {
|
||||
return JSON.parse(await (<any> this.editJsonDialog.getDialogContent()));
|
||||
}
|
||||
|
||||
async closeDisplayJsonValuedDialog() {
|
||||
await this.editJsonDialog.clickCloseButton();
|
||||
await this.editJsonDialog.checkDialogIsNotDisplayed();
|
||||
}
|
||||
}
|
||||
|
@@ -125,7 +125,8 @@
|
||||
"candidateusersgroup": "candidateusersgroup",
|
||||
"candidateUserProcess": "candidateuserprocess",
|
||||
"outputVariablesMapping": "output-variables-mapping",
|
||||
"outcomeVisibilityProcess": "outcome-visib-process"
|
||||
"outcomeVisibilityProcess": "outcome-visib-process",
|
||||
"restConnectorProcess": "rest-connector-process"
|
||||
},
|
||||
"forms": {
|
||||
"tabVisibilityFields": {
|
||||
@@ -181,7 +182,10 @@
|
||||
}
|
||||
},
|
||||
"formWithJsonWidget": {
|
||||
"name": "form-with-json-widget"
|
||||
"name": "form-with-json-widget",
|
||||
"widgets": {
|
||||
"displayJsonWidgetId": "DisplayJsonWidgetId"
|
||||
}
|
||||
},
|
||||
"formWithAllWidgets": {
|
||||
"name": "form-with-all-widgets"
|
||||
@@ -274,7 +278,8 @@
|
||||
"candidateUserTask": "candidateUserTask",
|
||||
"salesUserTask": "salesuser task",
|
||||
"hrUserTask": "hruser task",
|
||||
"attachLocalFile": "attach local file"
|
||||
"attachLocalFile": "attach local file",
|
||||
"userTaskToShowRestResult": "UserTaskToShowRestResult"
|
||||
},
|
||||
"security": [
|
||||
{
|
||||
@@ -288,7 +293,17 @@
|
||||
"users": ["hruser"]
|
||||
}
|
||||
],
|
||||
"infrastructure": { "connectors": { "restconnector": {} }, "bridges": {} }
|
||||
"infrastructure": { "connectors": { "restconnector": {} }, "bridges": {} },
|
||||
"connectors": {
|
||||
"restConnector": {
|
||||
"response": {
|
||||
"userId": 1,
|
||||
"id": 1,
|
||||
"title": "delectus aut autem",
|
||||
"completed": false
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"SUB_PROCESS_APP": {
|
||||
"name": "subprocessapp",
|
||||
|
Reference in New Issue
Block a user