feat: správa poznávaček, optimalizace fotek do WebP a úložiště
This commit is contained in:
1 parent
7a8dccb2f7
commit
c46bb74386
27 files changed
+4367
-5
No files matched your search
@@ -50,6 +50,7 @@ def test_migrations_applied_once_and_skipped_on_restart(
|
||||
assert first_versions == [
|
||||
"0001_initial_schema.sql",
|
||||
"0002_token_hash_index.sql",
|
||||
"0003_fotky_soubor_indexes.sql",
|
||||
]
|
||||
|
||||
# Opakovaný start nesmí selhat ani smazat data.
|
||||
@@ -159,3 +160,17 @@ def test_token_hash_unique_index_enforced(
|
||||
""",
|
||||
(user_id, "hash-tokenu-1", "2099-01-01T01:00:00Z"),
|
||||
)
|
||||
|
||||
|
||||
def test_fotky_file_indexes_created(db: sqlite3.Connection) -> None:
|
||||
index_names = {
|
||||
row["name"]
|
||||
for row in db.execute(
|
||||
"""
|
||||
SELECT name FROM sqlite_master
|
||||
WHERE type = 'index' AND tbl_name = 'fotky'
|
||||
"""
|
||||
).fetchall()
|
||||
}
|
||||
assert "idx_fotky_soubor_plny" in index_names
|
||||
assert "idx_fotky_soubor_nahled" in index_names
|
||||
Reference in new issue
Block a user