Ejemplo n.º 1
0
 def test_VM_set_tag_regularVM_regularVIF_regularValue_sameOVS(self):
     vif_ref = BNVMAPI_Util.get_first_VIF(self.vm_with_vdi)
     value = 1
     ovs = BNVMAPI_Util.get_VIF_ovs_bridge(vif_ref)
     self.assertEqual("Success", self.vmapi._VM_set_tag(self.session, self.vm_with_vdi, vif_ref, value, ovs).get('Status'))
Ejemplo n.º 2
0
 def test_VM_set_tag_regularVM_regularVIF_regularValue_negativeOVS(self):
     vif_ref = BNVMAPI_Util.get_first_VIF(self.vm_with_vdi)
     value = 1
     ovs = "NEGATIVE_OVS"
     self.assertEqual("Failure", self.vmapi._VM_set_tag(self.session, self.vm_with_vdi, vif_ref, value, ovs).get('Status'))
Ejemplo n.º 3
0
 def test_VM_set_tag_regularVM_regularVIF_negativeValue_regularOVS(self):
     vif_ref = BNVMAPI_Util.get_first_VIF(self.vm_with_vdi)
     value = "a"
     ovs = "ovs0"
     self.assertRaises(Exception, self.vmapi._VM_set_tag, self.session, self.vm_with_vdi, vif_ref, value, ovs)
Ejemplo n.º 4
0
 def test_VM_set_tag_regularVM_negativeVIF_regularValue_regularOVS(self):
     vif_ref = BNVMAPI_Util.get_negative_VIF()
     value = 1
     ovs = "ovs0"
     self.assertEqual("Failure", self.vmapi._VM_set_tag(self.session, self.vm_with_vdi, vif_ref, value, ovs).get('Status'))
Ejemplo n.º 5
0
 def setUp(self):
     self.vm_with_vdi = BNVMAPI_Util.create_bootable_VM_with_VDI()
     self.vmapi = BNVMAPI_Util.VMAPI
     self.session = BNVMAPI_Util.login_session()
Ejemplo n.º 6
0
 def tearDown(self):
     BNVMAPI_Util.destroy_VM_and_VDI(self.vm_with_vdi)