### Question:
GraphQLEndpoint extends Application { @GET @Path(Constants.ENDPOINT_SCHEMA) @Produces(MediaType.TEXT_PLAIN) public Response getGraphQLSchema() { return Response.ok(graphQLEngine.getSchema()) .build(); }  @Override Set<Object> getSingletons(); @GET @Path(Constants.ENDPOINT_SCHEMA) @Produces(MediaType.TEXT_PLAIN) Response getGraphQLSchema(); @GET @Path(Constants.ENDPOINT_API) @Produces(MediaType.APPLICATION_JSON) Response getGraphQLRequest(@QueryParam(Constants.PARAM_QUERY) String query,
                                      @QueryParam(Constants.PARAM_OPERATION_NAME) String operationName,
                                      @QueryParam(Constants.PARAM_VARIABLES) String jsonVars); @POST @Path(Constants.ENDPOINT_API) @Consumes(MediaType.APPLICATION_JSON) @Produces(MediaType.APPLICATION_JSON) Response postGraphQLRequestAsJson(Map<String, Object> body); @POST @Path(Constants.ENDPOINT_API) @Consumes(Constants.MEDIA_TYPE_GRAPHQL) @Produces(MediaType.APPLICATION_JSON) Response postGraphQLRequestAsGraphQLQuery(String body);  }### Answer:
@Test public void getGraphQLSchema_should_return_ok_with_schema() { when(graphQLEngine.getSchema()) .thenReturn(getSchema()); Response response = graphQLEndpoint.getGraphQLSchema(); assertThat(response, hasStatus(Response.Status.OK)); assertThat(response, hasEntity()); assertEquals(response.getEntity(), getSchema()); }