summaryrefslogtreecommitdiff
path: root/Lib
diff options
context:
space:
mode:
authorMartin Panter <vadmium+py@gmail.com>2016-06-06 01:59:19 +0000
committerMartin Panter <vadmium+py@gmail.com>2016-06-06 01:59:19 +0000
commit75ad320ffdeeb2fd8c26340ec82f9d738dd4dfcf (patch)
tree7b2033fca25f20b015d72be490ae71feed3dbabe /Lib
parentd7171759da0aadc50e4eda8a5690b123e33bd33b (diff)
downloadcpython-75ad320ffdeeb2fd8c26340ec82f9d738dd4dfcf.tar.gz
Issue #27108: Add missing names to mimetypes.__all__, by Jacek Ko?odziej
Diffstat (limited to 'Lib')
-rw-r--r--Lib/mimetypes.py6
-rw-r--r--Lib/test/test_mimetypes.py6
2 files changed, 10 insertions, 2 deletions
diff --git a/Lib/mimetypes.py b/Lib/mimetypes.py
index 0be76ad4f7..9a886803dc 100644
--- a/Lib/mimetypes.py
+++ b/Lib/mimetypes.py
@@ -33,8 +33,10 @@ except ImportError:
_winreg = None
__all__ = [
- "guess_type","guess_extension","guess_all_extensions",
- "add_type","read_mime_types","init"
+ "knownfiles", "inited", "MimeTypes",
+ "guess_type", "guess_all_extensions", "guess_extension",
+ "add_type", "init", "read_mime_types",
+ "suffix_map", "encodings_map", "types_map", "common_types"
]
knownfiles = [
diff --git a/Lib/test/test_mimetypes.py b/Lib/test/test_mimetypes.py
index 68565930a4..4e2c9089b5 100644
--- a/Lib/test/test_mimetypes.py
+++ b/Lib/test/test_mimetypes.py
@@ -101,5 +101,11 @@ class Win32MimeTypesTestCase(unittest.TestCase):
eq(self.db.guess_type("image.jpg"), ("image/jpeg", None))
eq(self.db.guess_type("image.png"), ("image/png", None))
+
+class MiscTestCase(unittest.TestCase):
+ def test__all__(self):
+ support.check__all__(self, mimetypes)
+
+
if __name__ == "__main__":
unittest.main()