Update of /cvsroot/python/python/dist/src/Lib/test In directory usw-pr-cvs1:/tmp/cvs-serv931/Lib/test Modified Files: test_minidom.py Log Message: Implement the encoding argument for toxml and toprettyxml. Document toprettyxml. Index: test_minidom.py =================================================================== RCS file: /cvsroot/python/python/dist/src/Lib/test/test_minidom.py,v retrieving revision 1.31 retrieving revision 1.32 diff -C2 -d -r1.31 -r1.32 *** test_minidom.py 6 Dec 2001 18:27:48 -0000 1.31 --- test_minidom.py 30 Jun 2002 15:05:00 -0000 1.32 *************** *** 607,610 **** --- 607,618 ---- doc.unlink() + def testEncodings(): + doc = parseString('<foo>€</foo>') + confirm(doc.toxml() == u'<?xml version="1.0" ?>\n<foo>\u20ac</foo>' + and doc.toxml('utf-8') == '<?xml version="1.0" encoding="utf-8"?>\n<foo>\xe2\x82\xac</foo>' + and doc.toxml('iso-8859-15') == '<?xml version="1.0" encoding="iso-8859-15"?>\n<foo>\xa4</foo>', + "testEncodings - encoding EURO SIGN") + doc.unlink() + # --- MAIN PROGRAM
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4