diff options
author | Petr Viktorin <pviktori@redhat.com> | 2014-12-18 10:22:24 +0100 |
---|---|---|
committer | Tomas Babej <tbabej@redhat.com> | 2015-01-14 11:40:28 +0100 |
commit | 07545569ecbdfdb1aeef6aa1878d827a7e5ddb38 (patch) | |
tree | ad799f3645052dc18d73f5ae622bb31f7989fe29 /ipatests/test_xmlrpc/xmlrpc_test.py | |
parent | 8add23d4015be79699563829ba26a52c7d107ab9 (diff) | |
download | freeipa-07545569ecbdfdb1aeef6aa1878d827a7e5ddb38.tar.gz freeipa-07545569ecbdfdb1aeef6aa1878d827a7e5ddb38.tar.xz freeipa-07545569ecbdfdb1aeef6aa1878d827a7e5ddb38.zip |
test_host_plugin: Use HostTracker fixtures
The racker object "remembers" expected state across several tests,
so only changes (rather than all expected state) need to be specified
in each test. Also, the tracker fixture will make it easy to use hosts
in other test modules.
This change makes the tests independent; any permutation of any subset
of these tests should now pass.
Reviewed-By: Tomas Babej <tbabej@redhat.com>
Diffstat (limited to 'ipatests/test_xmlrpc/xmlrpc_test.py')
-rw-r--r-- | ipatests/test_xmlrpc/xmlrpc_test.py | 29 |
1 files changed, 0 insertions, 29 deletions
diff --git a/ipatests/test_xmlrpc/xmlrpc_test.py b/ipatests/test_xmlrpc/xmlrpc_test.py index acfdf711d..808abae19 100644 --- a/ipatests/test_xmlrpc/xmlrpc_test.py +++ b/ipatests/test_xmlrpc/xmlrpc_test.py @@ -367,32 +367,3 @@ def raises_exact(expected_exception): assert expected_exception.strerror == got_exception.strerror else: raise AssertionError('did not raise!') - - -class RPCTest(XMLRPC_test): - """Base class for RPC tests""" - @classmethod - def setup_class(cls): - super(RPCTest, cls).setup_class() - cls.clean_up() - - @classmethod - def teardown_class(cls): - cls.clean_up() - super(RPCTest, cls).teardown_class() - - @classmethod - def clean_up(self): - """Cleanup run on both setup and teardown - - To be overridden in subclasses. - Usually calls the clean() method. - """ - - @classmethod - def clean(cls, command, *args, **options): - """Run a command, ignoring NotFound/EmptyModlist errors""" - try: - api.Command[command](*args, **options) - except (errors.NotFound, errors.EmptyModlist): - pass |