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/win_reg_stat/tasks/main.yml
Jordan Borean 072fa54b50
win reg - Support special chars in path (#53305)
* win reg - Support special chars in path

* Added deprecation warning for path separators
2019-03-08 05:41:52 +10:00

29 lines
676 B
YAML

---
- name: get value of expand string %windir%
win_command: powershell.exe $env:windir
register: win_dir_value
- name: template out test registry structure
win_template:
src: test_reg.reg.j2
dest: '{{ win_output_dir }}\test_reg.reg'
- name: import test registry structure
win_regmerge:
path: '{{ win_output_dir }}\test_reg.reg'
- block:
- name: run tests
import_tasks: tests.yml
always:
- name: remove test registry key
win_regedit:
path: HKCU:\{{ test_reg_path }}
state: absent
delete_key: True
- name: remove template registry file
win_file:
path: '{{ win_output_dir }}\test_reg.reg'
state: absent