Browse Source

Merge branch 'wip-cloud' into 'master'

cloud: libvirt does not support external devices

See merge request main/infrastructure!401
keep-around/20decfe56fea28fb1dceb04c91ef4b61ada708ec
Loïc Dachary 7 months ago
parent
commit
20decfe56f
  1. 17
      playbooks/cloud/tests/test_nextcloud.py

17
playbooks/cloud/tests/test_nextcloud.py

@ -1,10 +1,11 @@
import pytest
testinfra_hosts = ['ansible://cloud-host']
def test_nextcloud(host):
def test_nextcloud_web(host):
cmd = host.run("""
set -xe
mount | grep /dev/mapper/spare
curl --silent https://cloud.$(hostname -d)/login | \
grep --quiet 'This application requires JavaScript'
""")
@ -13,6 +14,18 @@ def test_nextcloud(host):
assert 0 == cmd.rc
def test_nextcloud_device(request, host):
if request.session.infrastructure.driver == 'libvirt':
pytest.skip("libvirt does not support external devices")
cmd = host.run("""
set -xe
mount | grep /dev/mapper/spare
""")
print(cmd.stdout)
print(cmd.stderr)
assert 0 == cmd.rc
def test_nextcloud_via_tor(host):
cmd = host.run("""
set -xe

Loading…
Cancel
Save