Revision a8dbf746 qa/qa_rapi.py

b/qa/qa_rapi.py
683 683
@InstanceCheck(INST_UP, INST_UP, FIRST_ARG)
684 684
def TestRapiInstanceModify(instance):
685 685
  """Test modifying instance via RAPI"""
686
  default_hv = qa_config.GetDefaultHypervisor()
687

  
686 688
  def _ModifyInstance(**kwargs):
687 689
    _WaitForRapiJob(_rapi_client.ModifyInstance(instance["name"], **kwargs))
688 690

  
689
  _ModifyInstance(hvparams={
690
    constants.HV_KERNEL_ARGS: "single",
691
    })
692

  
693 691
  _ModifyInstance(beparams={
694 692
    constants.BE_VCPUS: 3,
695 693
    })
......
698 696
    constants.BE_VCPUS: constants.VALUE_DEFAULT,
699 697
    })
700 698

  
701
  _ModifyInstance(hvparams={
702
    constants.HV_KERNEL_ARGS: constants.VALUE_DEFAULT,
703
    })
699
  if default_hv == constants.HT_XEN_PVM:
700
    _ModifyInstance(hvparams={
701
      constants.HV_KERNEL_ARGS: "single",
702
      })
703
    _ModifyInstance(hvparams={
704
      constants.HV_KERNEL_ARGS: constants.VALUE_DEFAULT,
705
      })
706
  elif default_hv == constants.HT_XEN_HVM:
707
    _ModifyInstance(hvparams={
708
      constants.HV_BOOT_ORDER: "acn",
709
      })
710
    _ModifyInstance(hvparams={
711
      constants.HV_BOOT_ORDER: constants.VALUE_DEFAULT,
712
      })
704 713

  
705 714

  
706 715
@InstanceCheck(INST_UP, INST_UP, FIRST_ARG)

Also available in: Unified diff