Commit 6a343475 authored by Michael Hanselmann's avatar Michael Hanselmann
Browse files

QA: Test ssconf_instance_list file on rename and creation

This test would've caught the bug fixed in the previous patch.
Signed-off-by: default avatarMichael Hanselmann <>
Reviewed-by: default avatarRené Nussbaumer <>
parent 1fc34c48
......@@ -33,7 +33,7 @@ import qa_config
import qa_utils
import qa_error
from qa_utils import AssertEqual, AssertNotEqual, StartSSH
from qa_utils import AssertEqual, AssertNotEqual, AssertIn, StartSSH
def _GetDiskStatePath(disk):
......@@ -61,6 +61,9 @@ def _DiskTest(node, disk_template):
utils.ShellQuoteArgs(cmd)).wait(), 0)
return instance
......@@ -129,6 +132,30 @@ def TestInstanceReinstall(instance):
utils.ShellQuoteArgs(cmd)).wait(), 0)
def _ReadSsconfInstanceList():
"""Reads ssconf_instance_list from the master node.
master = qa_config.GetMasterNode()
cmd = ["cat", utils.PathJoin(constants.DATA_DIR,
"ssconf_%s" % constants.SS_INSTANCE_LIST)]
return qa_utils.GetCommandOutput(master["primary"],
def _CheckSsconfInstanceList(instance):
"""Checks if a certain instance is in the ssconf instance list.
@type instance: string
@param instance: Instance name
def TestInstanceRename(instance, rename_target):
"""gnt-instance rename"""
master = qa_config.GetMasterNode()
......@@ -137,9 +164,11 @@ def TestInstanceRename(instance, rename_target):
for name1, name2 in [(rename_source, rename_target),
(rename_target, rename_source)]:
cmd = ['gnt-instance', 'rename', name1, name2]
utils.ShellQuoteArgs(cmd)).wait(), 0)
def TestInstanceFailover(instance):
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment