V2-4 : placements multi-device (report_bytes, tables 000015, copies UI)

This commit is contained in:
venture
2026-09-25 19:45:33 +02:00
parent 0f90aad938
commit a91ddf7aa8
42 changed files with 714 additions and 25 deletions
+17
View File
@@ -333,6 +333,23 @@ func TestMigrationsUpDown(t *testing.T) {
t.Error("index unique partiel (id) WHERE revoked_at IS NULL manquant sur share_links")
}
// --- 000014 : has_content + 000015 : placements -------------------------
var hasContentCol int
err = conn.QueryRow(`
SELECT COUNT(*) FROM information_schema.columns
WHERE table_schema = 'public' AND table_name = 'resources' AND column_name = 'has_content'`).Scan(&hasContentCol)
if err != nil {
t.Fatalf("has_content column: %v", err)
}
if hasContentCol == 0 {
t.Error("colonne resources.has_content manquante après 000014")
}
assertTables(t, conn, "users", "devices", "resources", "operations", "ocr_jobs", "shares", "share_links", "storage_locations", "resource_placements", "schema_migrations")
assertHexCheck(t, conn, "storage_locations", "id")
assertHexCheck(t, conn, "storage_locations", "device_id")
if err := MigrateDownDatabase(url); err != nil {
t.Fatalf("migrate down: %v", err)
}