mirror of
https://github.com/Alfresco/alfresco-ng2-components.git
synced 2025-07-24 17:32:15 +00:00
AAE 21001 enable AAE e2es (#9411)
* AAE-21001 enable AAE e2es * remove duplicated e2e * [ci:force] trigger ci * [ci:force] trigger ci * fix C286598
This commit is contained in:
@@ -1,122 +0,0 @@
|
|||||||
/*!
|
|
||||||
* @license
|
|
||||||
* Copyright © 2005-2023 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
||||||
*
|
|
||||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
||||||
* you may not use this file except in compliance with the License.
|
|
||||||
* You may obtain a copy of the License at
|
|
||||||
*
|
|
||||||
* http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
*
|
|
||||||
* Unless required by applicable law or agreed to in writing, software
|
|
||||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
||||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
||||||
* See the License for the specific language governing permissions and
|
|
||||||
* limitations under the License.
|
|
||||||
*/
|
|
||||||
|
|
||||||
import { createApiService,
|
|
||||||
AppListCloudPage,
|
|
||||||
LocalStorageUtil,
|
|
||||||
LoginPage,
|
|
||||||
ProcessDefinitionsService,
|
|
||||||
ProcessInstancesService,
|
|
||||||
QueryService,
|
|
||||||
TaskFormCloudComponent,
|
|
||||||
TaskHeaderCloudPage
|
|
||||||
} from '@alfresco/adf-testing';
|
|
||||||
import { browser, protractor } from 'protractor';
|
|
||||||
import { ProcessCloudDemoPage } from './../pages/process-cloud-demo.page';
|
|
||||||
import { ProcessDetailsCloudDemoPage } from './../pages/process-details-cloud-demo.page';
|
|
||||||
import { TasksCloudDemoPage } from './../pages/tasks-cloud-demo.page';
|
|
||||||
import { NavigationBarPage } from '../../core/pages/navigation-bar.page';
|
|
||||||
import { EditProcessFilterConfiguration } from './../config/edit-process-filter.config';
|
|
||||||
import { ProcessListCloudConfiguration } from './../config/process-list-cloud.config';
|
|
||||||
import {
|
|
||||||
ProcessDefinitionCloud,
|
|
||||||
ProcessInstanceCloud,
|
|
||||||
StartTaskCloudResponseModel
|
|
||||||
} from '@alfresco/adf-process-services-cloud';
|
|
||||||
|
|
||||||
describe('Process filters cloud', () => {
|
|
||||||
// en-US values for the process status
|
|
||||||
const PROCESS_STATUS = {
|
|
||||||
ALL: 'All',
|
|
||||||
RUNNING: 'Running',
|
|
||||||
SUSPENDED: 'Suspended',
|
|
||||||
COMPLETED: 'Completed'
|
|
||||||
};
|
|
||||||
|
|
||||||
const loginSSOPage = new LoginPage();
|
|
||||||
const navigationBarPage = new NavigationBarPage();
|
|
||||||
const appListCloudComponent = new AppListCloudPage();
|
|
||||||
const processCloudDemoPage = new ProcessCloudDemoPage();
|
|
||||||
const editProcessFilter = processCloudDemoPage.editProcessFilterCloudComponent();
|
|
||||||
|
|
||||||
const tasksCloudDemoPage = new TasksCloudDemoPage();
|
|
||||||
const editTaskFilter = tasksCloudDemoPage.editTaskFilterCloud;
|
|
||||||
const taskFilter = tasksCloudDemoPage.taskFilterCloudComponent;
|
|
||||||
const taskList = tasksCloudDemoPage.taskListCloudComponent();
|
|
||||||
const processList = processCloudDemoPage.processListCloudComponent();
|
|
||||||
|
|
||||||
const processDetailsCloudDemoPage = new ProcessDetailsCloudDemoPage();
|
|
||||||
const taskHeaderCloudPage = new TaskHeaderCloudPage();
|
|
||||||
const taskFormCloudComponent = new TaskFormCloudComponent();
|
|
||||||
|
|
||||||
const apiService = createApiService();
|
|
||||||
const processDefinitionService = new ProcessDefinitionsService(apiService);
|
|
||||||
const processInstancesService = new ProcessInstancesService(apiService);
|
|
||||||
const queryService = new QueryService(apiService);
|
|
||||||
|
|
||||||
const processListCloudConfigFile = new ProcessListCloudConfiguration().getConfiguration();
|
|
||||||
const editProcessFilterConfigFile = new EditProcessFilterConfiguration().getConfiguration();
|
|
||||||
|
|
||||||
let simpleProcessDefinition: ProcessDefinitionCloud;
|
|
||||||
let processInstance: ProcessInstanceCloud;
|
|
||||||
let taskAssigned: StartTaskCloudResponseModel[];
|
|
||||||
let taskName: string;
|
|
||||||
const simpleApp = browser.params.resources.ACTIVITI_CLOUD_APPS.SIMPLE_APP.name;
|
|
||||||
|
|
||||||
beforeAll(async () => {
|
|
||||||
await apiService.loginWithProfile('hrUser');
|
|
||||||
|
|
||||||
simpleProcessDefinition = (await processDefinitionService
|
|
||||||
.getProcessDefinitionByName(browser.params.resources.ACTIVITI_CLOUD_APPS.SIMPLE_APP.processes.processstring, simpleApp)).entry;
|
|
||||||
processInstance = (await processInstancesService.createProcessInstance(simpleProcessDefinition.key, simpleApp)).entry;
|
|
||||||
taskAssigned = (await queryService.getProcessInstanceTasks(processInstance.id, simpleApp)).list.entries;
|
|
||||||
taskName = browser.params.resources.ACTIVITI_CLOUD_APPS.SIMPLE_APP.tasks.processstring;
|
|
||||||
|
|
||||||
await loginSSOPage.loginWithProfile('hrUser');
|
|
||||||
await LocalStorageUtil.setConfigField('adf-edit-process-filter', JSON.stringify(editProcessFilterConfigFile));
|
|
||||||
await LocalStorageUtil.setConfigField('adf-cloud-process-list', JSON.stringify(processListCloudConfigFile));
|
|
||||||
});
|
|
||||||
|
|
||||||
beforeEach(async () => {
|
|
||||||
await navigationBarPage.navigateToProcessServicesCloudPage();
|
|
||||||
await appListCloudComponent.checkApsContainer();
|
|
||||||
await appListCloudComponent.goToApp(simpleApp);
|
|
||||||
await taskList.checkTaskListIsLoaded();
|
|
||||||
await processCloudDemoPage.processFilterCloudComponent.clickOnProcessFilters();
|
|
||||||
});
|
|
||||||
|
|
||||||
it('[C290040] Should be able to open the Task Details page by clicking on the process name', async () => {
|
|
||||||
await editProcessFilter.openFilter();
|
|
||||||
await editProcessFilter.setAppNameDropDown(simpleApp);
|
|
||||||
await editProcessFilter.setStatusFilterDropDown(PROCESS_STATUS.RUNNING);
|
|
||||||
await editProcessFilter.setProperty('processInstanceId', processInstance.id);
|
|
||||||
|
|
||||||
await processList.getDataTable().selectRow('Id', processInstance.id);
|
|
||||||
await browser.actions().sendKeys(protractor.Key.ENTER).perform();
|
|
||||||
|
|
||||||
await processDetailsCloudDemoPage.checkTaskIsDisplayed(taskName);
|
|
||||||
await browser.navigate().back();
|
|
||||||
|
|
||||||
await taskFilter.clickOnTaskFilters();
|
|
||||||
await editTaskFilter.openFilter();
|
|
||||||
await taskList.checkContentIsDisplayedByName(taskAssigned[0].entry.name);
|
|
||||||
await taskList.selectRow(taskAssigned[0].entry.name);
|
|
||||||
await taskHeaderCloudPage.checkTaskPropertyListIsDisplayed();
|
|
||||||
await expect(await taskFormCloudComponent.getFormTitle()).toContain(taskName);
|
|
||||||
await taskFormCloudComponent.clickCompleteButton();
|
|
||||||
});
|
|
||||||
});
|
|
@@ -120,6 +120,7 @@ describe('Start Task - Custom App', () => {
|
|||||||
fifteenValue: 15,
|
fifteenValue: 15,
|
||||||
twenty: '20',
|
twenty: '20',
|
||||||
twentyValue: 20,
|
twentyValue: 20,
|
||||||
|
twentyFiveValue: 25,
|
||||||
default: '25'
|
default: '25'
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -551,6 +552,7 @@ describe('Start Task - Custom App', () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
it('[C286598] Should be able to see all tasks when choosing All from state drop down', async () => {
|
it('[C286598] Should be able to see all tasks when choosing All from state drop down', async () => {
|
||||||
|
await taskListSinglePage.typeItemsPerPage(itemsPerPage.twentyFiveValue);
|
||||||
await taskListSinglePage.selectState('All');
|
await taskListSinglePage.selectState('All');
|
||||||
await taskListSinglePage.taskList().getDataTable().waitTillContentLoaded();
|
await taskListSinglePage.taskList().getDataTable().waitTillContentLoaded();
|
||||||
|
|
||||||
|
@@ -25,8 +25,6 @@
|
|||||||
"C272812": "https://alfresco.atlassian.net/browse/ACS-6425",
|
"C272812": "https://alfresco.atlassian.net/browse/ACS-6425",
|
||||||
"C274704": "https://alfresco.atlassian.net/browse/ACS-6425",
|
"C274704": "https://alfresco.atlassian.net/browse/ACS-6425",
|
||||||
"C311425": "https://alfresco.atlassian.net/browse/ACS-6425",
|
"C311425": "https://alfresco.atlassian.net/browse/ACS-6425",
|
||||||
"C290040": "https://alfresco.atlassian.net/browse/ACS-6930",
|
|
||||||
"C286598": "https://alfresco.atlassian.net/browse/ACS-6930",
|
|
||||||
"C297509": "https://alfresco.atlassian.net/browse/ACS-6930",
|
"C297509": "https://alfresco.atlassian.net/browse/ACS-6930",
|
||||||
"C299124": "https://alfresco.atlassian.net/browse/ACS-6930",
|
"C299124": "https://alfresco.atlassian.net/browse/ACS-6930",
|
||||||
"C277200": "https://alfresco.atlassian.net/browse/ACS-6930",
|
"C277200": "https://alfresco.atlassian.net/browse/ACS-6930",
|
||||||
|
Reference in New Issue
Block a user