@Test public void getGists_Anonymous() { responseHeaders.setContentType(MediaType.APPLICATION_JSON); mockServer.expect(requestTo("https: .andExpect(method(GET)) .andRespond(withSuccess(jsonResource("gists-public"), MediaType.APPLICATION_JSON)); List<GitHubGist> gists = gitHub.gistOperations().getGists(); assertEquals(30, gists.size()); }
public List<GitHubGist> getGists() { return asList(restTemplate.getForObject(buildUri("gists"), GitHubGist[].class)); }
GistTemplate extends AbstractGitHubOperations implements GistOperations { public List<GitHubGist> getGists() { return asList(restTemplate.getForObject(buildUri("gists"), GitHubGist[].class)); } }
GistTemplate extends AbstractGitHubOperations implements GistOperations { public List<GitHubGist> getGists() { return asList(restTemplate.getForObject(buildUri("gists"), GitHubGist[].class)); } GistTemplate(RestTemplate restTemplate, boolean isAuthorizedForUser); }
GistTemplate extends AbstractGitHubOperations implements GistOperations { public List<GitHubGist> getGists() { return asList(restTemplate.getForObject(buildUri("gists"), GitHubGist[].class)); } GistTemplate(RestTemplate restTemplate, boolean isAuthorizedForUser); List<GitHubGist> getUserGists(String user); List<GitHubGist> getGists(); List<GitHubGist> getPublicGists(); List<GitHubGist> getStarredGists(); GitHubGist getGist(String id); List<GitHubComment> getGistComments(String id); GitHubComment getGistComment(Long id); }
GistTemplate extends AbstractGitHubOperations implements GistOperations { public List<GitHubGist> getGists() { return asList(restTemplate.getForObject(buildUri("gists"), GitHubGist[].class)); } GistTemplate(RestTemplate restTemplate, boolean isAuthorizedForUser); List<GitHubGist> getUserGists(String user); List<GitHubGist> getGists(); List<GitHubGist> getPublicGists(); List<GitHubGist> getStarredGists(); GitHubGist getGist(String id); List<GitHubComment> getGistComments(String id); GitHubComment getGistComment(Long id);  }