xoxys.udev/molecule/default/tests/test_default.py
Robert Kaussow 731d776356
All checks were successful
ci/woodpecker/push/lint Pipeline was successful
ci/woodpecker/push/test Pipeline was successful
ci/woodpecker/push/docs Pipeline was successful
ci/woodpecker/push/notify Pipeline was successful
ci: migrate to woodpecker
2024-02-19 08:32:40 +01:00

16 lines
354 B
Python

import os
import testinfra.utils.ansible_runner
testinfra_hosts = testinfra.utils.ansible_runner.AnsibleRunner(
os.environ["MOLECULE_INVENTORY_FILE"]
).get_hosts("all")
def test_udev_symlink(host):
device = host.file("/dev/disk/by-id/molecule")
assert device.exists
assert device.is_symlink
assert device.linked_to == "/dev/sda"