forked from TrueCloudLab/frostfs-testlib
add_wait_for_service_to_be_in_state
This commit is contained in:
parent
14c85e0a9e
commit
917dc6f6d8
2 changed files with 17 additions and 0 deletions
|
@ -135,6 +135,10 @@ class DockerHost(Host):
|
||||||
timeout=service_attributes.start_timeout,
|
timeout=service_attributes.start_timeout,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
def wait_for_service_to_be_in_state(self, systemd_service_name: str, expected_state: str, timeout: int) -> None:
|
||||||
|
raise NotImplementedError("Not implemented for docker")
|
||||||
|
|
||||||
|
|
||||||
def get_data_directory(self, service_name: str) -> str:
|
def get_data_directory(self, service_name: str) -> str:
|
||||||
service_attributes = self._get_service_attributes(service_name)
|
service_attributes = self._get_service_attributes(service_name)
|
||||||
return service_attributes.data_directory_path
|
return service_attributes.data_directory_path
|
||||||
|
|
|
@ -266,3 +266,16 @@ class Host(ABC):
|
||||||
True if message found in logs in the given time frame.
|
True if message found in logs in the given time frame.
|
||||||
False otherwise.
|
False otherwise.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
|
|
||||||
|
@abstractmethod
|
||||||
|
def wait_for_service_to_be_in_state(self, systemd_service_name: str, expected_state: str, timeout: int) -> None:
|
||||||
|
"""
|
||||||
|
Waites for service to be in specified state.
|
||||||
|
|
||||||
|
Args:
|
||||||
|
systemd_service_name: Service to wait state of.
|
||||||
|
expected_state: State to wait for
|
||||||
|
timeout: Seconds to wait
|
||||||
|
|
||||||
|
"""
|
||||||
|
|
Loading…
Reference in a new issue