forked from pool/python
There is no InvalidFileException
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:Factory/python?expand=0&rev=388
This commit is contained in:
parent
e20f9250e8
commit
58f1758208
@ -31,7 +31,7 @@ Co-authored-by: Ned Deily <nad@python.org>
|
||||
+ # vulnerabilies in expat. Regular plist files don't contain
|
||||
+ # those declerations, and Apple's plutil tool does not accept
|
||||
+ # them either.
|
||||
+ raise InvalidFileException(
|
||||
+ raise ValueError(
|
||||
+ "XML entity declarations are not supported in plist files")
|
||||
+
|
||||
def handleBeginElement(self, element, attrs):
|
||||
@ -64,7 +64,7 @@ Co-authored-by: Ned Deily <nad@python.org>
|
||||
self.assertEqual(test2, result2)
|
||||
|
||||
+ def test_xml_plist_with_entity_decl(self):
|
||||
+ with self.assertRaisesRegexp(plistlib.InvalidFileException,
|
||||
+ with self.assertRaisesRegexp(ValueError,
|
||||
+ "XML entity declarations are not supported"):
|
||||
+ plistlib.readPlistFromString(XML_PLIST_WITH_ENTITY)
|
||||
+
|
||||
|
Loading…
x
Reference in New Issue
Block a user