From d30fe15d29a19733c796f6778ed135ee2ce28755 Mon Sep 17 00:00:00 2001 From: Prasanna Santhanam Date: Wed, 2 Oct 2013 20:17:40 +0530 Subject: [PATCH] marvin_refactor: setup/teardown per test for the vpc lifecycle test Signed-off-by: Prasanna Santhanam --- .../marvin/marvin/test/test_vpc_life_cycle.py | 20 +++++++++---------- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/tools/marvin/marvin/test/test_vpc_life_cycle.py b/tools/marvin/marvin/test/test_vpc_life_cycle.py index d2476731b4f..8dbc79723ef 100644 --- a/tools/marvin/marvin/test/test_vpc_life_cycle.py +++ b/tools/marvin/marvin/test/test_vpc_life_cycle.py @@ -25,14 +25,13 @@ from nose.plugins.attrib import attr class TestVpcLifeCycle(cloudstackTestCase): - @classmethod - def setUpClass(cls): - cls.apiclient = super(TestVpcLifeCycle, cls).getClsTestClient().getApiClient() - cls.zoneid = get_zone(cls.apiclient).id - cls.templateid = get_template(cls.apiclient).id, - cls.serviceofferingid = get_service_offering(cls.apiclient).id, - cls.account = UserAccount( - apiclient=cls.apiclient + def setUp(self): + self.apiclient = super(TestVpcLifeCycle, self).getClsTestClient().getApiClient() + self.zoneid = get_zone(self.apiclient).id + self.templateid = get_template(self.apiclient).id + self.serviceofferingid = get_service_offering(self.apiclient).id + self.account = UserAccount( + apiclient=self.apiclient ) @attr(tags='debug') @@ -96,6 +95,5 @@ class TestVpcLifeCycle(cloudstackTestCase): vm.destroy() vm.state | should | equal_to('Destroyed') - @classmethod - def tearDownClass(cls): - cls.account.delete() \ No newline at end of file + def tearDown(self): + self.account.delete() \ No newline at end of file