Skip to content

Commit

Permalink
GH-872 - Switch test execution log output to use ApplicationModuleIde…
Browse files Browse the repository at this point in the history
…ntifiers.
  • Loading branch information
odrotbohm committed Oct 13, 2024
1 parent f8b88dc commit de46683
Showing 1 changed file with 9 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
import org.springframework.beans.factory.support.BeanDefinitionRegistryPostProcessor;
import org.springframework.context.ConfigurableApplicationContext;
import org.springframework.modulith.core.ApplicationModule;
import org.springframework.modulith.core.ApplicationModuleIdentifier;
import org.springframework.modulith.core.JavaPackage;
import org.springframework.test.context.ContextConfigurationAttributes;
import org.springframework.test.context.ContextCustomizer;
Expand Down Expand Up @@ -112,8 +113,10 @@ private static void logModules(ModuleTestExecution execution) {

logHeadline("Extra includes:");

LOGGER.info("> "
+ extraIncludes.stream().map(ApplicationModule::getName).collect(Collectors.joining(", ")));
LOGGER.info("> " + extraIncludes.stream()
.map(ApplicationModule::getIdentifier)
.map(ApplicationModuleIdentifier::toString)
.collect(Collectors.joining(", ")));
}

var sharedModules = modules.getSharedModules();
Expand All @@ -122,8 +125,10 @@ private static void logModules(ModuleTestExecution execution) {

logHeadline("Shared modules:");

LOGGER.info("> "
+ sharedModules.stream().map(ApplicationModule::getName).collect(Collectors.joining(", ")));
LOGGER.info("> " + sharedModules.stream()
.map(ApplicationModule::getIdentifier)
.map(ApplicationModuleIdentifier::toString)
.collect(Collectors.joining(", ")));
}

var dependencies = execution.getDependencies();
Expand Down

0 comments on commit de46683

Please sign in to comment.