use of de.fraunhofer.iosb.ilt.faaast.service.model.request.GetAllSubmodelsRequest in project FAAAST-Service by FraunhoferIOSB.
the class RequestHandlerManagerTest method testGetAllSubmodelsRequest.
@Test
public void testGetAllSubmodelsRequest() throws ResourceNotFoundException {
when(persistence.get(null, (Reference) null, new OutputModifier())).thenReturn(environment.getSubmodels());
GetAllSubmodelsRequest request = new GetAllSubmodelsRequest.Builder().outputModifier(new OutputModifier()).build();
GetAllSubmodelsResponse response = manager.execute(request);
GetAllSubmodelsResponse expected = new GetAllSubmodelsResponse.Builder().payload(environment.getSubmodels()).statusCode(StatusCode.Success).build();
Assert.assertEquals(expected, response);
}
Aggregations