Skip to content

Commit

Permalink
Provide a default constructor for plugin, fixes camunda-community-hub…
Browse files Browse the repository at this point in the history
  • Loading branch information
Harjit Singh committed Jun 29, 2020
1 parent 315c399 commit 4b9a869
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,15 @@ public class ReactorProcessEnginePlugin extends AbstractProcessEnginePlugin {

private boolean reactorListenerFirstOnUserTask = false;

/**
* Default constructor for bean initialization. Uses <code>new CamundaEventBus()</code>.
*
* @see #ReactorProcessEnginePlugin(CamundaEventBus)
*/
public ReactorProcessEnginePlugin() {
this(new CamundaEventBus());
}

public ReactorProcessEnginePlugin(final CamundaEventBus eventBus) {
this.eventBus = eventBus;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,4 +103,11 @@ public void notify(DelegateTask delegateTask) {
verify(task).addCandidateGroup("bar");
verify(task).setName("my task");
}

@Test
public void provides_default_constructor() throws Exception {
ReactorProcessEnginePlugin plugin = new ReactorProcessEnginePlugin();

assertThat(plugin.getEventBus()).isNotNull();
}
}

0 comments on commit 4b9a869

Please sign in to comment.