a7528cdd25
* Update the NuGet package provider when needed * Update NuGet provider conditionally
29 lines
774 B
YAML
29 lines
774 B
YAML
# This file is part of Ansible
|
|
|
|
# Copyright: (c) 2018, Wojciech Sciesinski <wojciech[at]sciesinski[dot]net>
|
|
# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)
|
|
|
|
---
|
|
|
|
- name: get PowerShell version
|
|
win_shell: '$PSVersionTable.PSVersion.Major'
|
|
register: powershell_major_version
|
|
|
|
- name: Perform integration tests for Powershell 5+
|
|
when: powershell_major_version.stdout | int >= 5
|
|
block:
|
|
|
|
- name: ensure test repository is deleted
|
|
win_psrepository:
|
|
name: '{{ repository_name }}'
|
|
state: absent
|
|
|
|
- name: run all tests
|
|
include_tasks: tests.yml
|
|
|
|
always:
|
|
|
|
- name: ensure test repository is deleted after tests run
|
|
win_psrepository:
|
|
name: '{{ repository_name }}'
|
|
state: absent
|