[Kimchi-devel] [PATCH 2/5] Adding test case for updating flags

Aline Manera alinefm at linux.vnet.ibm.com
Mon Jun 9 21:17:12 UTC 2014


Reviewed-by: Aline Manera <alinefm at linux.vnet.ibm.com>

On 06/03/2014 04:20 AM, lvroyce at linux.vnet.ibm.com wrote:
> From: Royce Lv <lvroyce at linux.vnet.ibm.com>
>
> Add test case for flags change to make sure it works
> after vm powered off.
>
> Signed-off-by: Royce Lv <lvroyce at linux.vnet.ibm.com>
> ---
>   tests/test_model.py | 5 +++++
>   1 file changed, 5 insertions(+)
>
> diff --git a/tests/test_model.py b/tests/test_model.py
> index e3dff95..b78b52e 100644
> --- a/tests/test_model.py
> +++ b/tests/test_model.py
> @@ -247,9 +247,14 @@ class ModelTests(unittest.TestCase):
>               # Hot plug a disk
>               inst.vm_start(vm_name)
>               disk = _attach_disk()
> +            # VM disk still there after powered off
> +            inst.vm_poweroff(vm_name)
> +            disk_info = inst.vmstorage_lookup(vm_name, disk)
> +            self.assertEquals(u'disk', disk_info['type'])
>               inst.vmstorage_delete(vm_name, disk)
>
>               # Hot plug 'ide' bus disk does not work
> +            inst.vm_start(vm_name)
>               self.assertRaises(InvalidOperation, _attach_disk, 'ide')
>               inst.vm_poweroff(vm_name)
>




More information about the Kimchi-devel mailing list