diff --git a/e2e/resources/activiti7/subprocessapp.zip b/e2e/resources/activiti7/subprocessapp.zip index f51c06f1ff..73a7747300 100644 Binary files a/e2e/resources/activiti7/subprocessapp.zip and b/e2e/resources/activiti7/subprocessapp.zip differ diff --git a/lib/testing/src/lib/process-services-cloud/resources/resources.json b/lib/testing/src/lib/process-services-cloud/resources/resources.json index d2e69cabee..937c2c0a00 100644 --- a/lib/testing/src/lib/process-services-cloud/resources/resources.json +++ b/lib/testing/src/lib/process-services-cloud/resources/resources.json @@ -262,6 +262,50 @@ "processchild": "processchild", "processparent": "processparent" }, + "contentModels": { + "contentmodelalltypes": { + "name": "contentmodelalltypes", + "singleCustomType": { + "name": "singleCustomType", + "properties": { + "textProperty": "customtypetext", + "longProperty": "customtypelong", + "intProperty": "customtypeint", + "mltextProperty": "customtypemltext", + "booleanProperty": "customtypeboolean", + "floatProperty": "customtypefloat", + "doubleProperty": "customtypedouble", + "dateProperty": "customtypedate", + "datetimeProperty": "customtypedatetime" + } + }, + "singleCustomAspect": { + "name": "singleCustomAspect", + "properties": { + "textProperty": "aspecttext", + "longProperty": "aspectlong", + "intProperty": "aspectint", + "mltextProperty": "aspectmltext", + "booleanProperty": "aspectboolean", + "floatProperty": "aspectfloat", + "doubleProperty": "aspectdouble", + "dateProperty": "aspectdate", + "datetimeProperty": "aspectdatetime" + } + } + }, + "contentmodelonlytypes": { + "name": "contentmodelonlytypes", + "customType1": { + "name": "customType", + "properties": { + "textProperty": "text", + "dateProperty": "date", + "datetimeProperty": "datetime" + } + } + } + }, "security": [ { "role": "ACTIVITI_ADMIN", "groups": [], "users": ["superadminuser"] }, { diff --git a/lib/testing/src/lib/process-services/actions/process.util.ts b/lib/testing/src/lib/process-services/actions/process.util.ts index 519e89f6ff..9d08867310 100644 --- a/lib/testing/src/lib/process-services/actions/process.util.ts +++ b/lib/testing/src/lib/process-services/actions/process.util.ts @@ -43,6 +43,24 @@ export class ProcessUtil { } } + async startProcessByDefinitionNameWithFormValues(appName: string, processDefinitionName: string, values: any, processName?: string): Promise { + try { + const appDefinition = await new ApplicationsUtil(this.api).getAppDefinitionByName(appName); + + const processDefinition = await this.getProcessDefinitionByName(appDefinition.deploymentId, processDefinitionName); + + const startProcessOptions: any = { + processDefinitionId: processDefinition.id, + name: processName ? processName : processDefinitionName + StringUtil.generateRandomString(5).toLowerCase(), + values + }; + + return this.api.apiService.activiti.processApi.startNewProcessInstance(startProcessOptions); + } catch (error) { + Logger.error('Start Process - Service error, Response: ', JSON.parse(JSON.stringify(error))); + } + } + async startProcessOfApp(appName: string, processName?: string): Promise { try { const appDefinition = await new ApplicationsUtil(this.api).getAppDefinitionByName(appName);