Fix animation inconsistencies on pages with loading spinners
This commit is contained in:
18
backend/test_api_tests.py
Normal file
18
backend/test_api_tests.py
Normal file
@@ -0,0 +1,18 @@
|
||||
import asyncio
|
||||
from sqlmodel import create_engine, select, Session
|
||||
import sys
|
||||
sys.path.append('backend')
|
||||
import models
|
||||
|
||||
DATABASE_URL = "postgresql://pragativeer_admin:local_secure_password_2026@postgres:5432/pragativeer_prod"
|
||||
engine = create_engine(DATABASE_URL)
|
||||
|
||||
with Session(engine) as session:
|
||||
user = session.exec(select(models.User).where(models.User.name == "Amit Kumar")).first()
|
||||
print(f"User: {user.name}, Tier: {user.tier}, Exam: {user.target_exam}")
|
||||
|
||||
query = select(models.Test).where(models.Test.is_active == True).where(models.Test.type != "DPS")
|
||||
tests = session.exec(query).all()
|
||||
print(f"Tests returned from DB (excluding DPS): {len(tests)}")
|
||||
for t in tests:
|
||||
print(f" - {t.title} ({t.exam_pattern})")
|
||||
Reference in New Issue
Block a user