summaryrefslogtreecommitdiffstats
path: root/tests/test_xmlrpc/xmlrpc_test.py
diff options
context:
space:
mode:
authorJason Gerard DeRose <jderose@redhat.com>2009-01-28 21:21:56 -0700
committerRob Crittenden <rcritten@redhat.com>2009-02-03 15:29:04 -0500
commit48a278047db50f919a45ef82a57a6983804ed523 (patch)
treeef77a52e7e901c86d397343f21b3583ebcf9bd02 /tests/test_xmlrpc/xmlrpc_test.py
parent77e782e2cb5413cde9501568155cce9283ff7b7d (diff)
downloadfreeipa-48a278047db50f919a45ef82a57a6983804ed523.tar.gz
freeipa-48a278047db50f919a45ef82a57a6983804ed523.tar.xz
freeipa-48a278047db50f919a45ef82a57a6983804ed523.zip
Mostly got the test_xmlrpc/ tests working again
Diffstat (limited to 'tests/test_xmlrpc/xmlrpc_test.py')
-rw-r--r--tests/test_xmlrpc/xmlrpc_test.py27
1 files changed, 14 insertions, 13 deletions
diff --git a/tests/test_xmlrpc/xmlrpc_test.py b/tests/test_xmlrpc/xmlrpc_test.py
index 74e6157fb..08f7eab89 100644
--- a/tests/test_xmlrpc/xmlrpc_test.py
+++ b/tests/test_xmlrpc/xmlrpc_test.py
@@ -24,26 +24,27 @@ Base class for all XML-RPC tests
import sys
import socket
import nose
-from ipalib import api
-from ipalib import errors
+from ipalib import api, request
+from ipalib import errors, errors2
-try:
- api.finalize()
-except StandardError:
- pass
-class XMLRPC_test:
+class XMLRPC_test(object):
"""
Base class for all XML-RPC plugin tests
"""
def setUp(self):
- # FIXME: changing Plugin.name from a property to an instance attribute
- # somehow broke this.
- raise nose.SkipTest
try:
- res = api.Command['user_show']('notfound')
- except socket.error:
- raise nose.SkipTest
+ if not api.Backend.xmlclient.isconnected():
+ api.Backend.xmlclient.connect()
+ res = api.Command['user_show'](u'notfound')
+ except errors2.NetworkError:
+ raise nose.SkipTest()
except errors.NotFound:
pass
+
+ def tearDown(self):
+ """
+ nose tear-down fixture.
+ """
+ request.destroy_context()