# Backend
./backend/scripts/setup_test_db.sh
cd backend
UV_NATIVE_TLS=1 uv run python scripts/check_test_db_connectivity.py
DATABASE_URL=postgresql://sidebar:sidebar_dev@localhost:5433/sidebar_test UV_NATIVE_TLS=1 uv run pytest -q -rs
UV_NATIVE_TLS=1 uv run pytest tests/api/test_notes_service.py # Specific file
UV_NATIVE_TLS=1 uv run pytest -k "pin_note" # Pattern matching
UV_NATIVE_TLS=1 uv run pytest --cov=api --cov-report=term-missing # With coverage
# Hosted Supabase integration lane (explicit opt-in)
USE_SUPABASE_TEST_DB=1 UV_NATIVE_TLS=1 uv run python scripts/check_test_db_connectivity.py
USE_SUPABASE_TEST_DB=1 UV_NATIVE_TLS=1 uv run pytest -q -rs
# Frontend
npm test # All tests
npm test TaskItem # Specific file
npm run coverage # With coverage
# iOS
./scripts/test-ios.sh # Xcode scheme tests (unit + UI)
IOS_DESTINATION='platform=iOS Simulator,name=iPhone 15 Pro' ./scripts/test-ios.sh
# Deterministic CLI verification (recommended when full suite is flaky in parallel)
xcodebuild -project ios/sideBar/sideBar.xcodeproj -scheme sideBar \
-destination 'platform=iOS Simulator,name=iPhone 17 Pro,OS=26.2' \
-parallel-testing-enabled NO \
-only-testing:sideBarTests test
# Optional local retry mode for transient simulator/runtime flake triage
xcodebuild -project ios/sideBar/sideBar.xcodeproj -scheme sideBar \
-destination 'platform=iOS Simulator,name=iPhone 17 Pro,OS=26.2' \
-only-testing:sideBarTests \
-retry-tests-on-failure -test-iterations 3 test