Commit 76f59a32 authored by Michael Hanselmann's avatar Michael Hanselmann

Forward-port: Fix two problems in QA scripts

- Failover back to original node in instance failure test
- Exclude secondary node from list of potential nodes in
  replace-disks test

Reviewed-by: iustinp
parent 8a4e8898
......@@ -211,7 +211,7 @@ def RunHardwareFailureTests(instance, pnode, snode):
RunTest(qa_instance.TestInstanceFailover, instance)
if qa_config.TestEnabled('instance-replace-disks'):
othernode = qa_config.AcquireNode(exclude=pnode)
othernode = qa_config.AcquireNode(exclude=[pnode, snode])
try:
RunTest(qa_instance.TestReplaceDisks,
instance, pnode, snode, othernode)
......
......@@ -142,6 +142,11 @@ def TestInstanceFailover(instance):
AssertEqual(StartSSH(master['primary'],
utils.ShellQuoteArgs(cmd)).wait(), 0)
# ... and back
cmd = ['gnt-instance', 'failover', '--force', instance['name']]
AssertEqual(StartSSH(master['primary'],
utils.ShellQuoteArgs(cmd)).wait(), 0)
@qa_utils.DefineHook('instance-info')
def TestInstanceInfo(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