All Downloads are FREE. Search and download functionalities are using the official Maven repository.

net.serenitybdd.screenplay.rest.questions.LastResponse Maven / Gradle / Ivy

There is a newer version: 4.2.9
Show newest version
package net.serenitybdd.screenplay.rest.questions;

import io.restassured.response.Response;
import net.serenitybdd.screenplay.Actor;
import net.serenitybdd.screenplay.Question;
import net.serenitybdd.screenplay.annotations.Subject;
import net.serenitybdd.screenplay.rest.abilities.CallAnApi;

@Subject("the response received")
public class LastResponse implements Question {

    @Override
    public Response answeredBy(Actor actor) {
        return CallAnApi.as(actor).getLastResponse();
    }

    public static LastResponse received() {
        return new LastResponse();
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy