| # LLM API Test Runner | |
| # This script sets up the environment and runs the test suite | |
| echo "π Starting LLM API Test Suite..." | |
| # Check if virtual environment exists | |
| if [ ! -d "venv" ]; then | |
| echo "π¦ Creating virtual environment..." | |
| python3 -m venv venv | |
| fi | |
| # Activate virtual environment | |
| echo "π§ Activating virtual environment..." | |
| source venv/bin/activate | |
| # Upgrade pip | |
| echo "β¬οΈ Upgrading pip..." | |
| pip install --upgrade pip | |
| # Install dependencies | |
| echo "π Installing dependencies..." | |
| pip install -r requirements.txt | |
| # Run tests | |
| echo "π§ͺ Running test suite..." | |
| python -m pytest tests/ -v --cov=app --cov-report=term-missing --cov-report=html | |
| echo "β Test suite completed!" | |
| echo "π Coverage report generated in htmlcov/index.html" | |