public void validateReadPermission(String serverUrl, String personalAccessToken) {
    HttpUrl url = buildUrl(serverUrl, "/rest/api/1.0/repos");
    doGet(personalAccessToken, url, body -> buildGson().fromJson(body, RepositoryList.class));
  }
@Test
  public void validate_read_permission_success() {
    server.enqueue(new MockResponse().setResponseCode(200)
      .setBody(REPOS_BODY));

    underTest.validateReadPermission(server.url("/").toString(), "token");
  }