summaryrefslogtreecommitdiffstats
path: root/test/integration/targets/wait_for_connection
diff options
context:
space:
mode:
authorMatt Clay <matt@mystile.com>2020-02-26 02:57:49 +0100
committerMatt Clay <matt@mystile.com>2020-02-26 04:27:18 +0100
commita19ae28326ce861c0eeae803e939050b5bcd64bd (patch)
tree6d4b337fe81577db23816d72ee82e2ef452e0fd6 /test/integration/targets/wait_for_connection
parentClean up CONDITIONAL_BARE_VARS warning. Fixes #67735 (#67751) (diff)
downloadansible-a19ae28326ce861c0eeae803e939050b5bcd64bd.tar.xz
ansible-a19ae28326ce861c0eeae803e939050b5bcd64bd.zip
Test the delay option in wait_for_connection.
Diffstat (limited to 'test/integration/targets/wait_for_connection')
-rw-r--r--test/integration/targets/wait_for_connection/tasks/main.yml13
1 files changed, 13 insertions, 0 deletions
diff --git a/test/integration/targets/wait_for_connection/tasks/main.yml b/test/integration/targets/wait_for_connection/tasks/main.yml
index 613209e84c..19749e686e 100644
--- a/test/integration/targets/wait_for_connection/tasks/main.yml
+++ b/test/integration/targets/wait_for_connection/tasks/main.yml
@@ -4,6 +4,19 @@
sleep: 1
timeout: 10
+- name: Test normal connection to target node with delay
+ wait_for_connection:
+ connect_timeout: 5
+ sleep: 1
+ timeout: 10
+ delay: 3
+ register: result
+
+- name: Verify delay was honored
+ assert:
+ that:
+ - result.elapsed >= 3
+
- name: Use invalid parameter
wait_for_connection:
foo: bar