mirror of https://github.com/ansible/ansible.git
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
39 lines
1003 B
YAML
39 lines
1003 B
YAML
4 years ago
|
- name: create our unarchive destination
|
||
|
file:
|
||
|
path: '{{remote_tmp_dir}}/test-unarchive-tar-gz'
|
||
|
state: directory
|
||
|
|
||
|
- name: create a directory with quotable chars
|
||
|
file:
|
||
|
path: '{{ remote_tmp_dir }}/test-quotes~root'
|
||
|
state: directory
|
||
|
|
||
|
- name: unarchive into directory with quotable chars
|
||
|
unarchive:
|
||
|
src: "{{ remote_tmp_dir }}/test-unarchive.tar.gz"
|
||
|
dest: "{{ remote_tmp_dir }}/test-quotes~root"
|
||
|
remote_src: yes
|
||
|
register: unarchive08
|
||
|
|
||
|
- name: Test that unarchive succeeded
|
||
|
assert:
|
||
|
that:
|
||
|
- "unarchive08.changed == true"
|
||
|
|
||
|
- name: unarchive into directory with quotable chars a second time
|
||
|
unarchive:
|
||
|
src: "{{ remote_tmp_dir }}/test-unarchive.tar.gz"
|
||
|
dest: "{{ remote_tmp_dir }}/test-quotes~root"
|
||
|
remote_src: yes
|
||
|
register: unarchive09
|
||
|
|
||
|
- name: Test that unarchive did nothing
|
||
|
assert:
|
||
|
that:
|
||
|
- "unarchive09.changed == false"
|
||
|
|
||
|
- name: remove quotable chars test
|
||
|
file:
|
||
|
path: '{{ remote_tmp_dir }}/test-quotes~root'
|
||
|
state: absent
|