Fix tests

This commit is contained in:
Ulises M 2024-12-20 17:07:19 -06:00
parent 96a06e70bc
commit e9a064ad71
No known key found for this signature in database
GPG Key ID: 5A15782EB758534E
2 changed files with 6 additions and 3 deletions

View File

@ -24,4 +24,4 @@
:params [key-uid]
:on-success [:profile/delete-profile-picture-success]}]]]}]
(is (match? expected
(sut/delete-profile-picture cofx)))))
(sut/delete-profile-picture cofx false)))))

View File

@ -14,7 +14,7 @@
(fn []
(let [new-name "John Doe"]
(promesa/do
(rf/dispatch [:profile/edit-name new-name])
(rf/dispatch [:profile/edit-name {:display-name new-name}])
(h/wait-for [:navigate-back :toasts/upsert])
(let [profile (rf/sub [:profile/profile])
display-name (profile.utils/displayed-name profile)]
@ -26,7 +26,10 @@
(let [mock-image "resources/images/mock2/monkey.png"
absolute-path (.resolve test-utils/path mock-image)]
(promesa/do
(rf/dispatch [:profile/edit-picture absolute-path 80 80])
(rf/dispatch [:profile/edit-picture
{:picture absolute-path
:crop-width 80
:crop-height 80}])
(h/wait-for [:profile/update-local-picture :toasts/upsert])
(let [profile (rf/sub [:profile/profile])]
(is (not (nil? (:images profile))))))))))