### Question:
CaseDefinitionNewResourceHandler extends AbstractProjectDiagramNewResourceHandler<BPMNDiagramResourceType> { @Override public void createDiagram(Package pkg, String name, NewResourcePresenter presenter, Path path, String setId, String moduleName, Optional<String> projectType) { super.createDiagram(pkg, name, presenter, path, setId, moduleName, Optional.of(ProjectType.CASE.name())); } CaseDefinitionNewResourceHandler(); @Inject  CaseDefinitionNewResourceHandler(final DefinitionManager definitionManager,
                                            final ClientProjectDiagramService projectDiagramService,
                                            final BusyIndicatorView indicatorView,
                                            final BPMNDiagramResourceType projectDiagramResourceType,
                                            final ClientTranslationService translationService,
                                            final CaseHelper caseHelper); @Override String getDescription(); @Override IsWidget getIcon(); @Override void createDiagram(Package pkg, String name, NewResourcePresenter presenter, Path path, String setId,
                              String moduleName, Optional<String> projectType); @Override void acceptContext(Callback<Boolean, Void> callback); List<Profile> getProfiles();  }### Answer:
@Test public void createDiagram() { Package pkg = mock(Package.class); String name = "project"; NewResourcePresenter presenter = mock(NewResourcePresenter.class); Path path = mock(Path.class); String setId = BPMNDefinitionSet.class.getName(); String moduleName = "module"; Optional<String> projectType = Optional.of(ProjectType.CASE.name()); tested.createDiagram(pkg, name, presenter, path, setId, moduleName, projectType); verify(projectDiagramService).create(eq(path), eq(name), eq(setId), eq(moduleName), eq(pkg), eq(projectType), any()); }