AuthenticatedUser.xxx_emails

This commit is contained in:
Vincent Jacques
2012-02-25 10:10:55 +00:00
parent 307b6a85c7
commit bf1ffbde5e
4 changed files with 20 additions and 7 deletions
+6 -4
View File
@@ -116,9 +116,9 @@ class IntegrationTest:
self.doSomeWrites()
def doSomeReads( self ):
self.dumpUser( self.g.get_user(), doHasInFollowing = True )
self.dumpUser( self.g.get_user(), doPrivateThings = True )
jacquev6 = self.g.get_user( "jacquev6" )
self.dumpUser( jacquev6, doHasInFollowing = False )
self.dumpUser( jacquev6, doPrivateThings = False )
self.dumpOrganization( self.g.get_organization( "github" ), doTeams = False )
self.dumpOrganization( self.g.get_organization( "BeaverSoftware" ), doTeams = True )
self.dumpRepository( jacquev6.get_repo( "PyGithub" ) )
@@ -177,7 +177,7 @@ class IntegrationTest:
self.dumpRepository( r )
def dumpUser( self, u, doHasInFollowing ):
def dumpUser( self, u, doPrivateThings ):
print u.login, "(", u.name, ")"
print " Repos:"
for r in u.get_repos():
@@ -186,10 +186,12 @@ class IntegrationTest:
print "<-", r.parent.owner.login + "/" + r.parent.name,
print "<-", r.source.owner.login + "/" + r.source.name,
print
if doPrivateThings:
print " Emails:", ", ".join( u.get_emails() )
print " Watched:", ", ".join( r.name for r in u.get_watched() )
print " Organizations:", ", ".join( o.login for o in u.get_orgs() )
print " Following:", ", ".join( f.login for f in u.get_following() )
if doHasInFollowing:
if doPrivateThings:
print " Is following jacquev6:", u.has_in_following( self.g.get_user( "jacquev6" ) )
print " Followers:", ", ".join( f.login for f in u.get_followers() )
print