summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@gmail.com>2016-03-14 17:22:12 (GMT)
committerVictor Stinner <victor.stinner@gmail.com>2016-03-14 17:22:12 (GMT)
commit0ab7d0978b1686838e0eda40e8f950d2d4cbc16a (patch)
tree828049ade192b6bc9b8085ce6654908d0e51f0a8
parent21b47117ac061f0ba08219aa1a6d81a4a5a9c483 (diff)
parent87d6e1364c368244a51574ec805eeed8e8ae87a6 (diff)
downloadcpython-0ab7d0978b1686838e0eda40e8f950d2d4cbc16a.zip
cpython-0ab7d0978b1686838e0eda40e8f950d2d4cbc16a.tar.gz
cpython-0ab7d0978b1686838e0eda40e8f950d2d4cbc16a.tar.bz2
Merge 3.5 (test_venv)
-rw-r--r--Lib/test/test_venv.py11
1 files changed, 10 insertions, 1 deletions
diff --git a/Lib/test/test_venv.py b/Lib/test/test_venv.py
index f38f52df..dbb8b85 100644
--- a/Lib/test/test_venv.py
+++ b/Lib/test/test_venv.py
@@ -8,6 +8,7 @@ Licensed to the PSF under a contributor agreement.
import ensurepip
import os
import os.path
+import re
import struct
import subprocess
import sys
@@ -394,7 +395,15 @@ class EnsurePipTest(BaseTest):
# We force everything to text, so unittest gives the detailed diff
# if we get unexpected results
err = err.decode("latin-1") # Force to text, prevent decoding errors
- self.assertEqual(err, "")
+ # Ignore the warning:
+ # "The directory '$HOME/.cache/pip/http' or its parent directory
+ # is not owned by the current user and the cache has been disabled.
+ # Please check the permissions and owner of that directory. If
+ # executing pip with sudo, you may want sudo's -H flag."
+ # where $HOME is replaced by the HOME environment variable.
+ err = re.sub("^The directory .* or its parent directory is not owned "
+ "by the current user .*$", "", err, flags=re.MULTILINE)
+ self.assertEqual(err.rstrip(), "")
# Being fairly specific regarding the expected behaviour for the
# initial bundling phase in Python 3.4. If the output changes in
# future pip versions, this test can likely be relaxed further.