feat: test locust installation
This commit is contained in:
parent
83a1421314
commit
fc4d54410d
1 changed files with 20 additions and 0 deletions
20
tests/locust/base.py
Normal file
20
tests/locust/base.py
Normal file
|
@ -0,0 +1,20 @@
|
|||
# SPDX-FileCopyrightText: 2023 Aravinth Manivannan <realaravinth@batsense.net>
|
||||
#
|
||||
# SPDX-License-Identifier: AGPL-3.0-or-later
|
||||
|
||||
import os
|
||||
|
||||
|
||||
def test_locust_is_listening(host):
|
||||
socket = host.socket(f"tcp://0.0.0.0:8089")
|
||||
assert socket.is_listening
|
||||
|
||||
|
||||
def test_locust_config_exists(host):
|
||||
config = host.file("/etc/locust/docker-compose.yml")
|
||||
assert config.exists
|
||||
assert config.is_file
|
||||
|
||||
|
||||
def test_docker_is_installed(host):
|
||||
assert host.package("docker-compose").is_installed
|
Loading…
Reference in a new issue