Skip to content

Commit 2ddde43

Browse files
committed
Remove redundant cinder tests
1 parent 3af8d41 commit 2ddde43

File tree

1 file changed

+0
-40
lines changed
  • zaza/openstack/charm_tests/cinder

1 file changed

+0
-40
lines changed

zaza/openstack/charm_tests/cinder/tests.py

-40
Original file line numberDiff line numberDiff line change
@@ -305,46 +305,6 @@ def verify(stdin, stdout, stderr):
305305
'lsblk -sn -o SIZE /dev/vdb',
306306
privkey=privkey, verify=verify)
307307

308-
def test_300_apipaste_includes_audit_section(self):
309-
"""Test api-paste.ini renders audit section when enabled."""
310-
service_name = 'cinder'
311-
api_paste_ini_path = f"/etc/{service_name}/api-paste.ini"
312-
expected_content = [
313-
"[filter:audit]",
314-
"paste.filter_factory = keystonemiddleware.audit:filter_factory",
315-
f"audit_map_file = /etc/{service_name}/api_audit_map.conf",
316-
f"service_name = {service_name}"
317-
]
318-
319-
set_default = {'audit-middleware': False}
320-
set_alternate = {'audit-middleware': True}
321-
322-
with self.config_change(set_default, set_alternate):
323-
try:
324-
api_paste_content = zaza.model.file_contents(
325-
self.lead_unit,
326-
api_paste_ini_path,
327-
)
328-
except Exception as e:
329-
self.fail("Error fetching api-paste.ini: {}".format(str(e)))
330-
for line in expected_content:
331-
self.assertIn(line, api_paste_content)
332-
333-
def test_301_apipaste_excludes_audit_section(self):
334-
"""Test api_paste.ini does not render audit section when disabled."""
335-
service_name = 'cinder'
336-
section_heading = '[filter:audit]'
337-
api_paste_ini_path = f"/etc/{service_name}/api-paste.ini"
338-
339-
try:
340-
api_paste_content = zaza.model.file_contents(
341-
self.lead_unit,
342-
api_paste_ini_path
343-
)
344-
except Exception as e:
345-
self.fail("Error fetching api-paste.ini: {}".format(str(e)))
346-
self.assertNotIn(section_heading, api_paste_content)
347-
348308
@property
349309
def services(self):
350310
"""Return a list services for the selected OpenStack release."""

0 commit comments

Comments
 (0)