File tree Expand file tree Collapse file tree 3 files changed +16
-1
lines changed
resources/clj-kondo.exports/clj-python/libpython-clj Expand file tree Collapse file tree 3 files changed +16
-1
lines changed Original file line number Diff line number Diff line change 1- {:hooks
1+ {:lint-as {libpython-clj2.python/with clojure.core/with-open}
2+
3+ :hooks
24 {:analyze-call {libpython-clj.jna.base/def-pylib-fn
35 hooks.libpython-clj.jna.base.def-pylib-fn/def-pylib-fn
46
Original file line number Diff line number Diff line change 1+ (ns clj-kondo.fixtures.py-with-test
2+ (:require [libpython-clj2.python :as py]))
3+
4+ (defn test-py-with [testcode]
5+ (py/with [f (py/call-attr testcode " FileWrapper" " content" )]
6+ (py/call-attr f " read" )))
Original file line number Diff line number Diff line change 4545 output (str out err)]
4646 (is (not (has-py-dot-errors? output))
4747 (str " Found py. related errors in output:\n " output)))))
48+
49+ (deftest py-with-test
50+ (testing " py_with_test.clj - py/with binding"
51+ (let [{:keys [out err]} (run-clj-kondo (str fixtures-dir " /py_with_test.clj" ))
52+ output (str out err)]
53+ (is (not (re-find #"Unresolved symbol: f" output))
54+ (str " py/with binding not recognized:\n " output)))))
You can’t perform that action at this time.
0 commit comments