[AAE-550] Fix PS cloud test (#5139)

* fix PS cloud test

* fix spell

* separate e2e ps form ps-cloud
This commit is contained in:
Eugenio Romano
2019-10-09 13:57:03 +01:00
committed by GitHub
parent 798768a954
commit 05ce529704
8 changed files with 19 additions and 23 deletions

View File

@@ -97,7 +97,7 @@ export class ProcessCloudDemoPage {
async checkActionExecuted(processInstanceId: string, action: string): Promise<void> {
await BrowserVisibility.waitUntilElementIsVisible(element(by.cssContainingText(`span`, 'Action Menu:')));
await BrowserVisibility.waitUntilElementIsVisible(element(by.cssContainingText(`span`, 'Context Menu:')));
await BrowserVisibility.waitUntilElementIsVisible(element(by.cssContainingText(`span`, 'ProcessInstanceId: ' + processInstanceId)));
await BrowserVisibility.waitUntilElementIsVisible(element(by.cssContainingText(`span`, 'Process Instance ID: ' + processInstanceId)));
await BrowserVisibility.waitUntilElementIsVisible(element(by.cssContainingText(`span`, 'Action Type: ' + action)));
}
}

View File

@@ -45,8 +45,8 @@ export class TasksCloudDemoPage {
contextMenuToggle: ElementFinder = element(by.css('mat-slide-toggle[data-automation-id="contextmenu"]'));
multiSelectionToggle: ElementFinder = element(by.css('mat-slide-toggle[data-automation-id="multiSelection"]'));
testingModeToggle: ElementFinder = element(by.css('mat-slide-toggle[data-automation-id="testingMode"]'));
selectedRows: ElementFinder = element(by.xpath("//div[text()=' Selected rows: ']"));
noOfSelectedRows: ElementArrayFinder = element.all(by.xpath("//div[text()=' Selected rows: ']//li"));
selectedRows: ElementFinder = element(by.xpath("//div[text()=' Selected Rows: ']"));
noOfSelectedRows: ElementArrayFinder = element.all(by.xpath("//div[text()=' Selected Rows: ']//li"));
addActionTitle: ElementFinder = element(by.cssContainingText('.mat-card-title', 'Add Action'));
keyInputField: ElementFinder = element(by.css('input[placeholder="Key"]'));
titleInputField: ElementFinder = element(by.css('input[placeholder="Title"]'));
@@ -150,7 +150,7 @@ export class TasksCloudDemoPage {
async getSelectedTaskRowText(rowNo: string): Promise<string> {
await this.checkSelectedRowsIsDisplayed();
const row: ElementFinder = element(by.xpath(`//div[text()=' Selected rows: ']//li[${rowNo}]`));
const row: ElementFinder = element(by.xpath(`//div[text()=' Selected Rows: ']//li[${rowNo}]`));
return await BrowserActions.getText(row);
}
@@ -180,8 +180,7 @@ export class TasksCloudDemoPage {
async checkActionExecuted(taskId: string, action: string): Promise<void> {
await BrowserVisibility.waitUntilElementIsVisible(element(by.cssContainingText(`span`, 'Action Menu:')));
await BrowserVisibility.waitUntilElementIsVisible(element(by.cssContainingText(`span`, 'Context Menu:')));
await BrowserVisibility.waitUntilElementIsVisible(element(by.cssContainingText(`span`, 'Task Id: ' + taskId)));
await BrowserVisibility.waitUntilElementIsVisible(element(by.cssContainingText(`span`, 'Task ID: ' + taskId)));
await BrowserVisibility.waitUntilElementIsVisible(element(by.cssContainingText(`span`, 'Action Type: ' + action)));
}
}

View File

@@ -192,7 +192,7 @@ describe('Start Task Form', () => {
await tasksCloudDemoPage.openNewTaskForm();
await startTask.checkFormIsDisplayed();
await startTask.addName(standaloneTaskName);
await startTask.selectFormDefinition('StartEventForm');
await startTask.selectFormDefinition(resources.ACTIVITI7_APPS.CANDIDATE_BASE_APP.forms.starteventform);
await startTask.clickStartButton();
await tasksCloudDemoPage.taskListCloudComponent().checkContentIsDisplayedByName(standaloneTaskName);
await tasksCloudDemoPage.taskListCloudComponent().selectRow(standaloneTaskName);
@@ -224,9 +224,9 @@ describe('Start Task Form', () => {
it('[C311428] Should display the Standalone forms based on the flag set', async () => {
await tasksCloudDemoPage.openNewTaskForm();
await startTask.checkFormIsDisplayed();
await startTask.checkFormDefinitionIsNotDisplayed('UploadFileForm');
await startTask.checkFormDefinitionIsDisplayed('StartEventForm');
await startTask.checkFormDefinitionIsDisplayed('FormToTestValidations');
await startTask.checkFormDefinitionIsNotDisplayed('uploadfileform');
await startTask.checkFormDefinitionIsDisplayed(resources.ACTIVITI7_APPS.CANDIDATE_BASE_APP.forms.starteventform);
await startTask.checkFormDefinitionIsDisplayed(resources.ACTIVITI7_APPS.CANDIDATE_BASE_APP.forms.formtotestvalidations);
});
});

View File

@@ -91,7 +91,6 @@ describe('Task list cloud - selection', () => {
it('[C291914] Should not be able to select any row when selection mode is set to None', async () => {
await tasksCloudDemoPage.clickSettingsButton();
await tasksCloudDemoPage.selectSelectionMode('None');
await tasksCloudDemoPage.clickSettingsButton();
await tasksCloudDemoPage.disableDisplayTaskDetails();
await tasksCloudDemoPage.clickAppButton();
await tasksCloudDemoPage.taskListCloudComponent().getDataTable().waitForTableBody();
@@ -104,7 +103,6 @@ describe('Task list cloud - selection', () => {
it('[C291918] Should be able to select only one row when selection mode is set to Single', async () => {
await tasksCloudDemoPage.clickSettingsButton();
await tasksCloudDemoPage.selectSelectionMode('Single');
await tasksCloudDemoPage.clickSettingsButton();
await tasksCloudDemoPage.disableDisplayTaskDetails();
await tasksCloudDemoPage.clickAppButton();
await tasksCloudDemoPage.taskListCloudComponent().getDataTable().waitForTableBody();
@@ -122,8 +120,7 @@ describe('Task list cloud - selection', () => {
it('[C291919] Should be able to select only one row when selection mode is set to Multiple', async () => {
await tasksCloudDemoPage.clickSettingsButton();
await tasksCloudDemoPage.selectSelectionMode('Multiple');
await tasksCloudDemoPage.clickSettingsButton();
await tasksCloudDemoPage.enableMultiSelection();
await tasksCloudDemoPage.disableDisplayTaskDetails();
await tasksCloudDemoPage.clickAppButton();
await tasksCloudDemoPage.taskListCloudComponent().getDataTable().waitForTableBody();
@@ -140,8 +137,6 @@ describe('Task list cloud - selection', () => {
});
it('[C291916] Should be able to select multiple row when multiselect is true', async () => {
await tasksCloudDemoPage.clickSettingsButton();
await tasksCloudDemoPage.enableMultiSelection();
await tasksCloudDemoPage.clickSettingsButton();
await tasksCloudDemoPage.disableDisplayTaskDetails();
await tasksCloudDemoPage.clickAppButton();
@@ -163,8 +158,6 @@ describe('Task list cloud - selection', () => {
});
it('[C291915] Should be possible select all the rows when multiselect is true', async () => {
await tasksCloudDemoPage.clickSettingsButton();
await tasksCloudDemoPage.enableMultiSelection();
await tasksCloudDemoPage.clickSettingsButton();
await tasksCloudDemoPage.disableDisplayTaskDetails();
await tasksCloudDemoPage.clickAppButton();
@@ -178,8 +171,6 @@ describe('Task list cloud - selection', () => {
});
it('[C297472] Should be able to see selected tasks with Multiselection and Testing switched on', async () => {
await tasksCloudDemoPage.clickSettingsButton();
await tasksCloudDemoPage.enableMultiSelection();
await tasksCloudDemoPage.clickSettingsButton();
await tasksCloudDemoPage.enableTestingMode();
await tasksCloudDemoPage.clickAppButton();

View File

@@ -531,6 +531,10 @@ exports.ACTIVITI7_APPS = {
candidateGroupProcess: "candidategroupprocess",
anotherCandidateGroupProcess: "anothercandidategroup",
uploadFileProcess: "uploadfileprocess"
},
forms: {
starteventform: "starteventform",
formtotestvalidations: "formtotestvalidations"
}
},
SIMPLE_APP: {