Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(1026)

Unified Diff: Lib/packaging/tests/test_command_install_data.py

Issue 14057: Speedup sysconfig startup
Patch Set: Created 1 year, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | Lib/sysconfig.py » ('j') | Lib/sysconfig.py » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
--- a/Lib/packaging/tests/test_command_install_data.py Tue Feb 21 22:10:16 2012 +0100
+++ b/Lib/packaging/tests/test_command_install_data.py Wed Feb 22 00:17:45 2012 +0100
@@ -17,13 +17,11 @@ class InstallDataTestCase(support.Tempdi
def setUp(self):
super(InstallDataTestCase, self).setUp()
scheme = _get_default_scheme()
- old_items = sysconfig._SCHEMES.items(scheme)
+ old_sections = sysconfig._SCHEMES._sections.copy()
def restore():
- sysconfig._SCHEMES.remove_section(scheme)
- sysconfig._SCHEMES.add_section(scheme)
- for option, value in old_items:
- sysconfig._SCHEMES.set(scheme, option, value)
+ sysconfig._SCHEMES._sections.clear()
+ sysconfig._SCHEMES._sections.update(old_sections)
self.addCleanup(restore)
« no previous file with comments | « no previous file | Lib/sysconfig.py » ('j') | Lib/sysconfig.py » ('J')

RSS Feeds Recent Issues | This issue
This is Rietveld cbc36f91f3f7