From 9df6d173d81f9693f4953a97ad9a9d8b80dfe671 Mon Sep 17 00:00:00 2001
From: Michael Hanselmann <hansmi@google.com>
Date: Fri, 31 Aug 2007 15:36:47 +0000
Subject: [PATCH] =?UTF-8?q?Test=20=E2=80=9Cgnt-node=20volumes=E2=80=9D.?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Reviewed-by: iustinp
---
 testing/ganeti.qa.py   | 17 ++++++++++++++++-
 testing/qa-sample.yaml |  1 +
 2 files changed, 17 insertions(+), 1 deletion(-)

diff --git a/testing/ganeti.qa.py b/testing/ganeti.qa.py
index cb45f2fa0..f202e9f4b 100755
--- a/testing/ganeti.qa.py
+++ b/testing/ganeti.qa.py
@@ -441,6 +441,13 @@ def TestNodeInfo():
   cmd = ['gnt-node', 'info']
   AssertEqual(StartSSH(GetMasterNode()['primary'],
                        utils.ShellQuoteArgs(cmd)).wait(), 0)
+
+
+def TestNodeVolumes():
+  """gnt-node volumes"""
+  cmd = ['gnt-node', 'volumes']
+  AssertEqual(StartSSH(GetMasterNode()['primary'],
+                       utils.ShellQuoteArgs(cmd)).wait(), 0)
 # }}}
 
 # {{{ Instance tests
@@ -651,7 +658,6 @@ def TestUploadKnownHostsFile(localpath):
     AssertEqual(StartSSH(master['primary'],
                          utils.ShellQuoteArgs(cmd)).wait(), 0)
     raise
-
 # }}}
 
 # {{{ Main program
@@ -732,6 +738,9 @@ if __name__ == '__main__':
       if TestEnabled('instance-consecutive-failures'):
         RunTest(TestInstanceConsecutiveFailures, node, instance)
 
+      if TestEnabled('node-volumes'):
+        RunTest(TestNodeVolumes)
+
       RunTest(TestInstanceRemove, instance)
       del instance
 
@@ -743,6 +752,9 @@ if __name__ == '__main__':
       if TestEnabled('instance-info'):
         RunTest(TestInstanceInfo, instance)
 
+      if TestEnabled('node-volumes'):
+        RunTest(TestNodeVolumes)
+
       RunTest(TestInstanceRemove, instance)
       del instance
 
@@ -759,6 +771,9 @@ if __name__ == '__main__':
         if TestEnabled('instance-failover'):
           RunTest(TestInstanceFailover, instance)
 
+        if TestEnabled('node-volumes'):
+          RunTest(TestNodeVolumes)
+
         RunTest(TestInstanceRemove, instance)
         del instance
       finally:
diff --git a/testing/qa-sample.yaml b/testing/qa-sample.yaml
index 53ab4260d..4a7f9ba94 100644
--- a/testing/qa-sample.yaml
+++ b/testing/qa-sample.yaml
@@ -34,6 +34,7 @@ tests:
   cluster-destroy: True
 
   node-info: True
+  node-volumes: True
 
   instance-add-plain-disk: True
   instance-add-local-mirror-disk: True
-- 
GitLab