ansible.posix/tests/utils/shippable/sanity.sh
saito-hideki 53788e60fa
Ignore pylint errors caused by compatibility checks for six
* This is a temporary measure until we stop covering Python2

Signed-off-by: saito-hideki <saito@fgrep.org>
2025-09-29 16:30:19 +09:00

21 lines
760 B
Bash
Executable file

#!/usr/bin/env bash
# Following logic in https://github.com/ansible-collections/collection_template/blob/main/.github/workflows/ansible-test.yml
set -o pipefail -eux
if [ "${BASE_BRANCH:-}" ]; then
base_branch="origin/${BASE_BRANCH}"
else
base_branch=""
fi
# Run sanity tests inside a Docker container.
# The docker container has all the pinned dependencies that are
# required and all Python versions Ansible supports.
# See the documentation for the following GitHub action on
# https://github.com/ansible-community/ansible-test-gh-action/blob/main/README.md
# shellcheck disable=SC2086
ansible-test sanity --color -v --junit ${COVERAGE:+"$COVERAGE"} ${CHANGED:+"$CHANGED"} \
--docker --base-branch "${base_branch}" --allow-disabled --debug