### Question:
ExecutionAutoConfiguration { @Bean @Lazy @ConditionalOnMissingBean ExecutionContext executionContext(final AgentProperties agentProperties) { return new ExecutionContext(agentProperties); }  @Bean @Lazy @ConditionalOnMissingBean(LoggingListener.class) LoggingListener loggingListener(); @Bean @Lazy @ConditionalOnMissingBean(ConsoleLogListener.class) ConsoleLogListener consoleLogLoggingListener();  }### Answer:
@Test void executionContext() { contextRunner.run( context -> { Assertions.assertThat(context).hasSingleBean(LoggingListener.class); Assertions.assertThat(context).hasSingleBean(ConsoleLogListener.class); Assertions.assertThat(context).hasSingleBean(ExecutionContext.class); Assertions.assertThat(context).hasSingleBean(JobExecutionStateMachine.class); Assertions.assertThat(context).hasSingleBean(AgentProperties.class); uniqueExecutionStages.forEach( stageClass -> Assertions.assertThat(context).hasSingleBean(stageClass) ); repeatedExecutionStages.forEach( (clazz, count) -> Assertions.assertThat(context).getBeans(clazz).hasSize(count) ); } ); }