Skip to content

Commit 3b460b6

Browse files
committed
Manually merging to py2
1 parent 43858b1 commit 3b460b6

File tree

2 files changed

+11
-11
lines changed

2 files changed

+11
-11
lines changed

source_py2/test_python_toolbox/test_context_management/test_as_reentrant.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Copyright 2009-2015 Ram Rachum.
22
# This program is distributed under the MIT license.
33

4-
import queue as queue_module
4+
import Queue as queue_module
55

66
from python_toolbox.context_management import (as_reentrant, ContextManager,
77
ContextManagerType)

source_py2/test_python_toolbox/test_temp_file_tools/test_create_temp_folder.py

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -115,15 +115,15 @@ def test_parent_folder():
115115
assert str(tf2).startswith(str(tf1))
116116

117117
def test_chmod():
118-
with (create_temp_folder(chmod=0o777) as liberal_temp_folder,
119-
create_temp_folder(chmod=0o000) as conservative_temp_folder):
120-
# Doing a very weak test of chmod because not everything is supported
121-
# on Windows.
122-
assert (liberal_temp_folder.stat().st_mode & 0o777) > \
123-
(conservative_temp_folder.stat().st_mode & 0o777)
124-
125-
# Making `conservative_temp_folder` writeable again so it could be
126-
# deleted in cleanup:
127-
conservative_temp_folder.chmod(0o777)
118+
with create_temp_folder(chmod=0o777) as liberal_temp_folder:
119+
with create_temp_folder(chmod=0o000) as conservative_temp_folder:
120+
# Doing a very weak test of chmod because not everything is
121+
# supported on Windows.
122+
assert (liberal_temp_folder.stat().st_mode & 0o777) > \
123+
(conservative_temp_folder.stat().st_mode & 0o777)
124+
125+
# Making `conservative_temp_folder` writeable again so it could be
126+
# deleted in cleanup:
127+
conservative_temp_folder.chmod(0o777)
128128

129129

0 commit comments

Comments
 (0)