properties property

Map<String, Object?> get properties

The properties of the slice: spring.autoconfigure.exclude names the auto-configuration modules of the application that are not autoConfigurationNames (the web, cache, security... starters).

Pass them to springBootTest(properties:) first, so the test's own properties can still add to or replace them.

Implementation

Map<String, Object?> get properties {
  final excluded = [
    for (final module in _autoConfigurations)
      if (!autoConfigurationNames.contains(module.name)) module.name,
  ];
  return {
    if (excluded.isNotEmpty)
      'spring.autoconfigure.exclude': excluded.join(','),
  };
}