Commits

Joe Amenta  committed 3d4fe20

Making tkinter -> Tkinter work

  • Participants
  • Parent commits 0fc297c

Comments (0)

Files changed (2)

File lib3to2/fixes/fix_imports.py

            "http.client": "httplib",
            "http.cookies": "Cookie",
            "http.cookiejar": "cookielib",
-#          "tkinter": "Tkinter",
+           "tkinter": "Tkinter",
            "tkinter.dialog": "Dialog",
            "tkinter._fix": "FixTk",
            "tkinter.scrolledtext": "ScrolledText",
 
 class FixImports(fixer_base.BaseFix):
 
+    order = "pre"
+
     PATTERN = ' | \n'.join([all_patterns(name) for name in MAPPING])
     PATTERN = ' | \n'.join((PATTERN, multiple_name_import_match))
 

File lib3to2/tests/test_imports.py

         a = "import Tkinter"
         self.check(b, a)
 
-        #TODO: Make this work (see the fix_imports)
-        #b = "import tkinter"
-        #a = "import Tkinter"
-        #self.check(b, a)
+        b = "import tkinter"
+        a = "import Tkinter"
+        self.check(b, a)
 
         b = "import tkinter.colorchooser"
         a = "import tkColorChooser"