Search in sources :

Example 6 with FullVerifications

use of mockit.FullVerifications in project swagger-parser by swagger-api.

the class ResponseProcessorTest method testProcessResponse.

@Test
public void testProcessResponse(@Injectable final Model responseSchema, @Injectable final Property responseHeader) throws Exception {
    new StrictExpectations() {

        {
            new ModelProcessor(cache, swagger);
            times = 1;
            result = modelProcessor;
            modelProcessor.processModel(responseSchema);
            times = 1;
        }
    };
    Response response = new Response();
    response.setResponseSchema(responseSchema);
    response.addHeader("foo", responseHeader);
    new ResponseProcessor(cache, swagger).processResponse(response);
    new FullVerifications() {

        {
        }
    };
}
Also used : Response(io.swagger.models.Response) StrictExpectations(mockit.StrictExpectations) FullVerifications(mockit.FullVerifications) Test(org.testng.annotations.Test)

Aggregations

FullVerifications (mockit.FullVerifications)6 Test (org.testng.annotations.Test)6 RefProperty (io.swagger.models.properties.RefProperty)4 Operation (io.swagger.models.Operation)1 RefResponse (io.swagger.models.RefResponse)1 Response (io.swagger.models.Response)1 ArrayProperty (io.swagger.models.properties.ArrayProperty)1 MapProperty (io.swagger.models.properties.MapProperty)1 Expectations (mockit.Expectations)1 StrictExpectations (mockit.StrictExpectations)1