Add Python 3 CI support. (#17209)

This commit is contained in:
Matt Clay 2016-08-23 23:08:11 -07:00 committed by GitHub
parent a9322e8b8b
commit e2e7390adc
4 changed files with 134 additions and 0 deletions

View file

@ -7,6 +7,7 @@ test_privileged="${PRIVILEGED:-false}"
test_flags="${TEST_FLAGS:-}"
test_target="${TARGET:-}"
test_ansible_dir="${TEST_ANSIBLE_DIR:-/root/ansible}"
test_python3="${PYTHON3:-}"
http_image="${HTTP_IMAGE:-ansible/ansible:httptester}"
@ -85,12 +86,26 @@ container_id=$(docker run -d \
show_environment
if [ "${test_python3}" ]; then
docker exec "${container_id}" ln -s /usr/bin/python3 /usr/bin/python
docker exec "${container_id}" ln -s /usr/bin/pip3 /usr/bin/pip
skip_tags=$(tr '\n' ',' < "${source_root}/test/utils/shippable/python3-test-tag-blacklist.txt")
test_flags="--skip-tags ${skip_tags} ${test_flags}"
fi
docker exec "${container_id}" pip install jmespath
if [ "${copy_source}" ]; then
docker exec "${container_id}" cp -a "${test_shared_dir}" "${test_ansible_dir}"
fi
if [ "${test_python3}" ]; then
docker exec "${container_id}" sed -i -f \
"${test_ansible_dir}/test/utils/shippable/python3-test-target-blacklist.txt" \
"${test_ansible_dir}/test/integration/Makefile"
fi
docker exec "${container_id}" mkdir -p "${test_shared_dir}/shippable/testresults"
docker exec "${container_id}" /bin/sh -c "cd '${test_ansible_dir}' && . hacking/env-setup && cd test/integration && \
JUNIT_OUTPUT_DIR='${test_shared_dir}/shippable/testresults' ANSIBLE_CALLBACK_WHITELIST=junit \

View file

@ -0,0 +1,44 @@
test_apache2_module
test_apt
test_apt_repository
test_assemble
test_async
test_authorized_key
test_become
test_binary
test_changed_when
test_command_shell
test_conditionals
test_copy
test_embedded_module
test_facts_d
test_failed_when
test_fetch
test_file
test_filters
test_gem
test_get_url
test_git
test_good_parsing
test_handlers
test_hg
test_iterators
test_lineinfile
test_lookups
test_mysql_db
test_mysql_user
test_mysql_variables
test_pip
test_postgresql
test_service
test_special_vars
test_stat
test_subversion
test_sudo
test_synchronize
test_task_ordering
test_template
test_unarchive
test_until
test_uri
test_var_blending

View file

@ -0,0 +1,14 @@
s/ check_mode / /
s/ environment / /
s/ includes / /
s/ no_log / /
s/ pull / /
s/ test_async_conditional / /
s/ test_binary_modules$/ /
s/ test_connection / /
s/ test_handlers / /
s/ test_hash / /
s/ test_lookup_paths / /
s/ test_var_precedence / /
s/ test_vault / /
s/ unicode / /