Skip to content

Commit

Permalink
Merge pull request #2940 from Kathrin-Huber/replace_slash
Browse files Browse the repository at this point in the history
remove slash from title
  • Loading branch information
Kathrin-Huber authored Oct 23, 2019
2 parents 3757907 + 38d444a commit 049567c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ public String createTaskString(List<Task> processTasks) {
for (Task processTask : processTasks) {
taskString = taskString.concat(processTask.getTitle());
}
return taskString.replaceAll("\\s", "");
return taskString.replaceAll("\\s", "").replaceAll("/","");
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -256,8 +256,12 @@ public void testCreateTemplatesForProcesses() throws DAOException {
public void testCreateTaskString() throws DAOException {
Assert.assertEquals("FinishedClosedProgressOpenLocked",
migrationService.createTaskString(ServiceManager.getProcessService().getById(1).getTasks()));
List<Task> secondTasks = ServiceManager.getProcessService().getById(2).getTasks();
Assert.assertEquals("AdditionalProcessedandSomeNextOpen",
migrationService.createTaskString(ServiceManager.getProcessService().getById(2).getTasks()));
migrationService.createTaskString(secondTasks));
secondTasks.get(0).setTitle("test/test");
Assert.assertEquals("testtestProcessedandSomeNextOpen",
migrationService.createTaskString(secondTasks));
Assert.assertEquals("",
migrationService.createTaskString(ServiceManager.getProcessService().getById(3).getTasks()));
}
Expand Down

0 comments on commit 049567c

Please sign in to comment.