diff options
author | Petr Viktorin <pviktori@redhat.com> | 2015-09-17 17:56:45 +0200 |
---|---|---|
committer | Jan Cholasta <jcholast@redhat.com> | 2015-10-07 10:27:20 +0200 |
commit | e3c05fcb73c5a1081167d73278785bf18d652dab (patch) | |
tree | 2e812fea2e20b5808371975da090a829dd5c66f3 /ipatests/test_xmlrpc | |
parent | 65e3b9edc66d7dfe885df143c16a59588af8192f (diff) | |
download | freeipa-e3c05fcb73c5a1081167d73278785bf18d652dab.tar.gz freeipa-e3c05fcb73c5a1081167d73278785bf18d652dab.tar.xz freeipa-e3c05fcb73c5a1081167d73278785bf18d652dab.zip |
Remove uses of the `types` module
In Python 3, the types module no longer provide alternate names for
built-in types, e.g. `types.StringType` can just be spelled `str`.
NoneType is also removed; it needs to be replaced with type(None)
Reviewed-By: David Kupka <dkupka@redhat.com>
Reviewed-By: Jan Cholasta <jcholast@redhat.com>
Reviewed-By: Martin Basti <mbasti@redhat.com>
Diffstat (limited to 'ipatests/test_xmlrpc')
-rw-r--r-- | ipatests/test_xmlrpc/test_hbactest_plugin.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/ipatests/test_xmlrpc/test_hbactest_plugin.py b/ipatests/test_xmlrpc/test_hbactest_plugin.py index 6f7b0a615..fc6a4118f 100644 --- a/ipatests/test_xmlrpc/test_hbactest_plugin.py +++ b/ipatests/test_xmlrpc/test_hbactest_plugin.py @@ -24,7 +24,6 @@ Test the `ipalib/plugins/hbactest.py` module. from ipatests.test_xmlrpc.xmlrpc_test import XMLRPC_test, assert_attr_equal from ipalib import api from ipalib import errors -from types import NoneType from nose.tools import raises # Test strategy: @@ -114,7 +113,7 @@ class test_hbactest(XMLRPC_test): rules=self.rule_names ) assert ret['value'] == True - assert type(ret['error']) == NoneType + assert ret['error'] is None for i in [0,1,2,3]: assert self.rule_names[i] in ret['matched'] |