commit f74d2b697e708fca949a90fcf03999fd878b3302
Author: Ilias Tsitsimpis <iliastsi@grnet.gr>
Date:   Fri Mar 22 11:27:05 2013 +0200

    Rename AstakosClient's authenticate method to getUserInfo

diff --git a/snf-astakos-client/astakosclient/__init__.py b/snf-astakos-client/astakosclient/__init__.py
index 544d364..ee0fad8 100644
--- a/snf-astakos-client/astakosclient/__init__.py
+++ b/snf-astakos-client/astakosclient/__init__.py
@@ -168,8 +168,8 @@ class AstakosClient():
         return simplejson.loads(unicode(data))
 
     # ------------------------
-    def authenticate(self, token, usage=False):
-        """Check if user is authenticated Astakos user
+    def getUserInfo(self, token, usage=False):
+        """Authenticate user and get user's info as a dictionary
 
         Keyword arguments:
         token   -- user's token (string)
diff --git a/snf-astakos-client/astakosclient/tests.py b/snf-astakos-client/astakosclient/tests.py
index 09c0e64..d9863a6 100644
--- a/snf-astakos-client/astakosclient/tests.py
+++ b/snf-astakos-client/astakosclient/tests.py
@@ -429,7 +429,7 @@ class TestCallAstakos(unittest.TestCase):
 
 
 class TestAuthenticate(unittest.TestCase):
-    """Test cases for function authenticate"""
+    """Test cases for function getUserInfo"""
 
     # ----------------------------------
     # Test the response we get if we don't have internet access
@@ -439,7 +439,7 @@ class TestAuthenticate(unittest.TestCase):
         _mockRequest([_requestOffline])
         try:
             client = AstakosClient("https://example.com", retry=3)
-            client.authenticate(token_1)
+            client.getUserInfo(token_1)
         except AstakosClientException:
             pass
         else:
@@ -452,7 +452,7 @@ class TestAuthenticate(unittest.TestCase):
         _mockRequest([_requestOk])
         try:
             client = AstakosClient("https://example.com", use_pool=pool)
-            client.authenticate(token)
+            client.getUserInfo(token)
         except Unauthorized:
             pass
         except Exception:
@@ -474,7 +474,7 @@ class TestAuthenticate(unittest.TestCase):
         _mockRequest([_requestOk])
         try:
             client = AstakosClient("https://example.com", use_pool=pool)
-            auth_info = client.authenticate(token, usage=usage)
+            auth_info = client.getUserInfo(token, usage=usage)
         except:
             self.fail("Shouldn't raise an Exception")
         self.assertEqual(user_info, auth_info)
@@ -516,12 +516,12 @@ class TestAuthenticate(unittest.TestCase):
     # ----------------------------------
     # Test retry functionality
     def test_OfflineRetry(self):
-        """Test retry functionality for authentication"""
+        """Test retry functionality for getUserInfo"""
         global token_1, user_1
         _mockRequest([_requestOffline, _requestOffline, _requestOk])
         try:
             client = AstakosClient("https://example.com", retry=2)
-            auth_info = client.authenticate(token_1, usage=True)
+            auth_info = client.getUserInfo(token_1, usage=True)
         except:
             self.fail("Shouldn't raise an Exception")
         self.assertEqual(user_1, auth_info)
diff --git a/snf-astakos-client/docs/index.rst b/snf-astakos-client/docs/index.rst
index 09ac121..bb55a4c 100644
--- a/snf-astakos-client/docs/index.rst
+++ b/snf-astakos-client/docs/index.rst
@@ -34,7 +34,7 @@ demonstrates how to get user's info using ``astakosclient``.
     from astakosclient import AstakosClient
 
     client = AstakosClient("https://accounts.example.com")
-    user_info = client.authenticate("UQpYas7ElzWGD5yCcEXtjw==")
+    user_info = client.getUserInfo("UQpYas7ElzWGD5yCcEXtjw==")
     print user_info['username']
 
 Another example where we ask for the username of a user with UUID:
@@ -67,7 +67,7 @@ retry=0, use_pool=False, pool_size=8, logger=None\ **)**
 
     This class provides the following methods:
 
-    **authenticate(**\ token, usage=False\ **)**
+    **getUserInfo(**\ token, usage=False\ **)**
         Given a valid authentication token it returns a dict with the
         correspoinding user's info. If usage is set to True more
         information about user's resources will be returned.
