Exemplo n.º 1
0
 def test_get_community(self):
     """
     Test Retrieving an community by Id
     """
     dspace= self.dspace
     test_id = 2
     community = Community.get_community(dspace,test_id)
     self.assertEqual(community.id,test_id,"Get community by Id Fails")
Exemplo n.º 2
0
 def get_object(self,id,**kwargs):
     try:
         community = Community.get_community(dspace,id,**dict(kwargs))
         return community
     except Community.DoesNotExist:
         raise Http404