yangyichao-mango opened a new issue #3207:
URL: https://github.com/apache/incubator-dolphinscheduler/issues/3207


   **Describe the question**
   
   Part[1] in `ProcessDefinitionServiceTest.testCopyProcessDefinition` actually 
is not used because of the `processDefinition.getName() + "_copy_" + 
System.currentTimeMillis()` param Part[2] in 
`ProcessDefinitionService.copyProcessDefinition`.
   
   Part[1]:
   ```
   Mockito.when(processDefinitionService.createProcessDefinition(
                   loginUser,
                   definition.getProjectName(),
                   definition.getName(),
                   definition.getProcessDefinitionJson(),
                   definition.getDescription(),
                   definition.getLocations(),
                   definition.getConnects())).thenReturn(createProcessResult);
   ```
   
   Part[2]:
   ```
   return createProcessDefinition(
                       loginUser,
                       projectName,
                       processDefinition.getName() + "_copy_" + 
System.currentTimeMillis(),
                       processDefinition.getProcessDefinitionJson(),
                       processDefinition.getDescription(),
                       processDefinition.getLocations(),
                       processDefinition.getConnects());
   ```
   
   **What are the current deficiencies and the benefits of changing or adding 
this test**
   - It will make the test of 
`ProcessDefinitionServiceTest.testCopyProcessDefinition` unstable and pending 
the PR of #3053 .
   
   **Which version of DolphinScheduler:**
    -[dev]


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to