Skip to content

Commit

Permalink
test comments
Browse files Browse the repository at this point in the history
  • Loading branch information
rsh-blip committed Mar 13, 2023
1 parent bdd2dec commit 1bcaa50
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions cljfmt/test/cljfmt/core_test.cljc
Original file line number Diff line number Diff line change
Expand Up @@ -1407,4 +1407,19 @@
["{:a 1"
" :longer 2"
" :b 3}"]
{:align-associative? true})))
(testing "binding align preserves comments"
(is (reformats-to?
["(let [a 1 ;; comment"
" longer 2])"]
["(let [a 1 ;; comment"
" longer 2])"]
{:align-associative? true}
)))
(testing "map align preserves comments"
(is (reformats-to?
["{:a 1 ;; comment"
" :longer 2}"]
["{:a 1 ;; comment"
" :longer 2}"]
{:align-associative? true}))))

0 comments on commit 1bcaa50

Please sign in to comment.