mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
Cleanup xmlrpc: remove obsolete comments, unused imports. Add test for bytes marshalling.
This commit is contained in:
parent
3fa29f7cd7
commit
c4fec937dc
3 changed files with 11 additions and 21 deletions
|
@ -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')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue