Coverage for tests/utils.py: 100%
9 statements
« prev ^ index » next coverage.py v7.6.1, created at 2025-12-19 20:29 +0000
« prev ^ index » next coverage.py v7.6.1, created at 2025-12-19 20:29 +0000
1import sys 1abcdefghi
2from os import getenv 1abcdefghi
4import pytest 1abcdefghi
5from typer._completion_shared import _get_shell_name 1abcdefghi
7needs_py310 = pytest.mark.skipif( 1abcdefghi
8 sys.version_info < (3, 10), reason="requires python3.10+"
9)
11needs_linux = pytest.mark.skipif( 1abcdefghi
12 not sys.platform.startswith("linux"), reason="Test requires Linux"
13)
15shell = _get_shell_name() 1abcdefghi
16needs_bash = pytest.mark.skipif( 1abcdefghi
17 shell is None or "bash" not in shell, reason="Test requires Bash"
18)
20requires_completion_permission = pytest.mark.skipif( 1abcdefghi
21 not getenv("_TYPER_RUN_INSTALL_COMPLETION_TESTS", False),
22 reason="Test requires permission to run completion installation tests",
23)