Updated Branches: refs/heads/4.2 fbe529368 -> 2f308cc98
CLOUDSTACK-5201: Correcting code related to schedule of recurring snapshot policy Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/2f308cc9 Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/2f308cc9 Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/2f308cc9 Branch: refs/heads/4.2 Commit: 2f308cc988bb3c82c753d99daade5f6bfafd26e5 Parents: fbe5293 Author: Gaurav Aradhye <[email protected]> Authored: Thu Nov 21 11:15:32 2013 +0530 Committer: Girish Shilamkar <[email protected]> Committed: Thu Nov 21 11:17:42 2013 +0530 ---------------------------------------------------------------------- test/integration/component/test_base_image_updation.py | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cloudstack/blob/2f308cc9/test/integration/component/test_base_image_updation.py ---------------------------------------------------------------------- diff --git a/test/integration/component/test_base_image_updation.py b/test/integration/component/test_base_image_updation.py index b70bea5..762016f 100644 --- a/test/integration/component/test_base_image_updation.py +++ b/test/integration/component/test_base_image_updation.py @@ -534,14 +534,8 @@ class TestBaseImageUpdate(cloudstackTestCase): vm_with_reset.rootdeviceid ) - now = datetime.now() - delta = timedelta(minutes=15) - scheduled_time = now + delta - - self.services["recurring_snapshot"]["schedule"] = scheduled_time.minute - self.debug("Creating recurring snapshot policy for root disk on vm created with IsVolatile=True") - self.debug("Snapshot Policy - Type : %s Scheduled minute : %s" %( + self.debug("Snapshot Policy - Type : %s Scheduled Hours : %s" %( self.services["recurring_snapshot"]["intervaltype"], self.services["recurring_snapshot"]["schedule"])) @@ -575,7 +569,7 @@ class TestBaseImageUpdate(cloudstackTestCase): self.services["recurring_snapshot"]["maxsnaps"], "Check interval type in list resources call" ) - sleep_seconds = delta.seconds + 600 + sleep_seconds = (self.services["recurring_snapshot"]["schedule"]) * 3600 + 600 sleep_minutes = sleep_seconds/60 self.debug("Sleeping for %s minutes till the volume is snapshoted" %sleep_minutes) time.sleep(sleep_seconds)
