use of org.springframework.context.annotation.ConditionContext in project spring-boot by spring-projects.
the class LocalDebugPortAvailableConditionTests method getOutcome.
private ConditionOutcome getOutcome() {
MockEnvironment environment = new MockEnvironment();
EnvironmentTestUtils.addEnvironment(environment, "spring.devtools.remote.debug.local-port:" + this.port);
ConditionContext context = mock(ConditionContext.class);
given(context.getEnvironment()).willReturn(environment);
ConditionOutcome outcome = this.condition.getMatchOutcome(context, null);
return outcome;
}
use of org.springframework.context.annotation.ConditionContext in project spring-boot-admin by codecentric.
the class SpringBootAdminClientEnabledConditionTest method setUp.
@Before
public void setUp() {
condition = new SpringBootAdminClientEnabledCondition();
annotatedTypeMetadata = mock(AnnotatedTypeMetadata.class);
conditionContext = mock(ConditionContext.class);
}
Aggregations