File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 22
33from idlelib import iomenu
44import builtins
5+ import os
6+ import tempfile
57import unittest
68from test .support import requires
79from tkinter import Tk
@@ -60,9 +62,6 @@ def test_fixnewlines_end(self):
6062
6163 def test_reload_no_file (self ):
6264 # Test reload when no file is associated
63- import tempfile
64- import os
65- from unittest .mock import Mock
6665
6766 io = self .io
6867 # Ensure no filename is set
@@ -85,8 +84,6 @@ def mock_showinfo(*args, **kwargs):
8584
8685 def test_reload_with_file (self ):
8786 # Test reload with an actual file
88- import tempfile
89- import os
9087
9188 io = self .io
9289 text = io .editwin .text
@@ -114,8 +111,6 @@ def test_reload_with_file(self):
114111
115112 def test_reload_with_unsaved_changes_cancel (self ):
116113 # Test reload with unsaved changes and user cancels
117- import tempfile
118- import os
119114
120115 io = self .io
121116 text = io .editwin .text
@@ -149,8 +144,6 @@ def test_reload_with_unsaved_changes_cancel(self):
149144
150145 def test_reload_with_unsaved_changes_confirm (self ):
151146 # Test reload with unsaved changes and user confirms
152- import tempfile
153- import os
154147
155148 io = self .io
156149 text = io .editwin .text
You can’t perform that action at this time.
0 commit comments