-
Notifications
You must be signed in to change notification settings - Fork 398
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test: use 2nd venv for alt boto version tests
We pin the botocore version to avoid long list of download and save time. In order to keep the original ansible venv intact, we install the specific boto version in a dedicated venv that with expose to ansible with ansible_python_interpreter. This way we avoid some conflict between ansible's dep and boto. e.g: https://f73e17188c1e5a04acad-2f383edc1ebee1550897a1656739ef36.ssl.cf1.rackcdn.com/634/c7b79a3aeefd78a53e7afe854db0f9b673106f3f/check/ansible-test-cloud-integration-aws-py36_1/85f5ba0/job-output.txt
- Loading branch information
Showing
3 changed files
with
18 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
#!/usr/bin/env bash | ||
|
||
set -eux | ||
|
||
unset PYTHONPATH | ||
# Run full test suite | ||
source virtualenv.sh | ||
pip install 'botocore>1.10.26' boto3 | ||
ansible-playbook -i ../../inventory -v playbooks/full_test.yml "$@" | ||
python3 -mvenv --clear _venv | ||
_venv/bin/pip install 'botocore>1.10.26' boto3 | ||
ansible-playbook -i ../../inventory -v playbooks/full_test.yml -e "ansible_python_interpreter=$(pwd)/_venv/bin/python" "$@" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,16 @@ | ||
#!/usr/bin/env bash | ||
|
||
set -eux | ||
unset PYTHONPATH | ||
|
||
export ANSIBLE_ROLES_PATH=../ | ||
|
||
# Test graceful failure for older versions of botocore | ||
source virtualenv.sh | ||
pip install 'botocore<1.10.57' boto3 | ||
ansible-playbook -i ../../inventory -v playbooks/version_fail.yml "$@" | ||
python3 -mvenv --clear _venv | ||
_venv/bin/pip install 'botocore<1.10.57' boto3 | ||
ansible-playbook -i ../../inventory -v playbooks/version_fail.yml -e "ansible_python_interpreter=$(pwd)/_venv/bin/python" "$@" | ||
|
||
# Run full test suite | ||
source virtualenv.sh | ||
pip install 'botocore>=1.10.57' boto3 | ||
ansible-playbook -i ../../inventory -v playbooks/full_test.yml "$@" | ||
python3 -mvenv --clear _venv | ||
_venv/bin/pip install 'botocore>=1.10.57' boto3 | ||
ansible-playbook -i ../../inventory -v playbooks/full_test.yml -e "ansible_python_interpreter=$(pwd)/_venv/bin/python" "$@" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,13 @@ | ||
#!/usr/bin/env bash | ||
|
||
set -eux | ||
|
||
unset PYTHONPATH | ||
# Test graceful failure for older versions of botocore | ||
source virtualenv.sh | ||
pip install 'botocore<=1.7.1' boto3 | ||
ansible-playbook -i ../../inventory -v playbooks/version_fail.yml "$@" | ||
python3 -mvenv --clear _venv | ||
_venv/bin/pip install 'botocore==1.7.0' 'boto3==1.4.7' boto3 | ||
ansible-playbook -i ../../inventory -v playbooks/version_fail.yml -e "ansible_python_interpreter=$(pwd)/_venv/bin/python" "$@" | ||
|
||
# Run full test suite | ||
source virtualenv.sh | ||
pip install 'botocore' 'boto3>=1.16.57' | ||
ansible-playbook -i ../../inventory -v playbooks/full_test.yml "$@" | ||
python3 -mvenv --clear _venv | ||
_venv/bin/pip install 'botocore' 'boto3>=1.16.57' boto3 | ||
ansible-playbook -i ../../inventory -v playbooks/full_test.yml -e "ansible_python_interpreter=$(pwd)/_venv/bin/python" "$@" |