summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorToshio Kuratomi <a.badger@gmail.com>2017-10-03 07:17:12 -0700
committerToshio Kuratomi <a.badger@gmail.com>2017-10-26 17:37:11 -0700
commit638de22b350c7323c88d2af481bdf1b23bdb16b3 (patch)
tree5aef5d1dea6b50a76c5b68a5e1448a4d37fc6149
parent8c41fee7bfc180d3936875335add823e6b1accd6 (diff)
downloadansible-638de22b350c7323c88d2af481bdf1b23bdb16b3.tar.gz
Update tests for required_if changes
These tests are doing string matches on the error condition. Update them to match the new strings. This is probably okay to push out to old releases even though it's technically backwards incompatible because production playbooks won't be checking that a parameter was missing. Param missing is something detected and fixed while writing the playbook.
-rw-r--r--test/integration/targets/aws_lambda/tasks/main.yml2
-rw-r--r--test/integration/targets/cs_account/tasks/main.yml2
-rw-r--r--test/integration/targets/cs_firewall/tasks/main.yml4
-rw-r--r--test/integration/targets/cs_host/tasks/main.yml2
-rw-r--r--test/integration/targets/cs_user/tasks/main.yml2
-rw-r--r--test/integration/targets/cs_vpc/tasks/main.yml2
-rw-r--r--test/integration/targets/docker_secret/tasks/test_secrets.yml2
-rw-r--r--test/integration/targets/ec2_ami/tasks/main.yml2
-rw-r--r--test/integration/targets/ec2_group/tasks/main.yml4
9 files changed, 11 insertions, 11 deletions
diff --git a/test/integration/targets/aws_lambda/tasks/main.yml b/test/integration/targets/aws_lambda/tasks/main.yml
index 2fab6e9c38..26cea37268 100644
--- a/test/integration/targets/aws_lambda/tasks/main.yml
+++ b/test/integration/targets/aws_lambda/tasks/main.yml
@@ -42,7 +42,7 @@
assert:
that:
- 'result.failed'
- - 'result.msg.startswith("state is present but the following are missing: handler")'
+ - 'result.msg.startswith("state is present but all of the following are missing: handler")'
# ============================================================
- name: test with all module required variables but no region
diff --git a/test/integration/targets/cs_account/tasks/main.yml b/test/integration/targets/cs_account/tasks/main.yml
index b28c61397d..ee4cb80320 100644
--- a/test/integration/targets/cs_account/tasks/main.yml
+++ b/test/integration/targets/cs_account/tasks/main.yml
@@ -26,7 +26,7 @@
assert:
that:
- acc|failed
- - 'acc.msg == "missing required arguments: email,username,password,first_name,last_name"'
+ - 'acc.msg == "missing required arguments: email, username, password, first_name, last_name"'
- name: test create user account in check mode
cs_account:
diff --git a/test/integration/targets/cs_firewall/tasks/main.yml b/test/integration/targets/cs_firewall/tasks/main.yml
index 7da22a0d6e..1638587011 100644
--- a/test/integration/targets/cs_firewall/tasks/main.yml
+++ b/test/integration/targets/cs_firewall/tasks/main.yml
@@ -73,7 +73,7 @@
assert:
that:
- fw|failed
- - "fw.msg == 'one of the following is required: ip_address,network'"
+ - "fw.msg == 'one of the following is required: ip_address, network'"
- name: test fail if missing params
cs_firewall:
@@ -97,7 +97,7 @@
assert:
that:
- fw|failed
- - "fw.msg == 'one of the following is required: ip_address,network'"
+ - "fw.msg == 'one of the following is required: ip_address, network'"
- name: test present firewall rule ingress 80 in check mode
cs_firewall:
diff --git a/test/integration/targets/cs_host/tasks/main.yml b/test/integration/targets/cs_host/tasks/main.yml
index 2e301f6019..0c29e4b618 100644
--- a/test/integration/targets/cs_host/tasks/main.yml
+++ b/test/integration/targets/cs_host/tasks/main.yml
@@ -18,7 +18,7 @@
assert:
that:
- host|failed
- - 'host.msg == "missing required arguments: password,username,hypervisor,pod"'
+ - 'host.msg == "missing required arguments: password, username, hypervisor, pod"'
- name: test create a host in check mode
cs_host:
diff --git a/test/integration/targets/cs_user/tasks/main.yml b/test/integration/targets/cs_user/tasks/main.yml
index 16cae4519d..ef9a1a7f1c 100644
--- a/test/integration/targets/cs_user/tasks/main.yml
+++ b/test/integration/targets/cs_user/tasks/main.yml
@@ -26,7 +26,7 @@
assert:
that:
- user|failed
- - 'user.msg == "missing required arguments: account,email,password,first_name,last_name"'
+ - 'user.msg == "missing required arguments: account, email, password, first_name, last_name"'
- name: test create user in check mode
cs_user:
diff --git a/test/integration/targets/cs_vpc/tasks/main.yml b/test/integration/targets/cs_vpc/tasks/main.yml
index 560c93b661..cfc65a3e2e 100644
--- a/test/integration/targets/cs_vpc/tasks/main.yml
+++ b/test/integration/targets/cs_vpc/tasks/main.yml
@@ -31,7 +31,7 @@
assert:
that:
- vpc|failed
- - 'vpc.msg == "state is present but the following are missing: cidr"'
+ - 'vpc.msg == "state is present but all of the following are missing: cidr"'
- name: test create vpc in check mode
cs_vpc:
diff --git a/test/integration/targets/docker_secret/tasks/test_secrets.yml b/test/integration/targets/docker_secret/tasks/test_secrets.yml
index c49dafca10..603eeae87e 100644
--- a/test/integration/targets/docker_secret/tasks/test_secrets.yml
+++ b/test/integration/targets/docker_secret/tasks/test_secrets.yml
@@ -38,7 +38,7 @@
assert:
that:
- 'output.failed'
- - 'output.msg == "state is present but the following are missing: data"'
+ - 'output.msg == "state is present but all of the following are missing: data"'
- name: Create secret
docker_secret:
diff --git a/test/integration/targets/ec2_ami/tasks/main.yml b/test/integration/targets/ec2_ami/tasks/main.yml
index 68b8e2b3bd..b29750a717 100644
--- a/test/integration/targets/ec2_ami/tasks/main.yml
+++ b/test/integration/targets/ec2_ami/tasks/main.yml
@@ -158,7 +158,7 @@
assert:
that:
- "result.failed"
- - "result.msg == 'state is absent but the following are missing: image_id'"
+ - "result.msg == 'state is absent but all of the following are missing: image_id'"
# ============================================================
diff --git a/test/integration/targets/ec2_group/tasks/main.yml b/test/integration/targets/ec2_group/tasks/main.yml
index 1a94cba5a3..6ec69601a4 100644
--- a/test/integration/targets/ec2_group/tasks/main.yml
+++ b/test/integration/targets/ec2_group/tasks/main.yml
@@ -20,7 +20,7 @@
assert:
that:
- 'result.failed'
- - 'result.msg == "one of the following is required: name,group_id"'
+ - 'result.msg == "one of the following is required: name, group_id"'
# ============================================================
- name: test failure with only name
@@ -46,7 +46,7 @@
assert:
that:
- 'result.failed'
- - 'result.msg == "one of the following is required: name,group_id"'
+ - 'result.msg == "one of the following is required: name, group_id"'
# ============================================================
- name: test failure with empty description (AWS API requires non-empty string desc)