diff options
author | Zack Weinberg <zackw@panix.com> | 2020-09-12 09:51:07 -0400 |
---|---|---|
committer | Zack Weinberg <zackw@panix.com> | 2020-09-12 09:51:07 -0400 |
commit | 626727a8ddcd1d0ec185a26dab573674d5536c32 (patch) | |
tree | b8b1872aef9441a418ff6b5692e05417e3114d8b /t/python-virtualenv.sh | |
parent | 74673d1cbd3c789b26839f0c1a88ca032d47d058 (diff) | |
download | automake-626727a8ddcd1d0ec185a26dab573674d5536c32.tar.gz |
t/python-virtualenv.sh: Skip when versions don’t match
On some operating systems ‘python’ is Python 2.x but ‘virtualenv -ppython’
will create a virtualenv that uses Python 3.x. This is a bug, but it’s
not *automake’s* bug, and should not cause t/python-virtualenv.sh to fail.
Skip the test, instead of failing it, when the inner=outer version check
fails.
(This also has nothing to do with the main goal of this patchset, it just
annoyed me while I was testing.)
* t/python-virtualenv.sh: Skip test, rather than failing it, when
$py_version_pre != $py_version_post.
Diffstat (limited to 't/python-virtualenv.sh')
-rw-r--r-- | t/python-virtualenv.sh | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/t/python-virtualenv.sh b/t/python-virtualenv.sh index 6f4e0c07c..05df22b7c 100644 --- a/t/python-virtualenv.sh +++ b/t/python-virtualenv.sh @@ -39,7 +39,8 @@ fi py_version_post=$(python -V) # Sanity check. -test "$py_version_pre" = "$py_version_post" +test "$py_version_pre" = "$py_version_post" \ + || skip_ "virtualenv $py_version_post != $py_version_pre" cwd=$(pwd) || fatal_ "getting current working directory" py_version=$(python -c 'import sys; print("%u.%u" % tuple(sys.version_info[:2]))') |