Revision 55cec070 test/py/ganeti.rapi.client_unittest.py

b/test/py/ganeti.rapi.client_unittest.py
594 594
  def testRebootInstance(self):
595 595
    self.rapi.AddResponse("6146")
596 596
    job_id = self.client.RebootInstance("i-bar", reboot_type="hard",
597
                                        ignore_secondaries=True, dry_run=True)
597
                                        ignore_secondaries=True, dry_run=True,
598
                                        reason="Updates")
598 599
    self.assertEqual(6146, job_id)
599 600
    self.assertHandler(rlib2.R_2_instances_name_reboot)
600 601
    self.assertItems(["i-bar"])
601 602
    self.assertDryRun()
602 603
    self.assertQuery("type", ["hard"])
603 604
    self.assertQuery("ignore_secondaries", ["1"])
605
    self.assertQuery("reason", ["Updates"])
604 606

  
605 607
  def testRebootInstanceDefaultReason(self):
606 608
    self.rapi.AddResponse("6146")
......
612 614
    self.assertDryRun()
613 615
    self.assertQuery("type", ["hard"])
614 616
    self.assertQuery("ignore_secondaries", ["1"])
617
    self.assertQuery("reason", None)
615 618

  
616 619
  def testShutdownInstance(self):
617 620
    self.rapi.AddResponse("1487")

Also available in: Unified diff