fixed testplay host, included lookup path tests in all, added stage for easier debugging

This commit is contained in:
Brian Coca 2015-08-12 19:26:04 -04:00
parent 60803a1d3c
commit 464a436f8f
3 changed files with 8 additions and 8 deletions

View file

@ -21,7 +21,7 @@ VAULT_PASSWORD_FILE = vault-password
CONSUL_RUNNING := $(shell python consul_running.py)
all: parsing test_var_precedence unicode test_templating_settings non_destructive destructive includes check_mode test_hash test_handlers test_group_by test_vault test_tags
all: parsing test_var_precedence unicode test_templating_settings non_destructive destructive includes check_mode test_hash test_handlers test_group_by test_vault test_tags test_lookup_paths
parsing:
ansible-playbook bad_parsing.yml -i $(INVENTORY) -e @$(VARS_FILE) $(CREDENTIALS_ARG) -vvv $(TEST_FLAGS) --tags prepare,common,scenario5

View file

@ -8,7 +8,7 @@
- copy: dest={{playbook_dir}}/roles/showfile/testfile content='in role'
- copy: dest={{playbook_dir}}/files/testfile content='in files'
- copy: dest={{playbook_dir}}/testfile content='in local'
- set_fact: role_out="in role files" play_out="in files"
- set_fact: role_out="in role files" play_out="in files" stage='setup'
- include: testplay.yml
@ -18,7 +18,7 @@
gather_facts: false
tasks:
- file: path={{playbook_dir}}/roles/showfile/files/testfile state=absent
- set_fact: role_out="in role tasks" play_out="in files"
- set_fact: role_out="in role tasks" play_out="in files" stage='remove 1'
- include: testplay.yml
@ -28,7 +28,7 @@
gather_facts: false
tasks:
- file: path={{playbook_dir}}/roles/showfile/tasks/testfile state=absent
- set_fact: role_out="in files" play_out="in files"
- set_fact: role_out="in files" play_out="in files" stage='remote 2'
- include: testplay.yml
@ -38,7 +38,7 @@
gather_facts: false
tasks:
- file: path={{playbook_dir}}/roles/showfile/testfile state=absent
- set_fact: role_out="in files" play_out="in files"
- set_fact: role_out="in files" play_out="in files" stage='remove 3'
- include: testplay.yml
@ -48,7 +48,7 @@
gather_facts: false
tasks:
- file: path={{playbook_dir}}/files/testfile state=absent
- set_fact: role_out="in local" play_out="in local"
- set_fact: role_out="in local" play_out="in local" stage='remove 4'
- include: testplay.yml

View file

@ -1,5 +1,5 @@
- name: test initial state
hosts: localhost
hosts: testhost
connection: local
gather_facts: false
roles:
@ -8,7 +8,7 @@
- name: from play
set_fact: play_result="{{lookup('file', 'testfile')}}"
- name: output output
- name: output output {{stage}}
debug: msg="play> {{play_out}}, role> {{role_out}}"
- name: verify that result match expected