class EnabledIfEnvironmentVariableCondition extends AbstractRepeatableAnnotationCondition<EnabledIfEnvironmentVariable>
EnabledIfEnvironmentVariable
Modifier and Type | Field and Description |
---|---|
private static ConditionEvaluationResult |
ENABLED |
Constructor and Description |
---|
EnabledIfEnvironmentVariableCondition() |
Modifier and Type | Method and Description |
---|---|
protected ConditionEvaluationResult |
evaluate(EnabledIfEnvironmentVariable annotation) |
protected java.lang.String |
getEnvironmentVariable(java.lang.String name)
Get the value of the named environment variable.
|
protected ConditionEvaluationResult |
getNoDisabledConditionsEncounteredResult() |
evaluateExecutionCondition
private static final ConditionEvaluationResult ENABLED
protected ConditionEvaluationResult getNoDisabledConditionsEncounteredResult()
protected ConditionEvaluationResult evaluate(EnabledIfEnvironmentVariable annotation)
evaluate
in class AbstractRepeatableAnnotationCondition<EnabledIfEnvironmentVariable>
protected java.lang.String getEnvironmentVariable(java.lang.String name)
The default implementation simply delegates to
System.getenv(String)
. Can be overridden in a subclass for
testing purposes.