use of org.springframework.boot.actuate.endpoint.invoke.OperationParameters in project spring-boot by spring-projects.
the class CachingOperationInvokerAdvisorTests method applyWhenHasAtLeaseOneMandatoryParameterShouldNotAddAdvise.
@Test
void applyWhenHasAtLeaseOneMandatoryParameterShouldNotAddAdvise() {
OperationParameters parameters = getParameters("getWithParameters", String.class, String.class);
OperationInvoker advised = this.advisor.apply(EndpointId.of("foo"), OperationType.READ, parameters, this.invoker);
assertThat(advised).isSameAs(this.invoker);
}
use of org.springframework.boot.actuate.endpoint.invoke.OperationParameters in project spring-boot by spring-projects.
the class CachingOperationInvokerAdvisorTests method applyWithMandatoryCachedAndNonCachedShouldAddAdvise.
@Test
void applyWithMandatoryCachedAndNonCachedShouldAddAdvise() {
OperationParameters parameters = getParameters("getWithServerNamespaceAndOtherMandatory", WebServerNamespace.class, String.class);
OperationInvoker advised = this.advisor.apply(EndpointId.of("foo"), OperationType.READ, parameters, this.invoker);
assertThat(advised).isSameAs(this.invoker);
}
use of org.springframework.boot.actuate.endpoint.invoke.OperationParameters in project spring-boot by spring-projects.
the class CachingOperationInvokerAdvisorTests method applyWithApiVersionShouldAddAdvise.
@Test
void applyWithApiVersionShouldAddAdvise() {
OperationParameters parameters = getParameters("getWithApiVersion", ApiVersion.class, String.class);
given(this.timeToLive.apply(any())).willReturn(100L);
assertAdviseIsApplied(parameters);
}
use of org.springframework.boot.actuate.endpoint.invoke.OperationParameters in project spring-boot by spring-projects.
the class CachingOperationInvokerAdvisorTests method applyShouldAddCacheAdvise.
@Test
void applyShouldAddCacheAdvise() {
OperationParameters parameters = getParameters("get");
given(this.timeToLive.apply(any())).willReturn(100L);
assertAdviseIsApplied(parameters);
}
use of org.springframework.boot.actuate.endpoint.invoke.OperationParameters in project spring-boot by spring-projects.
the class CachingOperationInvokerAdvisorTests method applyWithWebServerNamespaceShouldAddAdvise.
@Test
void applyWithWebServerNamespaceShouldAddAdvise() {
OperationParameters parameters = getParameters("getWithServerNamespace", WebServerNamespace.class, String.class);
given(this.timeToLive.apply(any())).willReturn(100L);
assertAdviseIsApplied(parameters);
}
Aggregations