Skip to content

Commit

Permalink
tests: Check behaviour if ansible_remote_tmp is deleted mid-play
Browse files Browse the repository at this point in the history
  • Loading branch information
moreati committed May 21, 2024
1 parent 76047a6 commit b60878a
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 0 deletions.
1 change: 1 addition & 0 deletions tests/ansible/integration/context_service/all.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@
- import_playbook: lru_one_target.yml
- import_playbook: reconnection.yml
- import_playbook: remote_name.yml
- import_playbook: remote_tmp.yml
26 changes: 26 additions & 0 deletions tests/ansible/integration/context_service/remote_tmp.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# issue #1061: ensure remote temporary directory is recreated

- name: integration/context_service/remote_tmp.yml
hosts: test-targets
gather_facts: false
vars:
ansible_remote_tmp: ~/.ansible/remote_tmp_test
tasks:
- name: Exercise ansible_remote_tmp
copy:
dest: canary
mode: u=rw,go=
content: |
Created by integration/context_service/remote_tmp.yml
- name: Delete ansible_remote_tmp
raw: |
rm -rf "{{ ansible_remote_tmp }}"
- name: Do something else that requires ansible_remote_tmp
file:
path: canary
state: absent
tags:
- issue_1061
- remote_tmp

0 comments on commit b60878a

Please sign in to comment.