mirror of
https://github.com/penpot/penpot.git
synced 2026-10-29 05:50:35 +00:00
🐛 Adapt admin export to new binfile API and fix stale tests
The jobs-refactor base inlined the binfile adapters: export-files! takes the frozen cfg as its single argument, ::bfc/ids is now ::bfc/file-ids and the stream travels as ::bfc/output. The admin export command and its test helper still used the old two-arg call. The export dialog rework also carries :size on the download artifact, so the two stale expectations in exports-files-test now include it. AI-assisted-by: muse-spark-1.3
This commit is contained in:
parent
8853445951
commit
a6eb533c99
@ -353,10 +353,11 @@
|
||||
(let [path (tmp/tempfile :prefix "penpot.export." :min-age "30m")]
|
||||
(with-open [output (io/output-stream path)]
|
||||
(-> cfg
|
||||
(assoc ::bfc/ids (set file-ids))
|
||||
(assoc ::bfc/file-ids (set file-ids))
|
||||
(assoc ::bfc/embed-assets (boolean embedassets))
|
||||
(assoc ::bfc/include-libraries (boolean includelibs))
|
||||
(bf.v3/export-files! output)))
|
||||
(assoc ::bfc/output output)
|
||||
(bf.v3/export-files!)))
|
||||
|
||||
(if clone
|
||||
(let [profile (profile/get-profile pool profile-id)
|
||||
|
||||
@ -425,10 +425,11 @@
|
||||
(let [path (tmp/tempfile :prefix "penpot.import-test." :min-age "30m")]
|
||||
(with-open [output (io/output-stream path)]
|
||||
(-> th/*system*
|
||||
(assoc ::bfc/ids #{file-id})
|
||||
(assoc ::bfc/file-ids #{file-id})
|
||||
(assoc ::bfc/embed-assets false)
|
||||
(assoc ::bfc/include-libraries false)
|
||||
(bf.v3/export-files! output)))
|
||||
(assoc ::bfc/output output)
|
||||
(bf.v3/export-files!)))
|
||||
path))
|
||||
|
||||
(t/deftest export-anonymous-rejected
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user