2019-02-18 22:41:45 +01:00
|
|
|
#!/usr/bin/env bash
|
2016-11-30 06:21:53 +01:00
|
|
|
|
2019-02-18 22:41:45 +01:00
|
|
|
set -o pipefail -eux
|
2016-11-30 06:21:53 +01:00
|
|
|
|
|
|
|
declare -a args
|
2017-10-03 21:43:46 +02:00
|
|
|
IFS='/:' read -ra args <<< "$1"
|
2016-11-30 06:21:53 +01:00
|
|
|
|
2017-10-03 23:37:05 +02:00
|
|
|
image="${args[1]}"
|
|
|
|
|
|
|
|
if [ "${#args[@]}" -gt 2 ]; then
|
2018-07-24 05:46:22 +02:00
|
|
|
target="shippable/posix/group${args[2]}/"
|
2017-10-03 23:37:05 +02:00
|
|
|
else
|
2018-07-24 05:46:22 +02:00
|
|
|
target="shippable/posix/"
|
2017-10-03 23:37:05 +02:00
|
|
|
fi
|
2016-11-30 06:21:53 +01:00
|
|
|
|
2020-03-03 21:56:36 +01:00
|
|
|
# detect the post migration ansible/ansible repo and enable test support plugins
|
|
|
|
if [ -f lib/ansible/config/routing.yml ]; then
|
|
|
|
# this option is only useful for ansible/ansible (not collections) and should not be used prior to migration (except for incidental tests)
|
|
|
|
enable_test_support=--enable-test-support
|
|
|
|
fi
|
|
|
|
|
2017-05-13 19:08:42 +02:00
|
|
|
# shellcheck disable=SC2086
|
2018-04-13 01:15:28 +02:00
|
|
|
ansible-test integration --color -v --retry-on-error "${target}" ${COVERAGE:+"$COVERAGE"} ${CHANGED:+"$CHANGED"} ${UNSTABLE:+"$UNSTABLE"} \
|
2020-03-03 21:56:36 +01:00
|
|
|
${enable_test_support:+"$enable_test_support"} \
|
2017-10-03 23:37:05 +02:00
|
|
|
--docker "${image}"
|