ru.integrations.check.condition.StatusCodeCondition Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of CheckingLib Show documentation
Show all versions of CheckingLib Show documentation
This library for help checking response.
The newest version!
package ru.integrations.check.condition;
import io.restassured.response.Response;
import lombok.AllArgsConstructor;
import lombok.NoArgsConstructor;
import lombok.RequiredArgsConstructor;
/**
* Check statusCode.
*/
@RequiredArgsConstructor
public class StatusCodeCondition implements Condition {
private final int expectedStatusCode;
/**
* Check equals status code in status code in response.
*/
@Override
public void check(Response response) {
response.then()
.statusCode(expectedStatusCode);
}
}