mirror of https://github.com/ansible/ansible.git
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
35 lines
985 B
Bash
35 lines
985 B
Bash
6 years ago
|
#!/usr/bin/env bash
|
||
8 years ago
|
|
||
6 years ago
|
set -o pipefail -eux
|
||
8 years ago
|
|
||
|
declare -a args
|
||
7 years ago
|
IFS='/:' read -ra args <<< "$1"
|
||
8 years ago
|
|
||
6 years ago
|
cloud="${args[0]}"
|
||
|
python="${args[1]}"
|
||
|
group="${args[2]}"
|
||
|
|
||
|
target="shippable/${cloud}/group${group}/"
|
||
8 years ago
|
|
||
7 years ago
|
stage="${S:-prod}"
|
||
|
|
||
6 years ago
|
changed_all_target="shippable/${cloud}/smoketest/"
|
||
|
|
||
5 years ago
|
if ! ansible-test integration "${changed_all_target}" --list-targets > /dev/null 2>&1; then
|
||
|
# no smoketest tests are available for this cloud
|
||
|
changed_all_target="none"
|
||
|
fi
|
||
|
|
||
6 years ago
|
if [ "${group}" == "1" ]; then
|
||
|
# only run smoketest tests for group1
|
||
6 years ago
|
changed_all_mode="include"
|
||
6 years ago
|
else
|
||
|
# smoketest tests already covered by group1
|
||
6 years ago
|
changed_all_mode="exclude"
|
||
6 years ago
|
fi
|
||
|
|
||
8 years ago
|
# shellcheck disable=SC2086
|
||
7 years ago
|
ansible-test integration --color -v --retry-on-error "${target}" ${COVERAGE:+"$COVERAGE"} ${CHANGED:+"$CHANGED"} ${UNSTABLE:+"$UNSTABLE"} \
|
||
7 years ago
|
--remote-terminate always --remote-stage "${stage}" \
|
||
6 years ago
|
--docker --python "${python}" --changed-all-target "${changed_all_target}" --changed-all-mode "${changed_all_mode}"
|