You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by gi...@apache.org on 2013/11/21 06:46:20 UTC

git commit: updated refs/heads/master to 138cee4

Updated Branches:
  refs/heads/master db2ea0a16 -> 138cee401


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/138cee40
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/138cee40
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/138cee40

Branch: refs/heads/master
Commit: 138cee401ff6973a43302da2ba323b7e85321a19
Parents: db2ea0a
Author: Gaurav Aradhye <ga...@clogeny.com>
Authored: Thu Nov 21 11:15:32 2013 +0530
Committer: Girish Shilamkar <gi...@clogeny.com>
Committed: Thu Nov 21 11:15:32 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/138cee40/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)