formatting work
This commit is contained in:
@@ -8,21 +8,21 @@ import org.springframework.http.HttpStatus;
|
||||
import static org.hamcrest.MatcherAssert.assertThat;
|
||||
import static org.hamcrest.Matchers.is;
|
||||
|
||||
public class StepDefs extends SpringIntegrationTest{
|
||||
|
||||
@When("^the client calls /version$")
|
||||
public void the_client_issues_GET_version() throws Throwable{
|
||||
public class StepDefs extends SpringIntegrationTest {
|
||||
|
||||
@When("^the client calls /version$")
|
||||
public void the_client_issues_GET_version() throws Throwable {
|
||||
executeGet("http://localhost:8080/version");
|
||||
}
|
||||
|
||||
@Then("^the client receives status code of (\\d+)$")
|
||||
public void the_client_receives_status_code_of(int statusCode) throws Throwable{
|
||||
public void the_client_receives_status_code_of(int statusCode) throws Throwable {
|
||||
final HttpStatus currentStatusCode = latestResponse.getTheResponse().getStatusCode();
|
||||
assertThat("status code is incorrect : "+ latestResponse.getBody(), currentStatusCode.value(), is(statusCode) );
|
||||
assertThat("status code is incorrect : " + latestResponse.getBody(), currentStatusCode.value(), is(statusCode));
|
||||
}
|
||||
|
||||
@And("^the client receives server version (.+)$")
|
||||
public void the_client_receives_server_version_body(String version) throws Throwable{
|
||||
assertThat(latestResponse.getBody(), is(version)) ;
|
||||
public void the_client_receives_server_version_body(String version) throws Throwable {
|
||||
assertThat(latestResponse.getBody(), is(version));
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user