Skip to content

Commit

Permalink
redirect
Browse files Browse the repository at this point in the history
  • Loading branch information
evgeni committed Nov 21, 2024
1 parent 37de29b commit 4221c48
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions tests/foreman/sys/test_fam.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
"""

from broker import Broker
from pathlib import Path
import pytest
import yaml

Expand Down Expand Up @@ -190,6 +191,12 @@ def test_positive_run_modules_and_roles(module_target_sat, setup_fam, ansible_mo

# Execute test_playbook
result = module_target_sat.execute(
f'export NO_COLOR=True && export PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 && cd {FAM_ROOT_DIR} && make livetest_{ansible_module} PYTHON_COMMAND="python3" PYTEST_COMMAND="pytest-3.11"'
f'export NO_COLOR=True && export PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 && cd {FAM_ROOT_DIR} && make livetest_{ansible_module} PYTHON_COMMAND="python3" PYTEST_COMMAND="pytest-3.11" >/tmp/pytest.stdout 2>/tmp/pytest.stderr'
)
assert result.status == 0, f"{result.status=}\nstdout:\n{result.stdout} stderr:\n{result.stderr}"
module_target_sat.get('/tmp/pytest.stdout', 'pytest.stdout')
module_target_sat.get('/tmp/pytest.stderr', 'pytest.stderr')

stdout = Path('pytest.stdout').read_text()
stderr = Path('pytest.stderr').read_text()

assert result.status == 0, f"{result.status=}\nstdout:\n{stdout} stderr:\n{stderr}"

0 comments on commit 4221c48

Please sign in to comment.