Files
HadTavern/tests/test_pytest_wrapper.py

23 lines
1.2 KiB
Python
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Pytest-обёртка для существующих сценариев, которые сами себя запускают через run_all()/run_checks()
# Позволяет запускать все тесты одной командой: python -m pytest -q
# Не меняем исходные файлы, просто вызываем их публичные функции из pytest-тестов.
def test_executor_iterative():
# tests/test_executor_iterative.py содержит run_checks() (внутри сам asyncio.run)
from tests.test_executor_iterative import run_checks
run_checks()
def test_edge_cases():
# tests/test_edge_cases.py содержит run_all() (внутри сам asyncio.run)
from tests.test_edge_cases import run_all
run_all()
def test_macros_and_vars():
# tests/test_macros_vars.py содержит run_all() (внутри сам asyncio.run)
from tests.test_macros_vars import run_all
run_all()
def test_while_nodes():
# наш новый набор сценариев; внутри есть run_all() со своим asyncio.run
from tests.test_while_nodes import run_all
run_all()