From aa789ace66b8276b7ea55a14168d89b23b558285 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89ric=20Araujo?= Date: Sun, 24 Jun 2012 13:51:22 -0400 Subject: Restore test that was using pysetup and can now (#15157) use pydoc --- Lib/test/test_venv.py | 4 ++++ 1 file changed, 4 insertions(+) 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) -- cgit v0.12 From 0a8f5f709a5ca6cc13190bcb5053a1ba9a50edcc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89ric=20Araujo?= Date: Sun, 24 Jun 2012 13:53:41 -0400 Subject: Fix typos --- Doc/library/os.rst | 6 +++--- 1 file changed, 3 insertions(+), 3 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 -- cgit v0.12 From 544e13d126153cfded305416f3b356f52f9458e5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89ric=20Araujo?= Date: Sun, 24 Jun 2012 13:53:48 -0400 Subject: Fix markup --- Doc/library/shutil.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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 -- cgit v0.12