summaryrefslogtreecommitdiff
path: root/test/integration/targets/dellos10_command/tests/cli/invalid.yaml
diff options
context:
space:
mode:
Diffstat (limited to 'test/integration/targets/dellos10_command/tests/cli/invalid.yaml')
-rw-r--r--test/integration/targets/dellos10_command/tests/cli/invalid.yaml28
1 files changed, 28 insertions, 0 deletions
diff --git a/test/integration/targets/dellos10_command/tests/cli/invalid.yaml b/test/integration/targets/dellos10_command/tests/cli/invalid.yaml
new file mode 100644
index 0000000000..14b24b4cbc
--- /dev/null
+++ b/test/integration/targets/dellos10_command/tests/cli/invalid.yaml
@@ -0,0 +1,28 @@
+---
+- debug: msg="START cli/invalid.yaml"
+
+- name: run invalid command
+ dellos10_command:
+ commands: ['show foo']
+ provider: "{{ cli }}"
+ register: result
+ ignore_errors: yes
+
+- assert:
+ that:
+ - "'Error: Unrecognized command' in result.stdout"
+
+- name: run commands that include invalid command
+ dellos10_command:
+ commands:
+ - show version
+ - show foo
+ provider: "{{ cli }}"
+ register: result
+ ignore_errors: yes
+
+- assert:
+ that:
+ - "'Error: Unrecognized command' in result.stdout"
+
+- debug: msg="END cli/invalid.yaml"