From d04d21373f01ff0d4b8aabfb73ea19b2c023f4a0 Mon Sep 17 00:00:00 2001 From: Martin Panter Date: Mon, 6 Jun 2016 02:00:50 +0000 Subject: [PATCH] =?UTF-8?q?Issue=20#27109:=20Add=20InvalidFileException=20?= =?UTF-8?q?to=20=5F=5Fall=5F=5F,=20by=20Jacek=20Ko=C5=82odziej?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Lib/plistlib.py | 2 +- Lib/test/test_plistlib.py | 8 +++++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/Lib/plistlib.py b/Lib/plistlib.py index b66639ca9e5..4f360f32203 100644 --- a/Lib/plistlib.py +++ b/Lib/plistlib.py @@ -47,7 +47,7 @@ Parse Plist example: """ __all__ = [ "readPlist", "writePlist", "readPlistFromBytes", "writePlistToBytes", - "Plist", "Data", "Dict", "FMT_XML", "FMT_BINARY", + "Plist", "Data", "Dict", "InvalidFileException", "FMT_XML", "FMT_BINARY", "load", "dump", "loads", "dumps" ] diff --git a/Lib/test/test_plistlib.py b/Lib/test/test_plistlib.py index 662ed904b0b..60ff9183c2c 100644 --- a/Lib/test/test_plistlib.py +++ b/Lib/test/test_plistlib.py @@ -526,8 +526,14 @@ class TestPlistlibDeprecated(unittest.TestCase): self.assertEqual(cur, in_data) +class MiscTestCase(unittest.TestCase): + def test__all__(self): + blacklist = {"PlistFormat", "PLISTHEADER"} + support.check__all__(self, plistlib, blacklist=blacklist) + + def test_main(): - support.run_unittest(TestPlistlib, TestPlistlibDeprecated) + support.run_unittest(TestPlistlib, TestPlistlibDeprecated, MiscTestCase) if __name__ == '__main__':