Beispiel #1
0
 def test_remove(self):
     dom_list = _fill_doms(NUM)
     # random pick
     doms.remove(dom_list[2].uuid)
     for dom in doms.get_all():  # FIXME: better avoid this.
         self.assertNotEquals(dom.UUIDString(),
                              dom_list[2].uuid)
Beispiel #2
0
 def test_remove(self):
     dom_list = _fill_doms(NUM)
     # random pick
     doms.remove(dom_list[2].uuid)
     for dom in doms.get_all():  # FIXME: better avoid this.
         self.assertNotEquals(dom.UUIDString(),
                              dom_list[2].uuid)
Beispiel #3
0
    def test_destroy_unregistered_forcefully(self):
        with conttestlib.tmp_run_dir():
            dom = domain.Domain.create(
                conttestlib.minimal_dom_xml()
            )

        doms.remove(dom.UUIDString())
        self.assertRaises(libvirt.libvirtError, dom.destroy)
Beispiel #4
0
    def test_destroy_unregistered_forcefully(self):
        with conttestlib.tmp_run_dir():
            dom = domain.Domain.create(
                conttestlib.minimal_dom_xml()
            )

        doms.remove(dom.UUIDString())
        self.assertRaises(libvirt.libvirtError, dom.destroy)