1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00
community.general/test/integration/targets/iosxr_command/tests/cli/prompt.yaml
Nathaniel Case 5a49567c71
Fix iosxr copy and delete tasks (#44083)
* Fix iosxr copy and delete tasks

* Drop local from non-smoke tasks
2018-08-13 14:20:28 -04:00

26 lines
792 B
YAML

---
- debug:
msg: "START cli/prompt.yaml on connection={{ ansible_connection }}"
- name: delete config file on disk to prevent failure of copy task for duplicate
iosxr_command:
commands:
- command: 'delete harddisk:ansible_tmp.txt'
prompt: 'Delete harddisk\:/?ansible_tmp\.txt\[confirm\]'
answer: ""
ignore_errors: yes
- name: copy
iosxr_command:
commands:
- command: 'copy running-config harddisk:ansible_tmp.txt'
prompt: 'Destination file name \(control-c to abort\)\: \[\/ansible_tmp.txt\]\?'
answer: 'ansible_tmp.txt'
register: result
- assert:
that:
- "result.stdout is defined"
- "'ansible_tmp' in result.stdout[0]"
- debug: msg="END cli/prompt.yaml on connection={{ ansible_connection }}"