Skip to content

Commit b85d550

Browse files
dynj: add a test for with-bindings*
1 parent 72cc61d commit b85d550

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

test/active/clojure/dynj_test.clj

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,15 @@
2626
(foo v))))]
2727
(t/is (= 8 (f 4)))))
2828

29+
(t/deftest with-bindings*-test
30+
(t/is
31+
(= 7
32+
(sut/with-bindings*
33+
;; just "foo" doesn't work here; Var is expected
34+
{#'foo (fn [x] (+ x 4))}
35+
;; expects a thunk
36+
(fn [] (foo 3))))))
37+
2938
(sut/defn-dynj bar [arg]
3039
(* 3 arg))
3140

0 commit comments

Comments
 (0)