added a method to return organizations of the user

This commit is contained in:
Kohsuke Kawaguchi
2012-01-01 09:01:33 -08:00
parent 06ef6e841d
commit 70bc5c59e2
4 changed files with 24 additions and 2 deletions

View File

@@ -38,6 +38,12 @@ public class AppTest extends TestCase {
Set<String> members = gitHub.getOrganization("jenkinsci").getRepository("violations-plugin").getCollaboratorNames();
System.out.println(members.contains("kohsuke"));
}
public void testMemberOrgs() throws Exception {
GitHub gitHub = GitHub.connect();
Set<GHOrganization> o = gitHub.getUser("kohsuke").getOrganizations();
System.out.println(o);
}
public void testApp() throws IOException {
GitHub gitHub = GitHub.connect();