@Operation(summary = "create", description = "CREATE_WORKFLOWS_NOTES")
    @PostMapping(consumes = {"application/json"})
    @ResponseStatus(HttpStatus.CREATED)
    @ApiException(CREATE_PROCESS_DEFINITION_ERROR)
    public Result<ProcessDefinition> createWorkflow(@Parameter(hidden = true) @RequestAttribute(value = Constants.SESSION_USER) User loginUser,
                                                    @RequestBody WorkflowCreateRequest workflowCreateRequest) {
        ProcessDefinition processDefinition =
                processDefinitionService.createSingleProcessDefinition(loginUser, workflowCreateRequest);
        return Result.success(processDefinition);
    }
@Test
    public void testCreateWorkflow() {
        WorkflowCreateRequest workflowCreateRequest = new WorkflowCreateRequest();
        workflowCreateRequest.setName(name);
        workflowCreateRequest.setReleaseState(releaseState);
        workflowCreateRequest.setProjectCode(projectCode);
        workflowCreateRequest.setDescription(description);
        workflowCreateRequest.setGlobalParams(EMPTY_STRING);
        workflowCreateRequest.setTimeout(timeout);
        workflowCreateRequest.setWarningGroupId(warningGroupId);
        workflowCreateRequest.setExecutionType(executionType);

        Mockito.when(processDefinitionService.createSingleProcessDefinition(user, workflowCreateRequest))
                .thenReturn(this.getProcessDefinition(name));
        Result<ProcessDefinition> resourceResponse = workflowV2Controller.createWorkflow(user, workflowCreateRequest);
        Assertions.assertEquals(this.getProcessDefinition(name), resourceResponse.getData());
    }