Cleanup xmlrpc: remove obsolete comments, unused imports. Add test for bytes marshalling.

This commit is contained in:
Florent Xicluna 2011-10-30 20:19:32 +01:00
parent 3fa29f7cd7
commit c4fec937dc
3 changed files with 11 additions and 21 deletions

View file

@ -140,6 +140,9 @@ class XMLRPCTestCase(unittest.TestCase):
('host.tld',
[('Authorization', 'Basic dXNlcg==')], {}))
def test_dump_bytes(self):
self.assertRaises(TypeError, xmlrpclib.dumps, (b"my dog has fleas",))
def test_ssl_presence(self):
try:
import ssl
@ -177,7 +180,7 @@ class FaultTestCase(unittest.TestCase):
self.assertRaises(xmlrpclib.Fault, xmlrpclib.loads, s)
def test_dotted_attribute(self):
# this will raise AttirebuteError because code don't want us to use
# this will raise AttributeError because code don't want us to use
# private methods
self.assertRaises(AttributeError,
xmlrpc.server.resolve_dotted_attribute, str, '__add')