Skip to content

Commit

Permalink
tidy: use swap! without anonymous functions
Browse files Browse the repository at this point in the history
  • Loading branch information
seanstrom committed May 9, 2024
1 parent 47ab107 commit cc9937f
Showing 1 changed file with 15 additions and 15 deletions.
30 changes: 15 additions & 15 deletions src/status_im/subs/wallet/wallet_test.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -591,11 +591,11 @@
[sub-name]
(testing "returns formatted key-pairs and accounts"
(swap! rf-db/app-db
#(assoc-in %
[:wallet :keypairs]
[(assoc keypairs-accounts
:accounts
[wallet-account])]))
assoc-in
[:wallet :keypairs]
[(assoc keypairs-accounts
:accounts
[wallet-account])])

(let [{:keys [customization-color name address emoji]} wallet-account]
(is
Expand All @@ -614,11 +614,11 @@

(testing "allows for passing account format options"
(swap! rf-db/app-db
#(assoc-in %
[:wallet :keypairs]
[(assoc keypairs-accounts
:accounts
[wallet-account])]))
assoc-in
[:wallet :keypairs]
[(assoc keypairs-accounts
:accounts
[wallet-account])])

(let [{:keys [customization-color
name
Expand Down Expand Up @@ -646,11 +646,11 @@

(testing "filters non-wallet accounts"
(swap! rf-db/app-db
#(assoc-in %
[:wallet :keypairs]
[(assoc keypairs-accounts
:accounts
[chat-account])]))
assoc-in
[:wallet :keypairs]
[(assoc keypairs-accounts
:accounts
[chat-account])])
(is
(match? [{:name (:name keypairs-accounts)
:type (keyword (:type keypairs-accounts))
Expand Down

0 comments on commit cc9937f

Please sign in to comment.