mirror of
https://github.com/penpot/penpot.git
synced 2025-06-06 06:41:38 +02:00
💄 Fix backend tests.
This commit is contained in:
parent
a27828ed79
commit
0536b64ae5
6 changed files with 18 additions and 18 deletions
|
@ -16,7 +16,7 @@
|
||||||
(t/deftest color-libraries-crud
|
(t/deftest color-libraries-crud
|
||||||
(let [id (uuid/next)
|
(let [id (uuid/next)
|
||||||
prof (th/create-profile db/pool 2)
|
prof (th/create-profile db/pool 2)
|
||||||
team-id (:default-team prof)]
|
team-id (:default-team-id prof)]
|
||||||
|
|
||||||
(t/testing "create library"
|
(t/testing "create library"
|
||||||
(let [data {::sm/type :create-color-library
|
(let [data {::sm/type :create-color-library
|
||||||
|
@ -72,7 +72,7 @@
|
||||||
|
|
||||||
(t/deftest colors-crud
|
(t/deftest colors-crud
|
||||||
(let [prof (th/create-profile db/pool 1)
|
(let [prof (th/create-profile db/pool 1)
|
||||||
team-id (:default-team prof)
|
team-id (:default-team-id prof)
|
||||||
coll (th/create-color-library db/pool team-id 1)
|
coll (th/create-color-library db/pool team-id 1)
|
||||||
color-id (uuid/next)]
|
color-id (uuid/next)]
|
||||||
|
|
||||||
|
|
|
@ -16,8 +16,8 @@
|
||||||
|
|
||||||
(t/deftest files-crud
|
(t/deftest files-crud
|
||||||
(let [prof (th/create-profile db/pool 1)
|
(let [prof (th/create-profile db/pool 1)
|
||||||
team-id (:default-team prof)
|
team-id (:default-team-id prof)
|
||||||
proj-id (:default-project prof)
|
proj-id (:default-project-id prof)
|
||||||
file-id (uuid/next)
|
file-id (uuid/next)
|
||||||
page-id (uuid/next)]
|
page-id (uuid/next)]
|
||||||
|
|
||||||
|
@ -122,8 +122,8 @@
|
||||||
|
|
||||||
(t/deftest file-images-crud
|
(t/deftest file-images-crud
|
||||||
(let [prof (th/create-profile db/pool 1)
|
(let [prof (th/create-profile db/pool 1)
|
||||||
team-id (:default-team prof)
|
team-id (:default-team-id prof)
|
||||||
proj-id (:default-project prof)
|
proj-id (:default-project-id prof)
|
||||||
file (th/create-file db/pool (:id prof) proj-id 1)]
|
file (th/create-file db/pool (:id prof) proj-id 1)]
|
||||||
|
|
||||||
(t/testing "upload file image"
|
(t/testing "upload file image"
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
(t/deftest icon-libraries-crud
|
(t/deftest icon-libraries-crud
|
||||||
(let [id (uuid/next)
|
(let [id (uuid/next)
|
||||||
prof (th/create-profile db/pool 2)
|
prof (th/create-profile db/pool 2)
|
||||||
team-id (:default-team prof)]
|
team-id (:default-team-id prof)]
|
||||||
|
|
||||||
(t/testing "create library"
|
(t/testing "create library"
|
||||||
(let [data {::sm/type :create-icon-library
|
(let [data {::sm/type :create-icon-library
|
||||||
|
@ -89,7 +89,7 @@
|
||||||
|
|
||||||
(t/deftest icons-crud
|
(t/deftest icons-crud
|
||||||
(let [prof (th/create-profile db/pool 1)
|
(let [prof (th/create-profile db/pool 1)
|
||||||
team-id (:default-team prof)
|
team-id (:default-team-id prof)
|
||||||
coll (th/create-icon-library db/pool team-id 1)
|
coll (th/create-icon-library db/pool team-id 1)
|
||||||
icon-id (uuid/next)]
|
icon-id (uuid/next)]
|
||||||
|
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
(t/deftest image-libraries-crud
|
(t/deftest image-libraries-crud
|
||||||
(let [id (uuid/next)
|
(let [id (uuid/next)
|
||||||
prof (th/create-profile db/pool 2)
|
prof (th/create-profile db/pool 2)
|
||||||
team-id (:default-team prof)]
|
team-id (:default-team-id prof)]
|
||||||
|
|
||||||
(t/testing "create library"
|
(t/testing "create library"
|
||||||
(let [data {::sm/type :create-image-library
|
(let [data {::sm/type :create-image-library
|
||||||
|
@ -96,7 +96,7 @@
|
||||||
|
|
||||||
(t/deftest images-crud
|
(t/deftest images-crud
|
||||||
(let [prof (th/create-profile db/pool 1)
|
(let [prof (th/create-profile db/pool 1)
|
||||||
team-id (:default-team prof)
|
team-id (:default-team-id prof)
|
||||||
lib (th/create-image-library db/pool team-id 1)
|
lib (th/create-image-library db/pool team-id 1)
|
||||||
image-id (uuid/next)]
|
image-id (uuid/next)]
|
||||||
|
|
||||||
|
|
|
@ -16,8 +16,8 @@
|
||||||
|
|
||||||
(t/deftest pages-crud
|
(t/deftest pages-crud
|
||||||
(let [prof (th/create-profile db/pool 1)
|
(let [prof (th/create-profile db/pool 1)
|
||||||
team-id (:default-team prof)
|
team-id (:default-team-id prof)
|
||||||
proj-id (:default-project prof)
|
proj-id (:default-project-id prof)
|
||||||
file (th/create-file db/pool (:id prof) proj-id 1)
|
file (th/create-file db/pool (:id prof) proj-id 1)
|
||||||
page-id (uuid/next)]
|
page-id (uuid/next)]
|
||||||
|
|
||||||
|
@ -93,8 +93,8 @@
|
||||||
|
|
||||||
(t/deftest update-page-data
|
(t/deftest update-page-data
|
||||||
(let [prof (th/create-profile db/pool 1)
|
(let [prof (th/create-profile db/pool 1)
|
||||||
team-id (:default-team prof)
|
team-id (:default-team-id prof)
|
||||||
proj-id (:default-project prof)
|
proj-id (:default-project-id prof)
|
||||||
file (th/create-file db/pool (:id prof) proj-id 1)
|
file (th/create-file db/pool (:id prof) proj-id 1)
|
||||||
page-id (uuid/next)]
|
page-id (uuid/next)]
|
||||||
|
|
||||||
|
@ -169,8 +169,8 @@
|
||||||
|
|
||||||
(t/deftest update-page-data-2
|
(t/deftest update-page-data-2
|
||||||
(let [prof (th/create-profile db/pool 1)
|
(let [prof (th/create-profile db/pool 1)
|
||||||
team-id (:default-team prof)
|
team-id (:default-team-id prof)
|
||||||
proj-id (:default-project prof)
|
proj-id (:default-project-id prof)
|
||||||
file (th/create-file db/pool (:id prof) proj-id 1)
|
file (th/create-file db/pool (:id prof) proj-id 1)
|
||||||
page (th/create-page db/pool (:id prof) (:id file) 1)]
|
page (th/create-page db/pool (:id prof) (:id file) 1)]
|
||||||
(t/testing "lagging changes"
|
(t/testing "lagging changes"
|
||||||
|
|
|
@ -17,8 +17,8 @@
|
||||||
(t/deftest retrieve-bundle
|
(t/deftest retrieve-bundle
|
||||||
(let [prof (th/create-profile db/pool 1)
|
(let [prof (th/create-profile db/pool 1)
|
||||||
prof2 (th/create-profile db/pool 2)
|
prof2 (th/create-profile db/pool 2)
|
||||||
team-id (:default-team prof)
|
team-id (:default-team-id prof)
|
||||||
proj-id (:default-project prof)
|
proj-id (:default-project-id prof)
|
||||||
|
|
||||||
file (th/create-file db/pool (:id prof) proj-id 1)
|
file (th/create-file db/pool (:id prof) proj-id 1)
|
||||||
page (th/create-page db/pool (:id prof) (:id file) 1)
|
page (th/create-page db/pool (:id prof) (:id file) 1)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue