From 58b20b5dd7a6f1538f3848f8737a79f118670e9d Mon Sep 17 00:00:00 2001 From: Andrey Antukh Date: Sat, 17 Oct 2026 19:41:39 +0000 Subject: [PATCH] :bug: Read v1 import file ids from the file-ids map in test The v1 importer answers {:file-ids [...]} like v3, so (first result) returned a MapEntry and the media lookup failed on Postgres type inference. Take the new id from (:file-ids result) instead. AI-assisted-by: muse-spark-1.3-contributor --- backend/test/backend_tests/binfile_test.clj | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/backend/test/backend_tests/binfile_test.clj b/backend/test/backend_tests/binfile_test.clj index aeb69b7e2f..f47833556c 100644 --- a/backend/test/backend_tests/binfile_test.clj +++ b/backend/test/backend_tests/binfile_test.clj @@ -3173,7 +3173,7 @@ (assoc ::bfc/profile-id (:id profile)) (assoc ::bfc/input output) (v1/import-files!)) - new-id (first result) + new-id (first (:file-ids result)) media (first (th/db-query :file-media-object {:file-id new-id :deleted-at nil})) thumb (first (bfc/get-file-object-thumbnails th/*system* new-id)) storage (-> (:app.storage/storage th/*system*) @@ -3181,7 +3181,7 @@ obj1 (sto/get-object storage (:media-id media)) obj2 (sto/get-object storage (:media-id thumb))] - (t/is (= 1 (count result))) + (t/is (= 1 (count (:file-ids result)))) (t/is (some? media)) (t/is (some? thumb)) (t/is (not= (:id obj1) (:id obj2)))