diff options
author | Nikita Sobolev <mail@sobolevn.me> | 2023-04-23 23:25:08 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-04-23 23:25:08 (GMT) |
commit | bd2dca035af88694e25fb060f984fbbcda82bed8 (patch) | |
tree | fed7d54ec1154ebc7390967d78c61e911509fae2 /Lib/idlelib/idle_test | |
parent | 7255bbd4a1841447a21c3eb74e4fd9e21818d833 (diff) | |
download | cpython-bd2dca035af88694e25fb060f984fbbcda82bed8.zip cpython-bd2dca035af88694e25fb060f984fbbcda82bed8.tar.gz cpython-bd2dca035af88694e25fb060f984fbbcda82bed8.tar.bz2 |
gh-103668: Run pyugrade on idlelib (#103671)
---------
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
Diffstat (limited to 'Lib/idlelib/idle_test')
-rw-r--r-- | Lib/idlelib/idle_test/test_config.py | 2 | ||||
-rw-r--r-- | Lib/idlelib/idle_test/test_outwin.py | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/Lib/idlelib/idle_test/test_config.py b/Lib/idlelib/idle_test/test_config.py index 697fda5..08ed76f 100644 --- a/Lib/idlelib/idle_test/test_config.py +++ b/Lib/idlelib/idle_test/test_config.py @@ -191,7 +191,7 @@ class IdleConfTest(unittest.TestCase): idle_dir = os.path.abspath(sys.path[0]) for ctype in conf.config_types: config_path = os.path.join(idle_dir, '../config-%s.def' % ctype) - with open(config_path, 'r') as f: + with open(config_path) as f: cls.config_string[ctype] = f.read() cls.orig_warn = config._warn diff --git a/Lib/idlelib/idle_test/test_outwin.py b/Lib/idlelib/idle_test/test_outwin.py index e347bfc..d6e85ad 100644 --- a/Lib/idlelib/idle_test/test_outwin.py +++ b/Lib/idlelib/idle_test/test_outwin.py @@ -159,7 +159,7 @@ class ModuleFunctionTest(unittest.TestCase): for line, expected_output in test_lines: self.assertEqual(flh(line), expected_output) if expected_output: - mock_open.assert_called_with(expected_output[0], 'r') + mock_open.assert_called_with(expected_output[0]) if __name__ == '__main__': |