1. Olemis Lang
  2. bloodhound-rpc

Commits

Olemis Lang  committed 818dce5

BH RPC : Instantiate server proxy objects in ticket test cases with the help of functional testers

Setup digest auth bby default

  • Participants
  • Parent commits ba8a5d7
  • Branches bloodhound_rpc

Comments (0)

Files changed (2)

File trunk/tracrpc/tests/__init__.py

View file
  • Ignore whitespace
         return newparts.geturl()
 
 
-    class XmlRpcTransportTester(RpcTesterMixin):
+    class XmlRpcTester(RpcTesterMixin):
         """XML-RPC over HTTP. Supports custom transport.
 
         If transport is mnissing fall back to basic auth, default behavior
             return xmlrpclib.ServerProxy(rpc_url, transport=transport)
 
 
-    class XmlRpcDigestTester(XmlRpcTransportTester):
+    class XmlRpcDigestTester(XmlRpcTester):
         """XML-RPC over HTTP Digest authentication.
 
         Based upon

File trunk/tracrpc/tests/ticket.py

View file
  • Ignore whitespace
     
     def setUp(self):
         TracRpcTestCase.setUp(self)
-        self.anon = xmlrpclib.ServerProxy(self.url_anon)
-        self.user = xmlrpclib.ServerProxy(self.url_user)
-        self.admin = xmlrpclib.ServerProxy(self.url_admin)
+        self.anon = self._tester.server_proxy(self.url_anon)
+        self.user = self._tester.server_proxy(self.url_auth, user='user')
+        self.admin = self._tester.server_proxy(self.url_auth, user='admin')
 
     def tearDown(self):
         TracRpcTestCase.tearDown(self)
     
     def setUp(self):
         TracRpcTestCase.setUp(self)
-        self.anon = xmlrpclib.ServerProxy(self.url_anon)
-        self.user = xmlrpclib.ServerProxy(self.url_user)
-        self.admin = xmlrpclib.ServerProxy(self.url_admin)
+        self.anon = self._tester.server_proxy(self.url_anon)
+        self.user = self._tester.server_proxy(self.url_auth, user='user')
+        self.admin = self._tester.server_proxy(self.url_auth, user='admin')
 
     def tearDown(self):
         TracRpcTestCase.tearDown(self)