Permalink
Browse files

first nimbusrest client test working now.

  • Loading branch information...
1 parent 44477cd commit 5474ec66ecf9b3c6b7306fad27f4642d3dde1b30 @clemesha-ooi clemesha-ooi committed Feb 11, 2010
Showing with 4 additions and 6 deletions.
  1. +2 −3 web/src/python/nimbusrest/admin/connection.py
  2. +2 −3 web/src/python/nimbusrest/tests.py
@@ -40,9 +40,8 @@ def add_user(self, user):
udict = {'dn' : user.dn}
- resp = self.post_json('users/', udict)
- print 'resp is None --> ', resp, udict
- return self._user_from_data(resp)
+ u = self.post_json('users/', udict)
+ return self._user_from_data(u)
def get_user(self, user_id):
"""
@@ -10,15 +10,14 @@ class TestNimbusRestClient(unittest.TestCase):
def setUp(self):
self.user = FakeUser()
- self.uri = "http://localhost:4443/admin/"
+ self.uri = "https://localhost:4443/admin"
self.key = "testadmin"
self.secret = "secret"
self.conn = AdminConnection(self.uri, self.key, self.secret)
def test_add_user(self):
resp = self.conn.add_user(self.user)
- print resp
- self.assertEquals(1, 1)
+ self.assertEquals(resp.dn, "test_dn")
if __name__ == '__main__':

0 comments on commit 5474ec6

Please sign in to comment.