Skip to content

Commit

Permalink
* more assertions for case
Browse files Browse the repository at this point in the history
  • Loading branch information
swannodette committed Nov 18, 2024
1 parent e888fae commit 82efd24
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/test/clojure/cljs/analyzer/spec_tests.clj
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,13 @@
(is (s/valid? ::a/node binding))))

(deftest test-case
(let [node (no-warn (analyze ns-env '(case x 1 :foo 2 :bar)))]
(let [let-node (no-warn (analyze ns-env '(case x 1 :foo 2 :bar)))
node (-> let-node :body :ret)]
(is (= :case (:op node)))
(is (s/valid? ::a/node node))))

;; case-node
;; case-test
;; case-node
;; case-then

(deftest test-const
Expand Down

0 comments on commit 82efd24

Please sign in to comment.