

def test_delete_destroy_error(self):
    'Domain destroy raises error.'
    domain = mock.Mock()
    logger = mock.Mock()
    domain.isActive.return_value = True
    domain.destroy.side_effect = libvirt.libvirtError('BOOM')
    qemu.domain_delete(domain, logger)
    self.assertTrue(logger.undefineFlags.called)

dataset/ETHPy150Open F-Secure/see/see/context/resources/test/qemu_test.py DomainDeleteTest.test_delete_destroy_error/VarMisuse@62/84 `domain`->`logger`