testsAndMisc-archive/python_pkg/articles/run_tests.sh
Krzysztof kuhy Rudnicki 4cf523bf6d refactor: move Python packages under python_pkg/
- Move puzzle_solver/, poker_modifier_app/, articles/, tests/ into python_pkg/
- Move moviepy_showcase.py and _moviepy_*.py into python_pkg/moviepy_showcase/
- Update all imports to use python_pkg. prefix
- Update pyproject.toml per-file-ignores and pytest testpaths
- Add pre-commit hook to enforce Python files under python_pkg/
2026-03-18 22:54:45 +01:00

20 lines
539 B
Bash
Executable File

#!/usr/bin/env bash
set -euo pipefail
# Run only the website tests from this directory
DIR=$(cd -- "$(dirname -- "$0")" && pwd)
cd "$DIR"
PYTHON_BIN="${PYTHON:-}"
if [[ -z "${PYTHON_BIN}" ]]; then
if command -v python >/dev/null 2>&1; then PYTHON_BIN=python
elif command -v python3 >/dev/null 2>&1; then PYTHON_BIN=python3
else
echo "Python is required but not found in PATH." >&2
exit 1
fi
fi
# Be explicit to avoid collecting tests from other repo paths
"$PYTHON_BIN" -m pytest -q test_site_size.py test_server_api.py