summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorÉric Araujo <merwok@netwok.org>2012-06-24 17:54:22 (GMT)
committerÉric Araujo <merwok@netwok.org>2012-06-24 17:54:22 (GMT)
commit56261cff162dee2043b859986a6a73db52d27085 (patch)
treea66a47a9a9f4353f7521ae061996d9ad99222dd4
parent19c4e5bb391c805281288f1febc4dec12a365c86 (diff)
parent544e13d126153cfded305416f3b356f52f9458e5 (diff)
downloadcpython-56261cff162dee2043b859986a6a73db52d27085.zip
cpython-56261cff162dee2043b859986a6a73db52d27085.tar.gz
cpython-56261cff162dee2043b859986a6a73db52d27085.tar.bz2
Branch merge
-rw-r--r--Doc/library/os.rst6
-rw-r--r--Doc/library/shutil.rst2
-rw-r--r--Lib/test/test_venv.py4
3 files changed, 8 insertions, 4 deletions
diff --git a/Doc/library/os.rst b/Doc/library/os.rst
index f38b152..78b4007 100644
--- a/Doc/library/os.rst
+++ b/Doc/library/os.rst
@@ -1205,7 +1205,7 @@ features:
* For some functions, the *path* argument can be not only a string giving a path
name, but also a file descriptor. The function will then operate on the file
referred to by the descriptor. (For POSIX systems, this will use the ``f...``
- versions of the function.)
+ version of the function.)
You can check whether or not *path* can be specified as a file descriptor on
your platform using :data:`os.supports_fd`. If it is unavailable, using it
@@ -1220,7 +1220,7 @@ features:
should be a file descriptor referring to a directory, and the path to operate
on should be relative; path will then be relative to that directory. If the
path is absolute, *dir_fd* is ignored. (For POSIX systems, this will use the
- ``f...at`` versions of the function.)
+ ``f...at`` version of the function.)
You can check whether or not *dir_fd* is supported on your platform using
:data:`os.supports_dir_fd`. If it is unavailable, using it will raise a
@@ -1231,7 +1231,7 @@ features:
* For functions ith a *follow_symlinks* parameter: If *follow_symlinks* is
``False``, and the last element of the path to operate on is a symbolic link,
the function will operate on the symbolic link itself instead of the file the
- link points to. (For POSIX systems, this will use the ``l...`` versions of
+ link points to. (For POSIX systems, this will use the ``l...`` version of
the function.)
You can check whether or not *follow_symlinks* is supported on your platform
diff --git a/Doc/library/shutil.rst b/Doc/library/shutil.rst
index 267c96b..1c27cc9 100644
--- a/Doc/library/shutil.rst
+++ b/Doc/library/shutil.rst
@@ -214,7 +214,7 @@ Directory and files operations
Added a symlink attack resistant version that is used automatically
if platform supports fd-based functions.
- .. data:: rmtree.avoids_symlink_attacks
+ .. attribute:: rmtree.avoids_symlink_attacks
Indicates whether the current platform and implementation provides a
symlink attack resistant version of :func:`rmtree`. Currently this is
diff --git a/Lib/test/test_venv.py b/Lib/test/test_venv.py
index 1188d93..45a2987 100644
--- a/Lib/test/test_venv.py
+++ b/Lib/test/test_venv.py
@@ -21,10 +21,12 @@ class BaseTest(unittest.TestCase):
self.env_dir = tempfile.mkdtemp()
if os.name == 'nt':
self.bindir = 'Scripts'
+ self.pydocname = 'pydoc.py'
self.lib = ('Lib',)
self.include = 'Include'
else:
self.bindir = 'bin'
+ self.pydocname = 'pydoc'
self.lib = ('lib', 'python%s' % sys.version[:3])
self.include = 'include'
if sys.platform == 'darwin' and '__PYTHONV_LAUNCHER__' in os.environ:
@@ -74,6 +76,8 @@ class BasicTest(BaseTest):
executable = sys.executable
path = os.path.dirname(executable)
self.assertIn('home = %s' % path, data)
+ data = self.get_text_file_contents(self.bindir, self.pydocname)
+ self.assertTrue(data.startswith('#!%s%s' % (self.env_dir, os.sep)))
fn = self.get_env_file(self.bindir, self.exe)
if not os.path.exists(fn): # diagnostics for Windows buildbot failures
bd = self.get_env_file(self.bindir)