|
40 | 40 |
|
41 | 41 |
|
42 | 42 | class TestParsers(unittest.TestCase): |
43 | | - def __init__(self, *args, **kwargs): |
44 | | - super(TestParsers, self).__init__(*args, **kwargs) |
| 43 | + def setUp(self): |
45 | 44 | self.json_file = POLICY_SPEC_JSON |
46 | 45 | self.yaml_file = POLICY_SPEC_YAML |
47 | 46 |
|
@@ -98,13 +97,12 @@ def _assert_policy_spec(self, ps): |
98 | 97 |
|
99 | 98 |
|
100 | 99 | class TestTPPPolicyManagement(unittest.TestCase): |
101 | | - def __init__(self, *args, **kwargs): |
| 100 | + def setUp(self): |
102 | 101 | self.tpp_conn = TPPTokenConnection(url=TPP_TOKEN_URL, http_request_kwargs={'verify': "/tmp/chain.pem"}) |
103 | 102 | auth = Authentication(user=TPP_USER, password=TPP_PASSWORD, scope=SCOPE_PM) |
104 | 103 | self.tpp_conn.get_access_token(auth) |
105 | 104 | self.json_file = POLICY_SPEC_JSON |
106 | 105 | self.yaml_file = POLICY_SPEC_YAML |
107 | | - super(TestTPPPolicyManagement, self).__init__(*args, **kwargs) |
108 | 106 |
|
109 | 107 | prefixed_universal = None |
110 | 108 | username = "osstestuser" |
@@ -166,11 +164,10 @@ def _create_policy_tpp(self, policy_spec=None, policy=None, defaults=None): |
166 | 164 |
|
167 | 165 |
|
168 | 166 | class TestVaaSPolicyManagement(unittest.TestCase): |
169 | | - def __init__(self, *args, **kwargs): |
| 167 | + def setUp(self): |
170 | 168 | self.cloud_conn = CloudConnection(token=CLOUD_APIKEY, url=CLOUD_URL) |
171 | 169 | self.json_file = POLICY_SPEC_JSON |
172 | 170 | self.yaml_file = POLICY_SPEC_YAML |
173 | | - super(TestVaaSPolicyManagement, self).__init__(*args, **kwargs) |
174 | 171 |
|
175 | 172 | def test_create_policy_from_json(self): |
176 | 173 | # ps = json_parser.parse_file(self.json_file) |
|
0 commit comments