Skip to content

Commit

Permalink
citrusframework#1288: only register listeners when the list of listen…
Browse files Browse the repository at this point in the history
  • Loading branch information
turing85 committed Jan 8, 2025
1 parent e9f6947 commit e69123b
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,10 @@ public void run() {

try (LauncherSession session = LauncherFactory.openSession()) {
Launcher launcher = session.getLauncher();
launcher.registerTestExecutionListeners(testExecutionListeners.toArray(TestExecutionListener[]::new));
if (!testExecutionListeners.isEmpty()) {
launcher.registerTestExecutionListeners(
testExecutionListeners.toArray(TestExecutionListener[]::new));
}

if (printSummary) {
launcher.registerTestExecutionListeners(listener);
Expand Down

0 comments on commit e69123b

Please sign in to comment.