From 1143889f26caab75b5ac47f9f9db519658a41ea3 Mon Sep 17 00:00:00 2001 From: Matt Clay Date: Mon, 11 Mar 2019 23:49:08 -0700 Subject: [PATCH] Fix integration test inventory. --- test/integration/targets/delegate_to/inventory | 2 +- test/integration/targets/handlers/from_handlers.yml | 2 -- test/integration/targets/handlers/inventory.handlers | 4 ++++ test/integration/targets/handlers/test_force_handlers.yml | 3 --- test/integration/targets/handlers/test_handlers.yml | 4 ---- .../targets/handlers/test_handlers_any_errors_fatal.yml | 1 - .../targets/handlers/test_handlers_inexistent_notify.yml | 1 - test/integration/targets/handlers/test_handlers_listen.yml | 4 ---- test/integration/targets/handlers/test_listening_handlers.yml | 1 - test/integration/targets/unicode/inventory | 2 +- test/integration/targets/unicode/unicode.yml | 2 +- 11 files changed, 7 insertions(+), 19 deletions(-) diff --git a/test/integration/targets/delegate_to/inventory b/test/integration/targets/delegate_to/inventory index 8bf94347aa..8a2157e2bb 100644 --- a/test/integration/targets/delegate_to/inventory +++ b/test/integration/targets/delegate_to/inventory @@ -4,5 +4,5 @@ testhost2 ansible_connection=local testhost3 ansible_ssh_host=127.0.0.3 testhost4 ansible_ssh_host=127.0.0.4 -[local:vars] +[all:vars] ansible_python_interpreter="{{ ansible_playbook_python }}" diff --git a/test/integration/targets/handlers/from_handlers.yml b/test/integration/targets/handlers/from_handlers.yml index d5a202c84e..7b2dea2d53 100644 --- a/test/integration/targets/handlers/from_handlers.yml +++ b/test/integration/targets/handlers/from_handlers.yml @@ -1,7 +1,6 @@ - name: verify handlers_from on include_role hosts: A gather_facts: False - connection: local tags: ['scenario1'] tasks: - name: test include_role @@ -21,7 +20,6 @@ - name: verify handlers_from on import_role hosts: A gather_facts: False - connection: local tasks: - name: set facts to false set_fact: diff --git a/test/integration/targets/handlers/inventory.handlers b/test/integration/targets/handlers/inventory.handlers index 905026f12e..268cf65748 100644 --- a/test/integration/targets/handlers/inventory.handlers +++ b/test/integration/targets/handlers/inventory.handlers @@ -4,3 +4,7 @@ B C D E + +[testgroup:vars] +ansible_connection=local +ansible_python_interpreter="{{ ansible_playbook_python }}" diff --git a/test/integration/targets/handlers/test_force_handlers.yml b/test/integration/targets/handlers/test_force_handlers.yml index f7cadbd86d..9cff772929 100644 --- a/test/integration/targets/handlers/test_force_handlers.yml +++ b/test/integration/targets/handlers/test_force_handlers.yml @@ -4,7 +4,6 @@ tags: normal hosts: testgroup gather_facts: False - connection: local roles: - { role: test_force_handlers } tasks: @@ -14,7 +13,6 @@ tags: force_true_in_play hosts: testgroup gather_facts: False - connection: local force_handlers: True roles: - { role: test_force_handlers, tags: force_true_in_play } @@ -24,7 +22,6 @@ tags: force_false_in_play hosts: testgroup gather_facts: False - connection: local force_handlers: False roles: - { role: test_force_handlers, tags: force_false_in_play } diff --git a/test/integration/targets/handlers/test_handlers.yml b/test/integration/targets/handlers/test_handlers.yml index 142eeb387d..ae9847bae1 100644 --- a/test/integration/targets/handlers/test_handlers.yml +++ b/test/integration/targets/handlers/test_handlers.yml @@ -2,14 +2,12 @@ - name: run handlers hosts: A gather_facts: False - connection: local roles: - { role: test_handlers_meta, tags: ['scenario1'] } - name: verify final handler was run hosts: A gather_facts: False - connection: local tasks: - name: verify handler2 ran assert: @@ -21,7 +19,6 @@ - name: verify listening handlers hosts: A gather_facts: False - connection: local tasks: - name: notify some handlers command: echo foo @@ -46,6 +43,5 @@ - name: test handlers hosts: testgroup gather_facts: False - connection: local roles: - { role: test_handlers } diff --git a/test/integration/targets/handlers/test_handlers_any_errors_fatal.yml b/test/integration/targets/handlers/test_handlers_any_errors_fatal.yml index 9029443a6f..6b791a3bbb 100644 --- a/test/integration/targets/handlers/test_handlers_any_errors_fatal.yml +++ b/test/integration/targets/handlers/test_handlers_any_errors_fatal.yml @@ -3,7 +3,6 @@ - B gather_facts: no any_errors_fatal: yes - connection: local vars: output_dir: /tmp tasks: diff --git a/test/integration/targets/handlers/test_handlers_inexistent_notify.yml b/test/integration/targets/handlers/test_handlers_inexistent_notify.yml index f1c99efe12..15de38aa35 100644 --- a/test/integration/targets/handlers/test_handlers_inexistent_notify.yml +++ b/test/integration/targets/handlers/test_handlers_inexistent_notify.yml @@ -2,7 +2,6 @@ - name: notify inexistent handler hosts: localhost gather_facts: false - connection: local tasks: - name: test notify an inexistent handler command: uptime diff --git a/test/integration/targets/handlers/test_handlers_listen.yml b/test/integration/targets/handlers/test_handlers_listen.yml index b892af3b15..5477968bed 100644 --- a/test/integration/targets/handlers/test_handlers_listen.yml +++ b/test/integration/targets/handlers/test_handlers_listen.yml @@ -2,7 +2,6 @@ - name: test listen with named handlers hosts: localhost gather_facts: false - connection: local tasks: - name: test notify handlers listen command: uptime @@ -27,7 +26,6 @@ - name: test listen unnamed handlers hosts: localhost gather_facts: false - connection: local pre_tasks: - name: notify some handlers command: echo foo @@ -51,7 +49,6 @@ - name: test with mixed notify by name and listen hosts: localhost gather_facts: false - connection: local tasks: - name: test notify handlers names and identical listen command: uptime @@ -91,7 +88,6 @@ - name: test listen in roles hosts: localhost gather_facts: false - connection: local roles: - role: test_handlers_listen tasks: diff --git a/test/integration/targets/handlers/test_listening_handlers.yml b/test/integration/targets/handlers/test_listening_handlers.yml index 6500f02cfb..67bdad9aa2 100644 --- a/test/integration/targets/handlers/test_listening_handlers.yml +++ b/test/integration/targets/handlers/test_listening_handlers.yml @@ -2,7 +2,6 @@ - name: verify listening handlers hosts: A gather_facts: False - connection: local tasks: - name: notify some handlers command: echo foo diff --git a/test/integration/targets/unicode/inventory b/test/integration/targets/unicode/inventory index 256e8c0ddf..11b35606ee 100644 --- a/test/integration/targets/unicode/inventory +++ b/test/integration/targets/unicode/inventory @@ -1,5 +1,5 @@ [local] -testhost ansible_connection=local +testhost ansible_connection=local ansible_python_interpreter="{{ ansible_playbook_python }}" [all:vars] unicode_host_var=CaféEñyei diff --git a/test/integration/targets/unicode/unicode.yml b/test/integration/targets/unicode/unicode.yml index b22415a45d..672133d580 100644 --- a/test/integration/targets/unicode/unicode.yml +++ b/test/integration/targets/unicode/unicode.yml @@ -1,7 +1,6 @@ --- - name: 'A play with unicode: ¢ £ ¤ ¥' hosts: localhost - connection: local vars: test_var: 'Ī ī Ĭ ĭ Į į İ ı IJ ij Ĵ ĵ Ķ ķ ĸ Ĺ ĺ Ļ ļ Ľ ľ Ŀ ŀ Ł ł Ń ń Ņ ņ Ň ň ʼn Ŋ ŋ Ō ō Ŏ ŏ Ő ő Œ' hostnames: @@ -32,6 +31,7 @@ groups: 'ĪīĬĭ' ansible_ssh_host: 127.0.0.1 ansible_connection: local + ansible_python_interpreter: "{{ ansible_playbook_python }}" with_items: "{{ hostnames }}" - name: 'A task with unicode extra vars'