### Question:
AWSAuthService { public ResponseEntity<String> listRoles(String token){ Response response = reqProcessor.process("/auth/aws/roles/list","{}",token); return ResponseEntity.status(response.getHttpstatus()).body(response.getResponse()); }  ResponseEntity<String> authenticateEC2(AWSLogin login); ResponseEntity<String> createRole(String token, AWSLoginRole awsLoginRole, UserDetails userDetails); ResponseEntity<String> updateRole(String token, AWSLoginRole awsLoginRole); ResponseEntity<String> deleteRole(String token, String role, UserDetails userDetails); ResponseEntity<String> fetchRole(String token, String role); ResponseEntity<String> listRoles(String token); ResponseEntity<String> configureClient(AWSClientConfiguration awsClientConfiguration, String token); ResponseEntity<String> readClientConfiguration(String token); ResponseEntity<String> createSTSRole(AWSStsRole awsStsRole, String token); ResponseEntity<String> authenticateIAM(AWSIAMLogin awsiamLogin); ResponseEntity<String> authenticate(AWSAuthType authType, AWSAuthLogin awsAuthLogin); Response configureAWSRole(String roleName,String policies,String token );  }### Answer:
@Test public void test_listRoles_successfully() { String token = "5PDrOhsy4ig8L3EpsJZSLAMg"; String responseBody = "{ \"keys\": [\"mytestawsrole\"]}"; Response listResponse = getMockResponse(HttpStatus.OK, true, responseBody); ResponseEntity<String> responseEntityExpected = ResponseEntity.status(HttpStatus.OK).body(responseBody); when(reqProcessor.process("/auth/aws/roles/list", "{}", token)).thenReturn(listResponse); ResponseEntity<String> responseEntity = awsAuthService.listRoles(token); assertEquals(HttpStatus.OK, responseEntity.getStatusCode()); assertEquals(responseEntityExpected, responseEntity); }