Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
fd4903bf
Commit
fd4903bf
authored
Oct 17, 2009
by
Nick Coghlan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Move restoration of the os.environ object into the context manager where it belongs
parent
87c03b31
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
1 addition
and
1 deletion
+1
-1
Lib/test/test_httpservers.py
Lib/test/test_httpservers.py
+0
-1
Lib/test/test_support.py
Lib/test/test_support.py
+1
-0
No files found.
Lib/test/test_httpservers.py
View file @
fd4903bf
...
...
@@ -60,7 +60,6 @@ class BaseTestCase(unittest.TestCase):
self
.
lock
.
release
()
self
.
thread
.
stop
()
os
.
environ
.
__exit__
()
os
.
environ
=
os
.
environ
.
_environ
def
request
(
self
,
uri
,
method
=
'GET'
,
body
=
None
,
headers
=
{}):
self
.
connection
=
httplib
.
HTTPConnection
(
'localhost'
,
self
.
PORT
)
...
...
Lib/test/test_support.py
View file @
fd4903bf
...
...
@@ -576,6 +576,7 @@ class EnvironmentVarGuard(UserDict.DictMixin):
del
self
.
_environ
[
k
]
else
:
self
.
_environ
[
k
]
=
v
os
.
environ
=
self
.
_environ
class
DirsOnSysPath
(
object
):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment