tests: Show warning when app not available

Signed-off-by: James Valleroy <jvalleroy@mailbox.org>
Reviewed-by: Sunil Mohan Adapa <sunil@medhas.org>
This commit is contained in:
James Valleroy 2021-09-18 18:53:13 -04:00 committed by Sunil Mohan Adapa
parent e31053eb92
commit 0440b7ba52
No known key found for this signature in database
GPG Key ID: 43EA1CFF0AA7C5F2

View File

@ -10,6 +10,7 @@ import pathlib
import subprocess
import tempfile
import time
import warnings
from contextlib import contextmanager
import pytest
@ -345,6 +346,8 @@ def install(browser, app_name):
browser.visit(browser.url)
else:
# This app is not available in this distribution
warnings.warn(
f'App {app_name} is not available in distribution')
pytest.skip('App not available in distribution')
else:
install_button.click()