Search in sources :

Example 11 with OperationParameters

use of org.springframework.boot.actuate.endpoint.invoke.OperationParameters in project spring-boot by spring-projects.

the class OperationMethodTests method getParametersShouldReturnParameters.

@Test
void getParametersShouldReturnParameters() {
    OperationMethod operationMethod = new OperationMethod(this.exampleMethod, OperationType.READ);
    OperationParameters parameters = operationMethod.getParameters();
    assertThat(parameters.getParameterCount()).isEqualTo(1);
    assertThat(parameters.iterator().next().getName()).isEqualTo("name");
}
Also used : OperationParameters(org.springframework.boot.actuate.endpoint.invoke.OperationParameters) Test(org.junit.jupiter.api.Test)

Aggregations

Test (org.junit.jupiter.api.Test)11 OperationParameters (org.springframework.boot.actuate.endpoint.invoke.OperationParameters)11 OperationInvoker (org.springframework.boot.actuate.endpoint.invoke.OperationInvoker)5