homeserver/roles/gantsign.ctop/molecule/default/tests/test_role.py
mg ec33333916 ctop (#139)
rolle einzeln

submodule entfernt

Co-authored-by: Michael Grote <michael.grote@posteo.de>
Reviewed-on: mg/ansible#139
Co-Authored-By: mg <mg@noreply.git.mgrote.net>
Co-Committed-By: mg <mg@noreply.git.mgrote.net>
2021-06-29 21:43:09 +02:00

23 lines
555 B
Python

import re
def test_dir(host):
dir = host.file('/usr/local/bin')
assert dir.exists
assert dir.is_directory
assert dir.user == 'root'
assert dir.group == 'root'
def test_file(host):
installed_file = host.file('/usr/local/bin/ctop')
assert installed_file.exists
assert installed_file.is_file
assert installed_file.user == 'root'
assert installed_file.group == 'root'
def test_version(host):
version = host.check_output('ctop -v')
pattern = 'ctop version [0-9\\.]+'
assert re.search(pattern, version)