Skip to content

Commit 50ab04d

Browse files
Ashutosh KSrikanteswaraRao Talluri
authored andcommitted
CLOUDSTACK-7953: Fixed time wait period for verifying snapshot policy
Signed-off-by: SrikanteswaraRao Talluri <talluri@apache.org>
1 parent 1db2d14 commit 50ab04d

1 file changed

Lines changed: 15 additions & 7 deletions

File tree

test/integration/component/test_snapshot_limits.py

Lines changed: 15 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,21 @@
1616
# under the License.
1717

1818
from nose.plugins.attrib import attr
19-
from marvin.cloudstackTestCase import *
20-
from marvin.cloudstackAPI import *
21-
from marvin.lib.utils import *
22-
from marvin.lib.base import *
23-
from marvin.lib.common import *
19+
from marvin.cloudstackTestCase import cloudstackTestCase, unittest
20+
#from marvin.cloudstackAPI import *
21+
from marvin.lib.utils import cleanup_resources
22+
from marvin.lib.base import (Account,
23+
VirtualMachine,
24+
SnapshotPolicy,
25+
ServiceOffering)
26+
from marvin.lib.common import (get_zone,
27+
get_template,
28+
get_domain,
29+
list_volumes,
30+
list_snapshots,
31+
list_snapshot_policy)
2432
from marvin.lib.utils import is_snapshot_on_nfs
25-
import os
33+
import time
2634

2735

2836
class Services:
@@ -262,7 +270,7 @@ def test_04_snapshot_limit(self):
262270
# Sleep for (maxsnaps+1) hours to verify
263271
# only maxsnaps snapshots are retained
264272
time.sleep(
265-
(self.services["recurring_snapshot"]["maxsnaps"]) * 3600
273+
(int(self.services["recurring_snapshot"]["maxsnaps"]) + 1) * 3600
266274
)
267275

268276
# Verify the snapshot was created or not

0 commit comments

Comments
 (0)