bcc23e70e6
* win_dns_client - fix bug in devel and added tests * Fix sanity issue
28 lines
715 B
YAML
28 lines
715 B
YAML
---
|
|
- name: create dummy network adapter device
|
|
win_device:
|
|
path: '%WinDir%\Inf\netloop.inf'
|
|
hardware_id: '*msloop'
|
|
state: present
|
|
register: test_device_name
|
|
|
|
- set_fact:
|
|
test_device_name: '{{ test_device_name.name }}'
|
|
|
|
- block:
|
|
- name: get name of the dummy network adapter
|
|
win_shell: (Get-CimInstance -Class Win32_NetworkAdapter -Filter "Name='{{ test_device_name }}'").NetConnectionID
|
|
changed_when: False
|
|
register: test_adapter
|
|
|
|
- set_fact:
|
|
test_adapter: '{{ test_adapter.stdout | trim }}'
|
|
|
|
- name: run tests
|
|
include_tasks: tests.yml
|
|
|
|
always:
|
|
- name: remove dummy network adapter device
|
|
win_device:
|
|
name: '{{ test_device_name }}'
|
|
state: absent
|