adapted testinfra tests for the worker
This commit is contained in:
parent
38d954aeaa
commit
3249fd86ed
2
Pipfile
2
Pipfile
@ -20,6 +20,8 @@ agent ="molecule test -s wazuh-agent --destroy=never"
|
|||||||
elasticsearch ="molecule test -s elasticsearch --destroy=never"
|
elasticsearch ="molecule test -s elasticsearch --destroy=never"
|
||||||
kibana ="molecule test -s kibana --destroy=never"
|
kibana ="molecule test -s kibana --destroy=never"
|
||||||
|
|
||||||
|
verify_worker ="molecule verify -s worker"
|
||||||
|
|
||||||
# Destroy all the existing containers ' Molecule instances '
|
# Destroy all the existing containers ' Molecule instances '
|
||||||
destroy_elasticsearch ="molecule destroy -s elasticsearch"
|
destroy_elasticsearch ="molecule destroy -s elasticsearch"
|
||||||
destroy_worker ="molecule destroy -s worker"
|
destroy_worker ="molecule destroy -s worker"
|
||||||
|
|||||||
@ -73,10 +73,10 @@ def test_open_ports(host):
|
|||||||
"""Test if the main port is open and the agent-auth is not open."""
|
"""Test if the main port is open and the agent-auth is not open."""
|
||||||
distribution = host.system_info.distribution.lower()
|
distribution = host.system_info.distribution.lower()
|
||||||
if distribution == 'ubuntu':
|
if distribution == 'ubuntu':
|
||||||
assert host.socket("tcp://0.0.0.0:1515").is_listening
|
assert host.socket("tcp://0.0.0.0:1516").is_listening
|
||||||
assert host.socket("tcp://0.0.0.0:1514").is_listening
|
assert host.socket("tcp://0.0.0.0:1514").is_listening
|
||||||
elif distribution == 'centos':
|
elif distribution == 'centos':
|
||||||
assert host.socket("tcp://127.0.0.1:1515").is_listening
|
assert host.socket("tcp://127.0.0.1:1516").is_listening
|
||||||
assert host.socket("tcp://127.0.0.1:1514").is_listening
|
assert host.socket("tcp://127.0.0.1:1514").is_listening
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user