Test AuthenticatedUser watching

This commit is contained in:
Vincent Jacques
2012-05-22 19:19:31 +01:00
parent 287bc54154
commit 588a4a9a35
2 changed files with 49 additions and 0 deletions
+9
View File
@@ -94,3 +94,12 @@ class AuthenticatedUser( Framework.TestCase ):
self.user.add_to_following( nvie )
self.assertEqual( self.user.has_in_following( nvie ), True )
self.assertEqual( self.user.get_followers()[ 0 ].login, "jnorthrup" )
def testWatching( self ):
gitflow = self.g.get_user( "nvie" ).get_repo( "gitflow" )
self.assertEqual( self.user.get_watched()[ 0 ].name, "git" )
self.assertEqual( self.user.has_in_watched( gitflow ), True )
self.user.remove_from_watched( gitflow )
self.assertEqual( self.user.has_in_watched( gitflow ), False )
self.user.add_to_watched( gitflow )
self.assertEqual( self.user.has_in_watched( gitflow ), True )
File diff suppressed because one or more lines are too long