feat: add integration smoke tests

CLI-level smoke tests using --yaml output against real Twitter API.
Default skipped via @pytest.mark.smoke marker + pyproject.toml addopts.
Run locally with: uv run pytest -m smoke -v
This commit is contained in:
jackwener
2026-03-10 22:26:46 +08:00
parent fa6255f2ee
commit 9cf74abd56
13 changed files with 562 additions and 193 deletions

View File

@@ -33,6 +33,8 @@ dependencies = [
dev = [
"pytest>=8.0",
"ruff>=0.8",
"mypy>=1.14,<1.15",
"types-PyYAML>=6.0.12",
]
[project.urls]
@@ -46,9 +48,20 @@ twitter = "twitter_cli.cli:cli"
[tool.pytest.ini_options]
testpaths = ["tests"]
python_files = ["test_*.py"]
addopts = "-m 'not smoke'"
markers = [
"smoke: real-API integration tests (run with: pytest -m smoke)",
]
[tool.ruff]
line-length = 100
[tool.mypy]
python_version = "3.8"
ignore_missing_imports = true
check_untyped_defs = true
warn_unused_ignores = true
no_implicit_optional = true
[tool.hatch.build.targets.wheel]
packages = ["twitter_cli"]