summaryrefslogtreecommitdiff
path: root/test/integration/targets/win_stat
diff options
context:
space:
mode:
authorJordan Borean <jborean93@gmail.com>2017-08-07 14:23:01 +1000
committerGitHub <noreply@github.com>2017-08-07 14:23:01 +1000
commit0b69f3e40d606d6463eeb9053a98a887503dc2c9 (patch)
tree04b16abc381bcf7a680ae9bc3d5c4e5bf0bcb9e2 /test/integration/targets/win_stat
parent107e1776585cc44b484a948e601acc3d96cb7251 (diff)
downloadansible-0b69f3e40d606d6463eeb9053a98a887503dc2c9.tar.gz
win_stat: removed file in use test as it is too tempormental (#27832)
Diffstat (limited to 'test/integration/targets/win_stat')
-rw-r--r--test/integration/targets/win_stat/tasks/main.yml22
1 files changed, 0 insertions, 22 deletions
diff --git a/test/integration/targets/win_stat/tasks/main.yml b/test/integration/targets/win_stat/tasks/main.yml
index 30cdbf9b15..bd1e3d53a9 100644
--- a/test/integration/targets/win_stat/tasks/main.yml
+++ b/test/integration/targets/win_stat/tasks/main.yml
@@ -537,29 +537,7 @@
- win_stat_no_args.msg
- not win_stat_no_args|changed
-- name: ensure file that will be in use is deleted before test
- win_file:
- path: '{{win_stat_dir}}\in_use'
- state: absent
-
-- name: lock file in the background for next task
- win_command: powershell.exe "$data = 'abcdefghijklmnopqrstuvwxyz' * 1024; $file = [System.IO.File]::Open('{{win_stat_dir}}\in_use', 'OpenOrCreate', 'ReadWrite', 'None'); $writer = New-Object IO.StreamWriter($file); $start = Get-Date; while (((Get-Date) - $start).TotalSeconds -lt 15) { $writer.WriteLine($data) }; $writer.Close(); $file.Close()"
- async: 20
- poll: 0
- register: a
-
-- name: fail to get stat of file in use
- win_stat:
- path: '{{win_stat_dir}}\in_use'
- get_md5: False
- register: fail_file_in_use
- failed_when: "'failed to get hash of file' not in fail_file_in_use.msg"
-
- name: remove testing folder
win_file:
path: "{{win_output_dir}}\\win_stat"
state: absent
- register: cleanup
- retries: 3 # in case async task is still running, try 3 times
- delay: 5
- until: not cleanup|failed