Search in sources :

Example 1 with EnvironmentAware

use of org.springframework.context.EnvironmentAware in project spring-security by spring-projects.

the class AutowireBeanFactoryObjectPostProcessorTests method postProcessWhenEnvironmentAwareThenAwareInvoked.

@Test
public void postProcessWhenEnvironmentAwareThenAwareInvoked() {
    this.spring.register(Config.class).autowire();
    EnvironmentAware toPostProcess = mock(EnvironmentAware.class);
    this.objectObjectPostProcessor.postProcess(toPostProcess);
    verify(toPostProcess).setEnvironment(isNotNull());
}
Also used : EnvironmentAware(org.springframework.context.EnvironmentAware) Test(org.junit.jupiter.api.Test)

Aggregations

Test (org.junit.jupiter.api.Test)1 EnvironmentAware (org.springframework.context.EnvironmentAware)1