This patch adds testcases of virsh domname to subtest.cfg.sample.

Signed-off-by: Yu Mingfei <[email protected]>
---
  client/virt/subtests.cfg.sample |   44 +++++++++++++++++++++++++++++++++++++++
  1 files changed, 44 insertions(+), 0 deletions(-)

diff --git a/client/virt/subtests.cfg.sample b/client/virt/subtests.cfg.sample
index 099f28e..6e2498a 100644
--- a/client/virt/subtests.cfg.sample
+++ b/client/virt/subtests.cfg.sample
@@ -307,6 +307,50 @@ variants:
                  libvirtd = "off"
                  status_error = "yes"

+    - virsh_domname:
+        type = virsh_domname
+        variants:
+            - with_valid_option:
+                status_error = "no"
+                variants:
+                    - domid:
+                        options_ref = "id"
+                    - uuid:
+                        options_ref = "uuid"
+            - with_invalid_option:
+                status_error = "yes"
+                variants:
+                    - none:
+                        options_ref = ""
+                    - hex_domid:
+                        options_ref = "hex_id"
+                    - invalid_domid:
+                        options_ref = "invalid_id"
+                        invalid_id = "9999"
+                    - invalid_uuid:
+                        options_ref = "invalid_uuid"
+                        invalid_uuid = "99999999-9999-9999-9999-999999999999"
+                    - addition_invalid_param:
+                        options_ref = "invalid_param"
+                    - vm_name:
+                        options_ref = "name"
+        variants:
+            - vm_state:
+                variants:
+                    - vm_running:
+                        addition_status_error = "no"
+                        pre_vm_state = "running"
+                    - vm_paused:
+                        addition_status_error = "no"
+                        pre_vm_state = "paused"
+                    - vm_shut_off:
+                        addition_status_error = "yes"
+                        pre_vm_state = "shut off"
+            - with_libvirtd_stop:
+                only with_valid_option
+                addition_status_error = "yes"
+                libvirtd = "off"
+
      - module_probe:
          type = module_probe
          # You can specify your own module list, though it is not needed 
usually.
-- 
1.7.1



-- 
Best Regards
Yu Mingfei

_______________________________________________
Autotest mailing list
[email protected]
http://test.kernel.org/cgi-bin/mailman/listinfo/autotest

Reply via email to