#!/bin/bash
# Test script for MCP Server Gemini
set -e
echo "๐งช Running tests for MCP Server Gemini..."
# Run linting
echo "๐ Running ESLint..."
npx eslint src/**/*.ts --fix
# Run type checking
echo "๐ Type checking..."
npx tsc --noEmit
# Run unit tests
echo "๐งช Running unit tests..."
npx jest --coverage
# Run integration tests if API key is available
if [ -n "$GEMINI_API_KEY" ]; then
echo "๐ Running integration tests..."
npx jest --testPathPattern=integration
else
echo "โ ๏ธ Skipping integration tests (GEMINI_API_KEY not set)"
fi
echo "โ All tests completed successfully!"