diff --git a/tests/ansible/ansible.cfg b/tests/ansible/ansible.cfg index dfc2858e..ad58a781 100644 --- a/tests/ansible/ansible.cfg +++ b/tests/ansible/ansible.cfg @@ -1,4 +1,5 @@ [defaults] +any_errors_fatal = true inventory = hosts gathering = explicit strategy_plugins = ../../ansible_mitogen/plugins/strategy @@ -35,6 +36,10 @@ timeout = 10 # On Travis, paramiko check fails due to host key checking enabled. host_key_checking = False +[inventory] +any_unparsed_is_failed = true +host_pattern_mismatch = error + [callback_profile_tasks] task_output_limit = 10 diff --git a/tests/ansible/bench/file_transfer.yml b/tests/ansible/bench/file_transfer.yml index 6324a84e..09534af5 100644 --- a/tests/ansible/bench/file_transfer.yml +++ b/tests/ansible/bench/file_transfer.yml @@ -1,7 +1,6 @@ - name: bench/file_transfer.yml hosts: test-targets - any_errors_fatal: true tasks: - name: Make 32MiB file diff --git a/tests/ansible/bench/loop-100-copies.yml b/tests/ansible/bench/loop-100-copies.yml index 6f763f93..2a8e7d6f 100644 --- a/tests/ansible/bench/loop-100-copies.yml +++ b/tests/ansible/bench/loop-100-copies.yml @@ -1,6 +1,5 @@ - name: bench/loop-100-copies.yml hosts: all - any_errors_fatal: true tasks: - name: Create file tree diff --git a/tests/ansible/hosts/transport_config.hosts b/tests/ansible/hosts/transport_config.hosts index 856c6a0f..05e0d4f1 100644 --- a/tests/ansible/hosts/transport_config.hosts +++ b/tests/ansible/hosts/transport_config.hosts @@ -22,9 +22,15 @@ tc-remote-addr-explicit-both ansible_ssh_host=a.b.c ansible_host=b.c.d # password() tc-password-unset tc-password-explicit-ssh ansible_ssh_pass=ansi-ssh-pass -tc-password-explicit-user ansible_password=ansi-pass +tc-password-explicit-pass ansible_password=ansi-pass tc-password-explicit-both ansible_password=a.b.c ansible_ssh_pass=c.b.a +# remote_user() +tc-remote-user-unset # defaults to C.DEFAULT_REMOTE_USER +tc-remote-user-explicit-ssh ansible_ssh_user=ansi-ssh-user +tc-remote-user-explicit-user ansible_user=ansi-user +tc-remote-user-explicit-both ansible_user=a.b.c ansible_ssh_user=c.b.a + # become() tc-become-unset tc-become-set diff --git a/tests/ansible/integration/action/copy.yml b/tests/ansible/integration/action/copy.yml index 611ff3f2..8aae546a 100644 --- a/tests/ansible/integration/action/copy.yml +++ b/tests/ansible/integration/action/copy.yml @@ -2,7 +2,6 @@ - name: integration/action/copy.yml hosts: test-targets - any_errors_fatal: true tasks: - copy: dest: /tmp/copy-tiny-file diff --git a/tests/ansible/integration/action/fixup_perms2__copy.yml b/tests/ansible/integration/action/fixup_perms2__copy.yml index 1ba19e6f..652974d3 100644 --- a/tests/ansible/integration/action/fixup_perms2__copy.yml +++ b/tests/ansible/integration/action/fixup_perms2__copy.yml @@ -5,7 +5,6 @@ - name: integration/action/fixup_perms2__copy.yml hosts: test-targets - any_errors_fatal: true tasks: # # copy module (no mode). diff --git a/tests/ansible/integration/action/low_level_execute_command.yml b/tests/ansible/integration/action/low_level_execute_command.yml index 7f91bdf8..24649424 100644 --- a/tests/ansible/integration/action/low_level_execute_command.yml +++ b/tests/ansible/integration/action/low_level_execute_command.yml @@ -2,7 +2,6 @@ - name: integration/action/low_level_execute_command.yml hosts: test-targets - any_errors_fatal: true tasks: # "echo -en" to test we actually hit bash shell too. diff --git a/tests/ansible/integration/action/make_tmp_path.yml b/tests/ansible/integration/action/make_tmp_path.yml index bfebeffd..8e981250 100644 --- a/tests/ansible/integration/action/make_tmp_path.yml +++ b/tests/ansible/integration/action/make_tmp_path.yml @@ -9,7 +9,6 @@ - name: integration/action/make_tmp_path.yml hosts: test-targets - any_errors_fatal: true tasks: - meta: end_play when: not is_mitogen diff --git a/tests/ansible/integration/action/make_tmp_path__double.yml b/tests/ansible/integration/action/make_tmp_path__double.yml index 74ba65a2..fd66c13d 100644 --- a/tests/ansible/integration/action/make_tmp_path__double.yml +++ b/tests/ansible/integration/action/make_tmp_path__double.yml @@ -2,7 +2,7 @@ # they succeed and are cleaned up correctly. - name: integration/action/make_tmp_path__double.yml - hosts: targets + hosts: test-targets tasks: - mitogen_action_script: script: | diff --git a/tests/ansible/integration/action/remote_expand_user.yml b/tests/ansible/integration/action/remote_expand_user.yml index 8e31f657..3a675635 100644 --- a/tests/ansible/integration/action/remote_expand_user.yml +++ b/tests/ansible/integration/action/remote_expand_user.yml @@ -3,7 +3,6 @@ - name: integration/action/remote_expand_user.yml hosts: test-targets - any_errors_fatal: true tasks: - name: "Find out root's homedir." # Runs first because it blats regular Ansible facts with junk, so diff --git a/tests/ansible/integration/action/remote_file_exists.yml b/tests/ansible/integration/action/remote_file_exists.yml index 2d206930..28952f93 100644 --- a/tests/ansible/integration/action/remote_file_exists.yml +++ b/tests/ansible/integration/action/remote_file_exists.yml @@ -1,7 +1,6 @@ - name: integration/action/remote_file_exists.yml hosts: test-targets - any_errors_fatal: true tasks: - file: diff --git a/tests/ansible/integration/action/remove_tmp_path.yml b/tests/ansible/integration/action/remove_tmp_path.yml index 19ae22e3..1df212c7 100644 --- a/tests/ansible/integration/action/remove_tmp_path.yml +++ b/tests/ansible/integration/action/remove_tmp_path.yml @@ -4,7 +4,6 @@ # - name: integration/action/remove_tmp_path.yml hosts: test-targets - any_errors_fatal: true tasks: # # Use the copy module to cause a temporary directory to be created, and diff --git a/tests/ansible/integration/action/synchronize.yml b/tests/ansible/integration/action/synchronize.yml index a6cd277e..f17d8fb8 100644 --- a/tests/ansible/integration/action/synchronize.yml +++ b/tests/ansible/integration/action/synchronize.yml @@ -2,7 +2,6 @@ - name: integration/action/synchronize.yml hosts: test-targets - any_errors_fatal: true vars: ansible_user: mitogen__has_sudo_pubkey ansible_become_pass: has_sudo_pubkey_password diff --git a/tests/ansible/integration/action/transfer_data.yml b/tests/ansible/integration/action/transfer_data.yml index e0f42d0e..343f45da 100644 --- a/tests/ansible/integration/action/transfer_data.yml +++ b/tests/ansible/integration/action/transfer_data.yml @@ -1,7 +1,6 @@ - name: integration/action/transfer_data.yml hosts: test-targets - any_errors_fatal: true tasks: - file: diff --git a/tests/ansible/integration/async/multiple_items_loop.yml b/tests/ansible/integration/async/multiple_items_loop.yml index 24d43083..5d070255 100644 --- a/tests/ansible/integration/async/multiple_items_loop.yml +++ b/tests/ansible/integration/async/multiple_items_loop.yml @@ -2,7 +2,6 @@ - name: integration/async/multiple_items_loop.yml hosts: test-targets - any_errors_fatal: true tasks: - name: start long running ops diff --git a/tests/ansible/integration/async/result_binary_producing_json.yml b/tests/ansible/integration/async/result_binary_producing_json.yml index b05b24bf..4df46e76 100644 --- a/tests/ansible/integration/async/result_binary_producing_json.yml +++ b/tests/ansible/integration/async/result_binary_producing_json.yml @@ -2,7 +2,6 @@ - name: integration/async/result_binary_producing_json.yml gather_facts: true hosts: test-targets - any_errors_fatal: true tasks: - block: diff --git a/tests/ansible/integration/async/result_binary_producing_junk.yml b/tests/ansible/integration/async/result_binary_producing_junk.yml index afdf0c2f..734f0e12 100644 --- a/tests/ansible/integration/async/result_binary_producing_junk.yml +++ b/tests/ansible/integration/async/result_binary_producing_junk.yml @@ -2,7 +2,6 @@ - name: integration/async/result_binary_producing_junk.yml gather_facts: true hosts: test-targets - any_errors_fatal: true tasks: - block: diff --git a/tests/ansible/integration/async/result_shell_echo_hi.yml b/tests/ansible/integration/async/result_shell_echo_hi.yml index 6eb31702..d50a41b9 100644 --- a/tests/ansible/integration/async/result_shell_echo_hi.yml +++ b/tests/ansible/integration/async/result_shell_echo_hi.yml @@ -2,7 +2,6 @@ - name: integration/async/result_shell_echo_hi.yml gather_facts: true hosts: test-targets - any_errors_fatal: true tasks: - shell: echo hi; echo there >&2 diff --git a/tests/ansible/integration/async/runner_new_process.yml b/tests/ansible/integration/async/runner_new_process.yml index fbc7261f..0113b658 100644 --- a/tests/ansible/integration/async/runner_new_process.yml +++ b/tests/ansible/integration/async/runner_new_process.yml @@ -2,7 +2,6 @@ - name: integration/async/runner_new_process.yml hosts: test-targets - any_errors_fatal: true tasks: - name: get process ID. diff --git a/tests/ansible/integration/async/runner_one_job.yml b/tests/ansible/integration/async/runner_one_job.yml index 15e02efa..bfb50bfa 100644 --- a/tests/ansible/integration/async/runner_one_job.yml +++ b/tests/ansible/integration/async/runner_one_job.yml @@ -3,7 +3,6 @@ - name: integration/async/runner_one_job.yml hosts: test-targets - any_errors_fatal: true tasks: # Verify output of a single async job. diff --git a/tests/ansible/integration/async/runner_timeout_then_polling.yml b/tests/ansible/integration/async/runner_timeout_then_polling.yml index 6fc46ba7..2f71ebe4 100644 --- a/tests/ansible/integration/async/runner_timeout_then_polling.yml +++ b/tests/ansible/integration/async/runner_timeout_then_polling.yml @@ -2,7 +2,6 @@ - name: integration/async/runner_timeout_then_polling.yml hosts: test-targets - any_errors_fatal: true tasks: # Verify async-with-timeout-then-poll behaviour. diff --git a/tests/ansible/integration/async/runner_two_simultaneous_jobs.yml b/tests/ansible/integration/async/runner_two_simultaneous_jobs.yml index 6eda88aa..a0fd125a 100644 --- a/tests/ansible/integration/async/runner_two_simultaneous_jobs.yml +++ b/tests/ansible/integration/async/runner_two_simultaneous_jobs.yml @@ -1,7 +1,6 @@ - name: integration/async/runner_two_simultaneous_jobs.yml hosts: test-targets - any_errors_fatal: true tasks: # Start 2 duplicate jobs, verify they run concurrently. diff --git a/tests/ansible/integration/async/runner_with_polling_and_timeout.yml b/tests/ansible/integration/async/runner_with_polling_and_timeout.yml index a5cbabef..ba413372 100644 --- a/tests/ansible/integration/async/runner_with_polling_and_timeout.yml +++ b/tests/ansible/integration/async/runner_with_polling_and_timeout.yml @@ -2,7 +2,6 @@ - name: integration/async/runner_with_polling_and_timeout.yml hosts: test-targets - any_errors_fatal: true tasks: # Verify async-with-polling-and-timeout behaviour. diff --git a/tests/ansible/integration/become/su_password.yml b/tests/ansible/integration/become/su_password.yml index 7bd6db5a..bd6a0aee 100644 --- a/tests/ansible/integration/become/su_password.yml +++ b/tests/ansible/integration/become/su_password.yml @@ -4,7 +4,6 @@ - name: integration/become/su_password.yml hosts: test-targets become_method: su - any_errors_fatal: true tasks: - name: Ensure su password absent but required. diff --git a/tests/ansible/integration/become/sudo_flags_failure.yml b/tests/ansible/integration/become/sudo_flags_failure.yml index fdbb712c..75ecfebf 100644 --- a/tests/ansible/integration/become/sudo_flags_failure.yml +++ b/tests/ansible/integration/become/sudo_flags_failure.yml @@ -1,6 +1,5 @@ - name: integration/become/sudo_flags_failure.yml hosts: test-targets - any_errors_fatal: true tasks: - name: Verify behaviour for bad sudo flags. diff --git a/tests/ansible/integration/become/sudo_nonexistent.yml b/tests/ansible/integration/become/sudo_nonexistent.yml index bc3de7b8..e7a849c2 100644 --- a/tests/ansible/integration/become/sudo_nonexistent.yml +++ b/tests/ansible/integration/become/sudo_nonexistent.yml @@ -1,6 +1,5 @@ - name: integration/become/sudo_nonexistent.yml hosts: test-targets - any_errors_fatal: true tasks: - name: Verify behaviour for non-existent accounts. diff --git a/tests/ansible/integration/become/sudo_nopassword.yml b/tests/ansible/integration/become/sudo_nopassword.yml index 110c95b4..98dd9cfd 100644 --- a/tests/ansible/integration/become/sudo_nopassword.yml +++ b/tests/ansible/integration/become/sudo_nopassword.yml @@ -2,7 +2,6 @@ - name: integration/become/sudo_nopassword.yml hosts: test-targets - any_errors_fatal: true tasks: - name: Verify we aren't root diff --git a/tests/ansible/integration/become/sudo_password.yml b/tests/ansible/integration/become/sudo_password.yml index a0a1dec9..931cba27 100644 --- a/tests/ansible/integration/become/sudo_password.yml +++ b/tests/ansible/integration/become/sudo_password.yml @@ -2,7 +2,6 @@ - name: integration/become/sudo_password.yml hosts: test-targets - any_errors_fatal: true tasks: - name: Ensure sudo password absent but required. diff --git a/tests/ansible/integration/become/sudo_requiretty.yml b/tests/ansible/integration/become/sudo_requiretty.yml index 0bdfaa26..19b49b28 100644 --- a/tests/ansible/integration/become/sudo_requiretty.yml +++ b/tests/ansible/integration/become/sudo_requiretty.yml @@ -2,7 +2,6 @@ - name: integration/become/sudo_requiretty.yml hosts: test-targets - any_errors_fatal: true tasks: # TODO: https://github.com/dw/mitogen/issues/692 diff --git a/tests/ansible/integration/connection/become_same_user.yml b/tests/ansible/integration/connection/become_same_user.yml index 9f720e5c..5ff4f95b 100644 --- a/tests/ansible/integration/connection/become_same_user.yml +++ b/tests/ansible/integration/connection/become_same_user.yml @@ -4,7 +4,6 @@ - name: integration/connection/become_same_user.yml hosts: bsu-joe gather_facts: no - any_errors_fatal: true tasks: # bsu-joe's login user is joe, so become should be ignored. diff --git a/tests/ansible/integration/connection/disconnect_resets_connection.yml b/tests/ansible/integration/connection/disconnect_resets_connection.yml index 3a6f712a..95f96910 100644 --- a/tests/ansible/integration/connection/disconnect_resets_connection.yml +++ b/tests/ansible/integration/connection/disconnect_resets_connection.yml @@ -12,7 +12,6 @@ - name: integration/connection/disconnect_resets_connection.yml hosts: test-targets gather_facts: no - any_errors_fatal: true tasks: - meta: end_play when: not is_mitogen diff --git a/tests/ansible/integration/connection/exec_command.yml b/tests/ansible/integration/connection/exec_command.yml index 125def1b..f0ec1c1b 100644 --- a/tests/ansible/integration/connection/exec_command.yml +++ b/tests/ansible/integration/connection/exec_command.yml @@ -4,7 +4,6 @@ - name: integration/connection/exec_command.yml hosts: test-targets gather_facts: no - any_errors_fatal: true tasks: - connection_passthrough: method: exec_command diff --git a/tests/ansible/integration/connection/home_dir.yml b/tests/ansible/integration/connection/home_dir.yml index 1dbaa5d3..d41657bc 100644 --- a/tests/ansible/integration/connection/home_dir.yml +++ b/tests/ansible/integration/connection/home_dir.yml @@ -2,7 +2,6 @@ - name: integration/connection/home_dir.yml hosts: test-targets - any_errors_fatal: true tasks: - name: "Find out root's homedir." # Runs first because it blats regular Ansible facts with junk, so diff --git a/tests/ansible/integration/connection/put_large_file.yml b/tests/ansible/integration/connection/put_large_file.yml index 90a13999..ce8f8fe0 100644 --- a/tests/ansible/integration/connection/put_large_file.yml +++ b/tests/ansible/integration/connection/put_large_file.yml @@ -4,7 +4,6 @@ - name: integration/connection/put_large_file.yml hosts: test-targets gather_facts: no - any_errors_fatal: true vars: file_name: large-file file_size: 512 diff --git a/tests/ansible/integration/connection/put_small_file.yml b/tests/ansible/integration/connection/put_small_file.yml index 49be87a9..3e0eaaa9 100644 --- a/tests/ansible/integration/connection/put_small_file.yml +++ b/tests/ansible/integration/connection/put_small_file.yml @@ -4,7 +4,6 @@ - name: integration/connection/put_small_file.yml hosts: test-targets gather_facts: no - any_errors_fatal: true vars: file_name: small-file file_size: 123 diff --git a/tests/ansible/integration/connection_delegation/all.yml b/tests/ansible/integration/connection_delegation/all.yml index 8d5ffe03..cb55bdc7 100644 --- a/tests/ansible/integration/connection_delegation/all.yml +++ b/tests/ansible/integration/connection_delegation/all.yml @@ -1,5 +1,5 @@ - import_playbook: delegate_to_template.yml - import_playbook: local_action.yml -- import_playbook: osa_container_standalone.yml -- import_playbook: osa_delegate_to_self.yml +#- import_playbook: osa_container_standalone.yml +#- import_playbook: osa_delegate_to_self.yml - import_playbook: stack_construction.yml diff --git a/tests/ansible/integration/connection_delegation/delegate_to_template.yml b/tests/ansible/integration/connection_delegation/delegate_to_template.yml index be083ff9..14ebc8d2 100644 --- a/tests/ansible/integration/connection_delegation/delegate_to_template.yml +++ b/tests/ansible/integration/connection_delegation/delegate_to_template.yml @@ -14,7 +14,6 @@ physical_hosts: ["cd-normal-alias", "cd-normal-normal"] hosts: test-targets gather_facts: no - any_errors_fatal: true tasks: - meta: end_play when: not is_mitogen diff --git a/tests/ansible/integration/connection_delegation/stack_construction.yml b/tests/ansible/integration/connection_delegation/stack_construction.yml index ebf0f54f..ef468f1b 100644 --- a/tests/ansible/integration/connection_delegation/stack_construction.yml +++ b/tests/ansible/integration/connection_delegation/stack_construction.yml @@ -30,7 +30,6 @@ - hosts: cd-normal - any_errors_fatal: true tasks: - meta: end_play when: not is_mitogen @@ -433,6 +432,6 @@ }, 'method': 'doas', }, - ] + ] tags: - stack_construction diff --git a/tests/ansible/integration/connection_loader/local_blemished.yml b/tests/ansible/integration/connection_loader/local_blemished.yml index 85224dbf..1452abd2 100644 --- a/tests/ansible/integration/connection_loader/local_blemished.yml +++ b/tests/ansible/integration/connection_loader/local_blemished.yml @@ -2,7 +2,6 @@ - name: integration/connection_loader/local_blemished.yml hosts: test-targets - any_errors_fatal: true tasks: - determine_strategy: diff --git a/tests/ansible/integration/connection_loader/paramiko_unblemished.yml b/tests/ansible/integration/connection_loader/paramiko_unblemished.yml index 1bc5e2f6..74b3c743 100644 --- a/tests/ansible/integration/connection_loader/paramiko_unblemished.yml +++ b/tests/ansible/integration/connection_loader/paramiko_unblemished.yml @@ -3,7 +3,6 @@ - name: integration/connection_loader/paramiko_unblemished.yml hosts: test-targets - any_errors_fatal: true tasks: - debug: msg: "skipped for now" diff --git a/tests/ansible/integration/connection_loader/ssh_blemished.yml b/tests/ansible/integration/connection_loader/ssh_blemished.yml index 58d35cee..c019f208 100644 --- a/tests/ansible/integration/connection_loader/ssh_blemished.yml +++ b/tests/ansible/integration/connection_loader/ssh_blemished.yml @@ -2,7 +2,6 @@ - name: integration/connection_loader__ssh_blemished.yml hosts: test-targets - any_errors_fatal: true tasks: - determine_strategy: diff --git a/tests/ansible/integration/context_service/disconnect_cleanup.yml b/tests/ansible/integration/context_service/disconnect_cleanup.yml index 48304120..2dd10b2c 100644 --- a/tests/ansible/integration/context_service/disconnect_cleanup.yml +++ b/tests/ansible/integration/context_service/disconnect_cleanup.yml @@ -3,7 +3,6 @@ - name: integration/context_service/disconnect_cleanup.yml hosts: test-targets[0] - any_errors_fatal: true tasks: - meta: end_play when: not is_mitogen diff --git a/tests/ansible/integration/context_service/lru_one_target.yml b/tests/ansible/integration/context_service/lru_one_target.yml index 2d6dc6cf..570581e3 100644 --- a/tests/ansible/integration/context_service/lru_one_target.yml +++ b/tests/ansible/integration/context_service/lru_one_target.yml @@ -2,7 +2,6 @@ - name: integration/context_service/lru_one_target.yml hosts: test-targets - any_errors_fatal: true vars: max_interps: "{{lookup('env', 'MITOGEN_MAX_INTERPRETERS')}}" ubound: "{{max_interps|int + 1}}" diff --git a/tests/ansible/integration/context_service/reconnection.yml b/tests/ansible/integration/context_service/reconnection.yml index 2d7dbacf..4fc975a1 100644 --- a/tests/ansible/integration/context_service/reconnection.yml +++ b/tests/ansible/integration/context_service/reconnection.yml @@ -3,7 +3,6 @@ - name: integration/context_service/reconnection.yml hosts: test-targets - any_errors_fatal: true tasks: - mitogen_shutdown_all: diff --git a/tests/ansible/integration/context_service/remote_name.yml b/tests/ansible/integration/context_service/remote_name.yml index cce209e4..17ade617 100644 --- a/tests/ansible/integration/context_service/remote_name.yml +++ b/tests/ansible/integration/context_service/remote_name.yml @@ -2,7 +2,6 @@ - name: integration/context_service/remote_name.yml hosts: test-targets[0] - any_errors_fatal: true tasks: - meta: end_play when: not is_mitogen diff --git a/tests/ansible/integration/interpreter_discovery/ansible_2_8_tests.yml b/tests/ansible/integration/interpreter_discovery/ansible_2_8_tests.yml index 201ef8b4..ea828aa8 100644 --- a/tests/ansible/integration/interpreter_discovery/ansible_2_8_tests.yml +++ b/tests/ansible/integration/interpreter_discovery/ansible_2_8_tests.yml @@ -3,7 +3,6 @@ - name: integration/interpreter_discovery/ansible_2_8_tests.yml hosts: test-targets - any_errors_fatal: true gather_facts: true tasks: - name: can only run these tests on ansible >= 2.8.0 diff --git a/tests/ansible/integration/interpreter_discovery/complex_args.yml b/tests/ansible/integration/interpreter_discovery/complex_args.yml index ca35a402..38d10124 100644 --- a/tests/ansible/integration/interpreter_discovery/complex_args.yml +++ b/tests/ansible/integration/interpreter_discovery/complex_args.yml @@ -3,7 +3,6 @@ - name: integration/interpreter_discovery/complex_args.yml hosts: test-targets - any_errors_fatal: true gather_facts: true tasks: - name: create temp file to source diff --git a/tests/ansible/integration/local/cwd_preserved.yml b/tests/ansible/integration/local/cwd_preserved.yml index 24a34ba8..c1dfc99d 100644 --- a/tests/ansible/integration/local/cwd_preserved.yml +++ b/tests/ansible/integration/local/cwd_preserved.yml @@ -5,7 +5,6 @@ # https://github.com/ansible/ansible/issues/14489 - name: integration/local/cwd_preserved.yml - any_errors_fatal: true hosts: test-targets tasks: - connection: local diff --git a/tests/ansible/integration/module_utils/adjacent_to_playbook.yml b/tests/ansible/integration/module_utils/adjacent_to_playbook.yml index edd65db7..40da94d0 100644 --- a/tests/ansible/integration/module_utils/adjacent_to_playbook.yml +++ b/tests/ansible/integration/module_utils/adjacent_to_playbook.yml @@ -3,7 +3,6 @@ - name: integration/module_utils/adjacent_to_playbook.yml hosts: test-targets - any_errors_fatal: true tasks: - custom_python_external_module: diff --git a/tests/ansible/integration/module_utils/adjacent_to_role.yml b/tests/ansible/integration/module_utils/adjacent_to_role.yml index 4430c2d9..c4fb813f 100644 --- a/tests/ansible/integration/module_utils/adjacent_to_role.yml +++ b/tests/ansible/integration/module_utils/adjacent_to_role.yml @@ -3,7 +3,6 @@ - name: integration/module_utils/adjacent_to_playbook.yml hosts: test-targets - any_errors_fatal: true roles: - modrole tags: diff --git a/tests/ansible/integration/module_utils/from_config_path.yml b/tests/ansible/integration/module_utils/from_config_path.yml index 0fb0f3ea..f4d9186b 100644 --- a/tests/ansible/integration/module_utils/from_config_path.yml +++ b/tests/ansible/integration/module_utils/from_config_path.yml @@ -2,7 +2,6 @@ - name: integration/module_utils/from_config_path.yml hosts: test-targets - any_errors_fatal: true tasks: - custom_python_external_module: diff --git a/tests/ansible/integration/module_utils/from_config_path_pkg.yml b/tests/ansible/integration/module_utils/from_config_path_pkg.yml index 3453cf29..3e81f10f 100644 --- a/tests/ansible/integration/module_utils/from_config_path_pkg.yml +++ b/tests/ansible/integration/module_utils/from_config_path_pkg.yml @@ -2,7 +2,6 @@ - name: integration/module_utils/from_config_path.yml hosts: test-targets - any_errors_fatal: true tasks: - custom_python_external_pkg: diff --git a/tests/ansible/integration/module_utils/overrides_builtin.yml b/tests/ansible/integration/module_utils/overrides_builtin.yml index 86d88312..9d841e2e 100644 --- a/tests/ansible/integration/module_utils/overrides_builtin.yml +++ b/tests/ansible/integration/module_utils/overrides_builtin.yml @@ -1,7 +1,6 @@ - name: integration/module_utils/overrides_builtin.yml hosts: test-targets - any_errors_fatal: true roles: - overrides_modrole tags: diff --git a/tests/ansible/integration/playbook_semantics/become_flags.yml b/tests/ansible/integration/playbook_semantics/become_flags.yml index ac762643..9c6c8d90 100644 --- a/tests/ansible/integration/playbook_semantics/become_flags.yml +++ b/tests/ansible/integration/playbook_semantics/become_flags.yml @@ -4,7 +4,6 @@ - name: integration/playbook_semantics/become_flags.yml hosts: test-targets - any_errors_fatal: true tasks: - name: "without -E" @@ -19,7 +18,6 @@ - become_flags - hosts: test-targets - any_errors_fatal: true become_flags: -E tasks: - name: "with -E" diff --git a/tests/ansible/integration/playbook_semantics/delegate_to.yml b/tests/ansible/integration/playbook_semantics/delegate_to.yml index 7536258f..c8d9e607 100644 --- a/tests/ansible/integration/playbook_semantics/delegate_to.yml +++ b/tests/ansible/integration/playbook_semantics/delegate_to.yml @@ -1,6 +1,5 @@ - name: integration/playbook_semantics/delegate_to.yml hosts: test-targets - any_errors_fatal: true tasks: # # delegate_to, no sudo diff --git a/tests/ansible/integration/playbook_semantics/environment.yml b/tests/ansible/integration/playbook_semantics/environment.yml index 01e8ce04..69728981 100644 --- a/tests/ansible/integration/playbook_semantics/environment.yml +++ b/tests/ansible/integration/playbook_semantics/environment.yml @@ -2,7 +2,6 @@ - name: integration/playbook_semantics/environment.yml hosts: test-targets - any_errors_fatal: true tasks: - shell: echo $SOME_ENV environment: diff --git a/tests/ansible/integration/playbook_semantics/with_items.yml b/tests/ansible/integration/playbook_semantics/with_items.yml index 12a92bba..4de29c4b 100644 --- a/tests/ansible/integration/playbook_semantics/with_items.yml +++ b/tests/ansible/integration/playbook_semantics/with_items.yml @@ -3,7 +3,6 @@ - name: integration/playbook_semantics/with_items.yml hosts: test-targets - any_errors_fatal: true tasks: # TODO: https://github.com/dw/mitogen/issues/692 diff --git a/tests/ansible/integration/runner/builtin_command_module.yml b/tests/ansible/integration/runner/builtin_command_module.yml index b567bee6..70ed94ba 100644 --- a/tests/ansible/integration/runner/builtin_command_module.yml +++ b/tests/ansible/integration/runner/builtin_command_module.yml @@ -1,7 +1,6 @@ - name: integration/runner/builtin_command_module.yml hosts: test-targets - any_errors_fatal: true gather_facts: true tasks: - command: hostname diff --git a/tests/ansible/integration/runner/custom_bash_hashbang_argument.yml b/tests/ansible/integration/runner/custom_bash_hashbang_argument.yml index d2d2281c..ebb7966e 100644 --- a/tests/ansible/integration/runner/custom_bash_hashbang_argument.yml +++ b/tests/ansible/integration/runner/custom_bash_hashbang_argument.yml @@ -1,7 +1,6 @@ # https://github.com/dw/mitogen/issues/291 - name: integration/runner/custom_bash_hashbang_argument.yml hosts: test-targets - any_errors_fatal: true tasks: - custom_bash_old_style_module: diff --git a/tests/ansible/integration/runner/custom_bash_old_style_module.yml b/tests/ansible/integration/runner/custom_bash_old_style_module.yml index 122b8fde..81ab5d07 100644 --- a/tests/ansible/integration/runner/custom_bash_old_style_module.yml +++ b/tests/ansible/integration/runner/custom_bash_old_style_module.yml @@ -1,6 +1,5 @@ - name: integration/runner/custom_bash_old_style_module.yml hosts: test-targets - any_errors_fatal: true tasks: - custom_bash_old_style_module: diff --git a/tests/ansible/integration/runner/custom_bash_want_json_module.yml b/tests/ansible/integration/runner/custom_bash_want_json_module.yml index b4242e9a..24d9a064 100644 --- a/tests/ansible/integration/runner/custom_bash_want_json_module.yml +++ b/tests/ansible/integration/runner/custom_bash_want_json_module.yml @@ -1,6 +1,5 @@ - name: integration/runner/custom_bash_want_json_module.yml hosts: test-targets - any_errors_fatal: true tasks: - custom_bash_want_json_module: foo: true diff --git a/tests/ansible/integration/runner/custom_binary_producing_json.yml b/tests/ansible/integration/runner/custom_binary_producing_json.yml index 6dfeefc3..4c6e2468 100644 --- a/tests/ansible/integration/runner/custom_binary_producing_json.yml +++ b/tests/ansible/integration/runner/custom_binary_producing_json.yml @@ -1,6 +1,5 @@ - name: integration/runner/custom_binary_producing_json.yml hosts: test-targets - any_errors_fatal: true gather_facts: true tasks: - block: diff --git a/tests/ansible/integration/runner/custom_binary_producing_junk.yml b/tests/ansible/integration/runner/custom_binary_producing_junk.yml index 97fc92fe..c2fb7ccd 100644 --- a/tests/ansible/integration/runner/custom_binary_producing_junk.yml +++ b/tests/ansible/integration/runner/custom_binary_producing_junk.yml @@ -24,7 +24,6 @@ - hosts: test-targets - any_errors_fatal: true tasks: - assert: that: diff --git a/tests/ansible/integration/runner/custom_binary_single_null.yml b/tests/ansible/integration/runner/custom_binary_single_null.yml index 353cc58d..a666ad68 100644 --- a/tests/ansible/integration/runner/custom_binary_single_null.yml +++ b/tests/ansible/integration/runner/custom_binary_single_null.yml @@ -10,7 +10,6 @@ - custom_binary_single_null - hosts: test-targets - any_errors_fatal: true tasks: - assert: that: diff --git a/tests/ansible/integration/runner/custom_perl_json_args_module.yml b/tests/ansible/integration/runner/custom_perl_json_args_module.yml index 68230420..76ead985 100644 --- a/tests/ansible/integration/runner/custom_perl_json_args_module.yml +++ b/tests/ansible/integration/runner/custom_perl_json_args_module.yml @@ -1,6 +1,5 @@ - name: integration/runner/custom_perl_json_args_module.yml hosts: test-targets - any_errors_fatal: true tasks: - custom_perl_json_args_module: foo: true diff --git a/tests/ansible/integration/runner/custom_perl_want_json_module.yml b/tests/ansible/integration/runner/custom_perl_want_json_module.yml index 44c39e64..2e520329 100644 --- a/tests/ansible/integration/runner/custom_perl_want_json_module.yml +++ b/tests/ansible/integration/runner/custom_perl_want_json_module.yml @@ -1,6 +1,5 @@ - name: integration/runner/custom_perl_want_json_module.yml hosts: test-targets - any_errors_fatal: true tasks: - custom_perl_want_json_module: foo: true diff --git a/tests/ansible/integration/runner/custom_python_json_args_module.yml b/tests/ansible/integration/runner/custom_python_json_args_module.yml index 33a03ba0..d72ff0fa 100644 --- a/tests/ansible/integration/runner/custom_python_json_args_module.yml +++ b/tests/ansible/integration/runner/custom_python_json_args_module.yml @@ -1,6 +1,5 @@ - name: integration/runner/custom_python_json_args_module.yml hosts: test-targets - any_errors_fatal: true tasks: - custom_python_json_args_module: foo: true diff --git a/tests/ansible/integration/runner/custom_python_new_style_missing_interpreter.yml b/tests/ansible/integration/runner/custom_python_new_style_missing_interpreter.yml index 1562e307..0c620dac 100644 --- a/tests/ansible/integration/runner/custom_python_new_style_missing_interpreter.yml +++ b/tests/ansible/integration/runner/custom_python_new_style_missing_interpreter.yml @@ -1,7 +1,6 @@ - name: integration/runner/custom_python_new_style_module.yml hosts: test-targets - any_errors_fatal: true tasks: - custom_python_new_style_missing_interpreter: foo: true diff --git a/tests/ansible/integration/runner/custom_python_new_style_module.yml b/tests/ansible/integration/runner/custom_python_new_style_module.yml index b22fdc14..e2384f81 100644 --- a/tests/ansible/integration/runner/custom_python_new_style_module.yml +++ b/tests/ansible/integration/runner/custom_python_new_style_module.yml @@ -1,6 +1,5 @@ - name: integration/runner/custom_python_new_style_module.yml hosts: test-targets - any_errors_fatal: true tasks: # without Mitogen Ansible 2.10 hangs on this play - meta: end_play diff --git a/tests/ansible/integration/runner/custom_python_prehistoric_module.yml b/tests/ansible/integration/runner/custom_python_prehistoric_module.yml index 4ddec8c5..f2a3eefd 100644 --- a/tests/ansible/integration/runner/custom_python_prehistoric_module.yml +++ b/tests/ansible/integration/runner/custom_python_prehistoric_module.yml @@ -2,7 +2,6 @@ - name: integration/runner/custom_python_prehistoric_module.yml hosts: test-targets - any_errors_fatal: true tasks: - custom_python_prehistoric_module: register: out diff --git a/tests/ansible/integration/runner/custom_python_want_json_module.yml b/tests/ansible/integration/runner/custom_python_want_json_module.yml index d704ee11..a9bbd5b2 100644 --- a/tests/ansible/integration/runner/custom_python_want_json_module.yml +++ b/tests/ansible/integration/runner/custom_python_want_json_module.yml @@ -1,6 +1,5 @@ - name: integration/runner/custom_python_want_json_module.yml hosts: test-targets - any_errors_fatal: true tasks: - custom_python_want_json_module: foo: true diff --git a/tests/ansible/integration/runner/custom_script_interpreter.yml b/tests/ansible/integration/runner/custom_script_interpreter.yml index 03ea6718..9849912e 100644 --- a/tests/ansible/integration/runner/custom_script_interpreter.yml +++ b/tests/ansible/integration/runner/custom_script_interpreter.yml @@ -1,6 +1,5 @@ - name: integration/runner/custom_script_interpreter.yml hosts: test-targets - any_errors_fatal: true tasks: - custom_bash_old_style_module: diff --git a/tests/ansible/integration/runner/environment_isolation.yml b/tests/ansible/integration/runner/environment_isolation.yml index 90110d01..c3e7b16e 100644 --- a/tests/ansible/integration/runner/environment_isolation.yml +++ b/tests/ansible/integration/runner/environment_isolation.yml @@ -3,7 +3,6 @@ - name: integration/runner/environment_isolation.yml hosts: test-targets - any_errors_fatal: true gather_facts: true tasks: diff --git a/tests/ansible/integration/runner/etc_environment.yml b/tests/ansible/integration/runner/etc_environment.yml index 3a44c753..6ed3e9c2 100644 --- a/tests/ansible/integration/runner/etc_environment.yml +++ b/tests/ansible/integration/runner/etc_environment.yml @@ -4,7 +4,6 @@ - name: integration/runner/etc_environment.yml hosts: test-targets[0] - any_errors_fatal: true gather_facts: true tasks: - include: _etc_environment_user.yml diff --git a/tests/ansible/integration/runner/forking_active.yml b/tests/ansible/integration/runner/forking_active.yml index 6a0e322d..5198ee1c 100644 --- a/tests/ansible/integration/runner/forking_active.yml +++ b/tests/ansible/integration/runner/forking_active.yml @@ -1,6 +1,5 @@ - name: integration/runner/forking_active.yml hosts: test-targets - any_errors_fatal: true tasks: # Verify mitogen_task_isolation=fork triggers forking. diff --git a/tests/ansible/integration/runner/forking_correct_parent.yml b/tests/ansible/integration/runner/forking_correct_parent.yml index 7fe54e7b..8f360bb7 100644 --- a/tests/ansible/integration/runner/forking_correct_parent.yml +++ b/tests/ansible/integration/runner/forking_correct_parent.yml @@ -1,7 +1,6 @@ - name: integration/runner/forking_correct_parent.yml hosts: test-targets - any_errors_fatal: true tasks: # Verify mitogen_task_isolation=fork forks from "virginal fork parent", not diff --git a/tests/ansible/integration/runner/forking_inactive.yml b/tests/ansible/integration/runner/forking_inactive.yml index 37282f82..91355489 100644 --- a/tests/ansible/integration/runner/forking_inactive.yml +++ b/tests/ansible/integration/runner/forking_inactive.yml @@ -2,7 +2,6 @@ - name: integration/runner/forking_inactive.yml hosts: test-targets - any_errors_fatal: true tasks: - name: get process ID. diff --git a/tests/ansible/integration/ssh/variables.yml b/tests/ansible/integration/ssh/variables.yml index d05ac288..f596da63 100644 --- a/tests/ansible/integration/ssh/variables.yml +++ b/tests/ansible/integration/ssh/variables.yml @@ -13,9 +13,9 @@ -o "ControlPath /tmp/mitogen-ansible-test-{{18446744073709551615|random}}" tasks: - - name: ansible_ssh_user - # Remaining tests just use "ansible_user". + - name: ansible_ssh_user, ansible_ssh_pass shell: > + ANSIBLE_ANY_ERRORS_FATAL=false ANSIBLE_STRATEGY=mitogen_linear ANSIBLE_SSH_ARGS="" ansible -m shell -a whoami -i "{{MITOGEN_INVENTORY_FILE}}" test-targets @@ -26,7 +26,9 @@ register: out when: is_mitogen - - shell: > + - name: ansible_ssh_user, wrong ansible_ssh_pass + shell: > + ANSIBLE_ANY_ERRORS_FATAL=false ANSIBLE_STRATEGY=mitogen_linear ANSIBLE_SSH_ARGS="" ansible -m shell -a whoami -i "{{MITOGEN_INVENTORY_FILE}}" test-targets @@ -39,13 +41,15 @@ when: is_mitogen - assert: - that: out.rc == 4 # unreachable + that: + - out.rc == 4 # ansible.executor.task_queue_manager.TaskQueueManager.RUN_UNREACHABLE_HOSTS fail_msg: out={{out}} when: is_mitogen - - name: ansible_ssh_pass + - name: ansible_user, ansible_ssh_pass shell: > + ANSIBLE_ANY_ERRORS_FATAL=false ANSIBLE_STRATEGY=mitogen_linear ANSIBLE_SSH_ARGS="" ansible -m shell -a whoami -i "{{MITOGEN_INVENTORY_FILE}}" test-targets @@ -56,7 +60,9 @@ register: out when: is_mitogen - - shell: > + - name: ansible_user, wrong ansible_ssh_pass + shell: > + ANSIBLE_ANY_ERRORS_FATAL=false ANSIBLE_STRATEGY=mitogen_linear ANSIBLE_SSH_ARGS="" ansible -m shell -a whoami -i "{{MITOGEN_INVENTORY_FILE}}" test-targets @@ -69,13 +75,15 @@ when: is_mitogen - assert: - that: out.rc == 4 # unreachable + that: + - out.rc == 4 # ansible.executor.task_queue_manager.TaskQueueManager.RUN_UNREACHABLE_HOSTS fail_msg: out={{out}} when: is_mitogen - - name: ansible_password + - name: ansible_user, ansible_password shell: > + ANSIBLE_ANY_ERRORS_FATAL=false ANSIBLE_STRATEGY=mitogen_linear ANSIBLE_SSH_ARGS="" ansible -m shell -a whoami -i "{{MITOGEN_INVENTORY_FILE}}" test-targets @@ -86,7 +94,9 @@ register: out when: is_mitogen - - shell: > + - name: ansible_user, wrong ansible_password + shell: > + ANSIBLE_ANY_ERRORS_FATAL=false ANSIBLE_STRATEGY=mitogen_linear ANSIBLE_SSH_ARGS="" ansible -m shell -a whoami -i "{{MITOGEN_INVENTORY_FILE}}" test-targets @@ -99,18 +109,20 @@ when: is_mitogen - assert: - that: out.rc == 4 # unreachable + that: + - out.rc == 4 # ansible.executor.task_queue_manager.TaskQueueManager.RUN_UNREACHABLE_HOSTS fail_msg: out={{out}} when: is_mitogen - - name: ansible_ssh_private_key_file + - name: setup ansible_ssh_private_key_file shell: chmod 0600 ../data/docker/mitogen__has_sudo_pubkey.key args: chdir: ../.. - - name: ansible_ssh_private_key_file + - name: ansible_user, ansible_ssh_private_key_file shell: > + ANSIBLE_ANY_ERRORS_FATAL=false ANSIBLE_STRATEGY=mitogen_linear ANSIBLE_SSH_ARGS="" ansible -m shell -a whoami -i "{{MITOGEN_INVENTORY_FILE}}" test-targets @@ -121,7 +133,9 @@ register: out when: is_mitogen - - shell: > + - name: ansible_user, wrong ansible_ssh_private_key_file + shell: > + ANSIBLE_ANY_ERRORS_FATAL=false ANSIBLE_STRATEGY=mitogen_linear ANSIBLE_SSH_ARGS="" ansible -m shell -a whoami -i "{{MITOGEN_INVENTORY_FILE}}" test-targets @@ -134,6 +148,7 @@ when: is_mitogen - assert: - that: out.rc == 4 # unreachable + that: + - out.rc == 4 # ansible.executor.task_queue_manager.TaskQueueManager.RUN_UNREACHABLE_HOSTS fail_msg: out={{out}} when: is_mitogen diff --git a/tests/ansible/integration/strategy/_mixed_mitogen_vanilla.yml b/tests/ansible/integration/strategy/_mixed_mitogen_vanilla.yml index b2ae7641..e4df9378 100644 --- a/tests/ansible/integration/strategy/_mixed_mitogen_vanilla.yml +++ b/tests/ansible/integration/strategy/_mixed_mitogen_vanilla.yml @@ -3,7 +3,6 @@ - name: integration/strategy/_mixed_mitogen_vanilla.yml (mitogen_linear) hosts: test-targets[0] - any_errors_fatal: true strategy: mitogen_linear run_once: true tasks: @@ -22,7 +21,6 @@ - name: integration/strategy/_mixed_mitogen_vanilla.yml (linear) hosts: test-targets[0] - any_errors_fatal: true strategy: linear tasks: - custom_python_detect_environment: @@ -40,7 +38,6 @@ - name: integration/strategy/_mixed_mitogen_vanilla.yml (mitogen_linear) hosts: test-targets[0] - any_errors_fatal: true strategy: mitogen_linear tasks: - custom_python_detect_environment: diff --git a/tests/ansible/integration/strategy/_mixed_vanilla_mitogen.yml b/tests/ansible/integration/strategy/_mixed_vanilla_mitogen.yml index e073d11a..d2bdfdb8 100644 --- a/tests/ansible/integration/strategy/_mixed_vanilla_mitogen.yml +++ b/tests/ansible/integration/strategy/_mixed_vanilla_mitogen.yml @@ -3,7 +3,6 @@ - name: integration/strategy/_mixed_vanilla_mitogen.yml (linear) hosts: test-targets[0] - any_errors_fatal: true strategy: linear tasks: - custom_python_detect_environment: @@ -21,7 +20,6 @@ - name: integration/strategy/_mixed_vanilla_mitogen.yml (mitogen_linear) hosts: test-targets[0] - any_errors_fatal: true strategy: mitogen_linear tasks: - custom_python_detect_environment: @@ -39,7 +37,6 @@ - name: integration/strategy/_mixed_vanilla_mitogen.yml (linear) hosts: test-targets[0] - any_errors_fatal: true strategy: linear tasks: - custom_python_detect_environment: diff --git a/tests/ansible/integration/strategy/mixed_vanilla_mitogen.yml b/tests/ansible/integration/strategy/mixed_vanilla_mitogen.yml index 0f462fea..796cbfef 100644 --- a/tests/ansible/integration/strategy/mixed_vanilla_mitogen.yml +++ b/tests/ansible/integration/strategy/mixed_vanilla_mitogen.yml @@ -1,7 +1,6 @@ - name: integration/strategy/mixed_vanilla_mitogen.yml (linear->mitogen->linear) hosts: test-targets[0] - any_errors_fatal: true tasks: - connection: local command: | diff --git a/tests/ansible/integration/stub_connections/kubectl.yml b/tests/ansible/integration/stub_connections/kubectl.yml index 5303f7c7..47777ba8 100644 --- a/tests/ansible/integration/stub_connections/kubectl.yml +++ b/tests/ansible/integration/stub_connections/kubectl.yml @@ -2,7 +2,6 @@ - name: integration/stub_connections/kubectl.yml hosts: test-targets gather_facts: false - any_errors_fatal: true tasks: - meta: end_play when: not is_mitogen diff --git a/tests/ansible/integration/stub_connections/lxc.yml b/tests/ansible/integration/stub_connections/lxc.yml index ec79cdac..abe354b6 100644 --- a/tests/ansible/integration/stub_connections/lxc.yml +++ b/tests/ansible/integration/stub_connections/lxc.yml @@ -2,7 +2,6 @@ - name: integration/stub_connections/lxc.yml hosts: test-targets gather_facts: false - any_errors_fatal: true tasks: - meta: end_play when: not is_mitogen diff --git a/tests/ansible/integration/stub_connections/lxd.yml b/tests/ansible/integration/stub_connections/lxd.yml index cb03232f..5314f82c 100644 --- a/tests/ansible/integration/stub_connections/lxd.yml +++ b/tests/ansible/integration/stub_connections/lxd.yml @@ -2,7 +2,6 @@ - name: integration/stub_connections/lxd.yml hosts: test-targets gather_facts: false - any_errors_fatal: true tasks: - meta: end_play when: not is_mitogen diff --git a/tests/ansible/integration/stub_connections/mitogen_doas.yml b/tests/ansible/integration/stub_connections/mitogen_doas.yml index 5e545935..87764d12 100644 --- a/tests/ansible/integration/stub_connections/mitogen_doas.yml +++ b/tests/ansible/integration/stub_connections/mitogen_doas.yml @@ -2,7 +2,6 @@ - name: integration/stub_connections/mitogen_doas.yml hosts: test-targets gather_facts: false - any_errors_fatal: true tasks: - meta: end_play when: not is_mitogen diff --git a/tests/ansible/integration/stub_connections/mitogen_sudo.yml b/tests/ansible/integration/stub_connections/mitogen_sudo.yml index 36f69814..6da0e5d6 100644 --- a/tests/ansible/integration/stub_connections/mitogen_sudo.yml +++ b/tests/ansible/integration/stub_connections/mitogen_sudo.yml @@ -2,7 +2,6 @@ - name: integration/stub_connections/mitogen_sudo.yml hosts: test-targets gather_facts: false - any_errors_fatal: true tasks: - meta: end_play when: not is_mitogen diff --git a/tests/ansible/integration/transport_config/port.yml b/tests/ansible/integration/transport_config/port.yml index 6014ffae..340eae79 100644 --- a/tests/ansible/integration/transport_config/port.yml +++ b/tests/ansible/integration/transport_config/port.yml @@ -41,7 +41,7 @@ - out.result[0].kwargs.port == 4321 fail_msg: out={{out}} -- hosts: tc-port-explicit-unset +- hosts: tc-port-unset vars: {mitogen_via: tc-port-explicit-ssh} tasks: - include: ../_mitogen_only.yml @@ -50,9 +50,9 @@ that: - out.result|length == 2 - out.result[0].method == "ssh" - - out.result[1].kwargs.port == 4321 + - out.result[0].kwargs.port == 4321 - out.result[1].method == "ssh" - - out.result[0].kwargs.port == None + - out.result[1].kwargs.port == None fail_msg: out={{out}} # ansible_port= diff --git a/tests/ansible/integration/transport_config/remote_user.yml b/tests/ansible/integration/transport_config/remote_user.yml index b873fcbe..5ddc5aa3 100644 --- a/tests/ansible/integration/transport_config/remote_user.yml +++ b/tests/ansible/integration/transport_config/remote_user.yml @@ -60,7 +60,7 @@ left: out.result[0].kwargs.username right: "ansi-user" -- hosts: tc-remote-user-explicit-host +- hosts: tc-remote-user-explicit-user vars: {mitogen_via: tc-remote-user-unset} tasks: - include: ../_mitogen_only.yml diff --git a/tests/ansible/regression/issue_109__target_has_old_ansible_installed.yml b/tests/ansible/regression/issue_109__target_has_old_ansible_installed.yml index 1188b6ce..5343989c 100644 --- a/tests/ansible/regression/issue_109__target_has_old_ansible_installed.yml +++ b/tests/ansible/regression/issue_109__target_has_old_ansible_installed.yml @@ -3,7 +3,6 @@ - name: regression/issue_109__target_has_old_ansible_installed.yml hosts: test-targets - any_errors_fatal: true gather_facts: true tasks: - meta: end_play diff --git a/tests/ansible/regression/issue_113__duplicate_module_imports.yml b/tests/ansible/regression/issue_113__duplicate_module_imports.yml index b479e025..4975a07c 100644 --- a/tests/ansible/regression/issue_113__duplicate_module_imports.yml +++ b/tests/ansible/regression/issue_113__duplicate_module_imports.yml @@ -2,7 +2,6 @@ # by exercisizng the uri package. - name: regression/issue_113__duplicate_module_imports.yml - any_errors_fatal: true hosts: test-targets tasks: diff --git a/tests/ansible/regression/issue_140__thread_pileup.yml b/tests/ansible/regression/issue_140__thread_pileup.yml index e6ea83ce..23649f92 100644 --- a/tests/ansible/regression/issue_140__thread_pileup.yml +++ b/tests/ansible/regression/issue_140__thread_pileup.yml @@ -4,7 +4,6 @@ - name: regression/issue_140__thread_pileup.yml hosts: test-targets - any_errors_fatal: true tasks: - name: Create file tree diff --git a/tests/ansible/regression/issue_152__local_action_wrong_interpreter.yml b/tests/ansible/regression/issue_152__local_action_wrong_interpreter.yml index 4da6f544..c53d34e4 100644 --- a/tests/ansible/regression/issue_152__local_action_wrong_interpreter.yml +++ b/tests/ansible/regression/issue_152__local_action_wrong_interpreter.yml @@ -6,7 +6,6 @@ - name: regression/issue_152__local_action_wrong_interpreter.yml hosts: test-targets connection: local - any_errors_fatal: true tasks: - copy: diff --git a/tests/ansible/regression/issue_152__virtualenv_python_fails.yml b/tests/ansible/regression/issue_152__virtualenv_python_fails.yml index 11f94edd..34a57a8a 100644 --- a/tests/ansible/regression/issue_152__virtualenv_python_fails.yml +++ b/tests/ansible/regression/issue_152__virtualenv_python_fails.yml @@ -1,5 +1,4 @@ - name: regression/issue_152__virtualenv_python_fails.yml - any_errors_fatal: true gather_facts: true hosts: test-targets tasks: diff --git a/tests/ansible/regression/issue_154__module_state_leaks.yml b/tests/ansible/regression/issue_154__module_state_leaks.yml index 59b970d9..3a7ee309 100644 --- a/tests/ansible/regression/issue_154__module_state_leaks.yml +++ b/tests/ansible/regression/issue_154__module_state_leaks.yml @@ -2,7 +2,6 @@ # must be reinitialized or cleared out somehow on each invocation. - name: regression/issue_154__module_state_leaks.yml - any_errors_fatal: true hosts: test-targets tasks: diff --git a/tests/ansible/regression/issue_177__copy_module_failing.yml b/tests/ansible/regression/issue_177__copy_module_failing.yml index 7da39962..948621d3 100644 --- a/tests/ansible/regression/issue_177__copy_module_failing.yml +++ b/tests/ansible/regression/issue_177__copy_module_failing.yml @@ -1,5 +1,4 @@ - name: regression/issue_177__copy_module_failing.yml - any_errors_fatal: true hosts: test-targets tasks: diff --git a/tests/ansible/regression/issue_615__streaming_transfer.yml b/tests/ansible/regression/issue_615__streaming_transfer.yml index 56a7ec41..1c69914d 100644 --- a/tests/ansible/regression/issue_615__streaming_transfer.yml +++ b/tests/ansible/regression/issue_615__streaming_transfer.yml @@ -2,7 +2,6 @@ - name: regression/issue_615_streaming_transfer.yml hosts: test-targets - any_errors_fatal: True gather_facts: no # Without Mitogen this causes Ansible to use the slurp module, which is *slow* become: true diff --git a/tests/ansible/regression/issue_655__wait_for_connection_error.yml b/tests/ansible/regression/issue_655__wait_for_connection_error.yml index eedec635..fbdb9f2b 100644 --- a/tests/ansible/regression/issue_655__wait_for_connection_error.yml +++ b/tests/ansible/regression/issue_655__wait_for_connection_error.yml @@ -4,10 +4,8 @@ # since things are ran on localhost; Azure DevOps loses connection and fails # TODO: do we want to install docker a different way to be able to do this for other tests too --- -# this should only run on our Mac hosts - name: regression/issue_655_wait_for_connection_error.yml - hosts: targets - any_errors_fatal: True + hosts: localhost gather_facts: yes become: no tasks: @@ -85,5 +83,7 @@ loop: - cmd: podman stop testMitogen - cmd: podman machine stop + when: + - ansible_facts.pkg_mgr in ['homebrew'] tags: - issue_655 diff --git a/tests/ansible/setup/report.yml b/tests/ansible/setup/report.yml index 9077158f..450e4fb0 100644 --- a/tests/ansible/setup/report.yml +++ b/tests/ansible/setup/report.yml @@ -17,3 +17,4 @@ - debug: {var: ansible_run_tags} - debug: {var: ansible_skip_tags} - debug: {var: ansible_version.full} + - debug: {var: is_mitogen} diff --git a/tests/ansible/tests/affinity_test.py b/tests/ansible/tests/affinity_test.py index 0051a701..b968071b 100644 --- a/tests/ansible/tests/affinity_test.py +++ b/tests/ansible/tests/affinity_test.py @@ -205,7 +205,7 @@ class LinuxPolicyTest(testlib.TestCase): proc.wait() his_cpu = self._get_cpus(tf.name) - self.assertNotEquals(my_cpu, his_cpu) + self.assertNotEqual(my_cpu, his_cpu) self.policy._clear() finally: tf.close() diff --git a/tox.ini b/tox.ini index 6b2addc7..bcacba03 100644 --- a/tox.ini +++ b/tox.ini @@ -86,6 +86,7 @@ passenv = AWS_SECRET_ACCESS_KEY HOME setenv = + # See also azure-pipelines.yml ANSIBLE_SKIP_TAGS = requires_local_sudo,resource_intensive ANSIBLE_STRATEGY = mitogen_linear NOCOVERAGE_ERASE = 1