diff options
author | Rob Crittenden <rcritten@redhat.com> | 2009-02-03 15:03:17 -0500 |
---|---|---|
committer | Rob Crittenden <rcritten@redhat.com> | 2009-02-04 09:03:40 -0500 |
commit | 98d4644bff67a6545cada8364c84b43e2a99fe62 (patch) | |
tree | 46ab8a3f30bd11b7ca1a8780c0c57da75330f437 /tests/test_xmlrpc/xmlrpc_test.py | |
parent | 2d7e0de5ea7a2923708006bc58dae4b35b65fe63 (diff) | |
download | freeipa-98d4644bff67a6545cada8364c84b43e2a99fe62.tar.gz freeipa-98d4644bff67a6545cada8364c84b43e2a99fe62.tar.xz freeipa-98d4644bff67a6545cada8364c84b43e2a99fe62.zip |
Fix remaining issues with XML-RPC test cases
Tied the make-test script into the test target of the top-level Makefile
Added code to xmlrpc_test.py so that it configures the API if it isn't
already done which enables individual tests to be executed.
Diffstat (limited to 'tests/test_xmlrpc/xmlrpc_test.py')
-rw-r--r-- | tests/test_xmlrpc/xmlrpc_test.py | 13 |
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): """ |