feat: implement WebADIS authentication and add medianumber retrieval functionality
This commit is contained in:
20
tests/test_migrations_runner.py
Normal file
20
tests/test_migrations_runner.py
Normal file
@@ -0,0 +1,20 @@
|
||||
import sqlite3 as sql
|
||||
from pathlib import Path
|
||||
|
||||
from src.backend.database import Database
|
||||
|
||||
p = Path("devtests_test_migrations.db")
|
||||
if p.exists():
|
||||
p.unlink()
|
||||
|
||||
print("Creating Database at", p)
|
||||
db = Database(db_path=p)
|
||||
|
||||
conn = sql.connect(p)
|
||||
c = conn.cursor()
|
||||
c.execute("SELECT name FROM sqlite_master WHERE type='table'")
|
||||
print("Tables:", sorted([r[0] for r in c.fetchall()]))
|
||||
|
||||
c.execute("SELECT id, applied_at FROM schema_migrations")
|
||||
print("Migrations applied:", c.fetchall())
|
||||
conn.close()
|
||||
Reference in New Issue
Block a user