From e4e9b745e1e0d0e028650b8426185f667ab0562d Mon Sep 17 00:00:00 2001 From: Girish Shilamkar Date: Fri, 25 Jul 2014 19:58:40 +0530 Subject: [PATCH] Fixing resize volume test case --- test/integration/smoke/test_volumes.py | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/test/integration/smoke/test_volumes.py b/test/integration/smoke/test_volumes.py index 7fbcc21647e..6e9ea759085 100644 --- a/test/integration/smoke/test_volumes.py +++ b/test/integration/smoke/test_volumes.py @@ -560,16 +560,8 @@ class TestVolumes(cloudstackTestCase): cmd.id = rootvolume.id cmd.diskofferingid = self.services['diskofferingid'] - success = False - try: + with self.assertRaises(Exception): self.apiClient.resizeVolume(cmd) - except Exception as ex: - if "Can only resize Data volumes" in str(ex): - success = True - self.assertEqual( - success, - True, - "ResizeVolume - verify root disks cannot be resized by disk offering id") # Ok, now let's try and resize a volume that is not custom. cmd.id = self.volume.id