From 286b73359bc49b14224c8ef7bfc4e48737640c1f Mon Sep 17 00:00:00 2001 From: Iustin Pop <iustin@google.com> Date: Wed, 18 Jul 2012 13:07:08 +0200 Subject: [PATCH] Add a simple QA test for gnt-node list-drbd This will be run only if 'haskell-confd' QA configuration has been enabled. Signed-off-by: Iustin Pop <iustin@google.com> Reviewed-by: Agata Murawska <agatamurawska@google.com> --- qa/ganeti-qa.py | 2 ++ qa/qa-sample.json | 2 ++ qa/qa_node.py | 7 ++++++- 3 files changed, 10 insertions(+), 1 deletion(-) diff --git a/qa/ganeti-qa.py b/qa/ganeti-qa.py index aa52d00d8..94518128d 100755 --- a/qa/ganeti-qa.py +++ b/qa/ganeti-qa.py @@ -490,6 +490,8 @@ def RunQa(): snode = qa_config.AcquireNode(exclude=pnode) try: instance = RunTest(func, pnode, snode) + RunTestIf("haskell-confd", qa_node.TestNodeListDrbd, pnode) + RunTestIf("haskell-confd", qa_node.TestNodeListDrbd, snode) RunCommonInstanceTests(instance) RunGroupListTests() RunTest(qa_group.TestAssignNodesIncludingSplit, diff --git a/qa/qa-sample.json b/qa/qa-sample.json index 158de2924..dc033acc3 100644 --- a/qa/qa-sample.json +++ b/qa/qa-sample.json @@ -95,6 +95,8 @@ "cluster-redist-conf": true, "cluster-repair-disk-sizes": true, + "haskell-confd": true, + "group-list": true, "group-rwops": true, diff --git a/qa/qa_node.py b/qa/qa_node.py index 9f75f7d1e..647af1907 100644 --- a/qa/qa_node.py +++ b/qa/qa_node.py @@ -1,7 +1,7 @@ # # -# Copyright (C) 2007, 2011 Google Inc. +# Copyright (C) 2007, 2011, 2012 Google Inc. # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -417,3 +417,8 @@ def TestNodeList(): def TestNodeListFields(): """gnt-node list-fields""" qa_utils.GenericQueryFieldsTest("gnt-node", query.NODE_FIELDS.keys()) + + +def TestNodeListDrbd(node): + """gnt-node list-drbd""" + AssertCommand(["gnt-node", "list-drbd", node["primary"]]) -- GitLab