Apply format

This commit is contained in:
Manuel Gutierrez 2020-10-26 19:27:03 +01:00
parent b79f3c6213
commit b679c7d185
No known key found for this signature in database
GPG Key ID: CEB8789DAED15AAD

View File

@ -30,7 +30,9 @@ def test_wazuh_services_are_running(host):
# api = host.service("wazuh-api") # api = host.service("wazuh-api")
# assert manager.is_running # assert manager.is_running
# assert api.is_running # assert api.is_running
output = host.check_output('ps aux | grep ossec | tr -s " " | cut -d" " -f11') output = host.check_output(
'ps aux | grep ossec | tr -s " " | cut -d" " -f11'
)
assert 'ossec-authd' in output assert 'ossec-authd' in output
assert 'wazuh-modulesd' in output assert 'wazuh-modulesd' in output
assert 'wazuh-db' in output assert 'wazuh-db' in output
@ -48,7 +50,6 @@ def test_wazuh_services_are_running(host):
("/var/ossec/etc/rules/local_rules.xml", "ossec", "ossec", 0o640), ("/var/ossec/etc/rules/local_rules.xml", "ossec", "ossec", 0o640),
("/var/ossec/etc/lists/audit-keys", "ossec", "ossec", 0o660), ("/var/ossec/etc/lists/audit-keys", "ossec", "ossec", 0o660),
]) ])
def test_wazuh_files(host, wazuh_file, wazuh_owner, wazuh_group, wazuh_mode): def test_wazuh_files(host, wazuh_file, wazuh_owner, wazuh_group, wazuh_mode):
"""Test Wazuh related files exist and have proper owners and mode.""" """Test Wazuh related files exist and have proper owners and mode."""
wazuh_file_host = host.file(wazuh_file) wazuh_file_host = host.file(wazuh_file)
@ -56,6 +57,7 @@ def test_wazuh_files(host, wazuh_file, wazuh_owner, wazuh_group, wazuh_mode):
assert wazuh_file_host.group == wazuh_group assert wazuh_file_host.group == wazuh_group
assert wazuh_file_host.mode == wazuh_mode assert wazuh_file_host.mode == wazuh_mode
def test_filebeat_is_installed(host): def test_filebeat_is_installed(host):
"""Test the elasticsearch package is installed.""" """Test the elasticsearch package is installed."""
filebeat = host.package("filebeat") filebeat = host.package("filebeat")