summaryrefslogtreecommitdiffstats
path: root/tests/test_xmlrpc/xmlrpc_test.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/test_xmlrpc/xmlrpc_test.py')
-rw-r--r--tests/test_xmlrpc/xmlrpc_test.py13
1 files changed, 13 insertions, 0 deletions
diff --git a/tests/test_xmlrpc/xmlrpc_test.py b/tests/test_xmlrpc/xmlrpc_test.py
index 1070196e1..8e626600f 100644
--- a/tests/test_xmlrpc/xmlrpc_test.py
+++ b/tests/test_xmlrpc/xmlrpc_test.py
@@ -26,7 +26,20 @@ import socket
import nose
from ipalib import api, request
from ipalib import errors2
+from ipalib import errors
+# Initialize the API. We do this here so that one can run the tests
+# individually instead of at the top-level. If API.bootstrap()
+# has already been called we continue gracefully. Other errors will be
+# raised.
+try:
+ api.bootstrap(context='cli')
+ api.finalize()
+except StandardError, e:
+ if str(e) == "API.bootstrap() already called":
+ pass
+ else:
+ raise e
class XMLRPC_test(object):
"""