From 392d41749a0771f4e32d53579932fa63b59c69c0 Mon Sep 17 00:00:00 2001 From: vemv Date: Sun, 18 Jul 2021 18:47:27 +0200 Subject: [PATCH] Address remaining reflection warnings (#324) --- project.clj | 5 ++--- test/refactor_nrepl/ns/resolve_missing_test.clj | 6 ++++-- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/project.clj b/project.clj index aced53d3..5298d6de 100644 --- a/project.clj +++ b/project.clj @@ -46,8 +46,7 @@ :lein-plugin {:source-paths ["lein-plugin"]} :test {:dependencies [[print-foo "1.0.2"]]} - :dev {:global-vars {*warn-on-reflection* true} - :dependencies [[org.clojure/clojurescript "1.10.520"] + :dev {:dependencies [[org.clojure/clojurescript "1.10.520"] [org.clojure/core.async "1.3.618" :exclusions [org.clojure/clojure org.clojure/tools.reader]] [cider/piggieback "0.5.2"] [commons-io/commons-io "2.8.0"]] @@ -67,7 +66,7 @@ with-debug-bindings [[:inner 0]] merge-meta [[:inner 0]] try-if-let [[:block 1]]}}}] - :eastwood {:plugins [[jonase/eastwood "0.7.1"]] + :eastwood {:plugins [[jonase/eastwood "0.9.1"]] :eastwood {;; vendored - shouldn't be tweaked for satisfying linters: :exclude-namespaces [refactor-nrepl.ns.slam.hound.regrow] ;; :implicit-dependencies would fail spuriously when the CI matrix runs for Clojure < 1.10, diff --git a/test/refactor_nrepl/ns/resolve_missing_test.clj b/test/refactor_nrepl/ns/resolve_missing_test.clj index 2c096343..41487892 100644 --- a/test/refactor_nrepl/ns/resolve_missing_test.clj +++ b/test/refactor_nrepl/ns/resolve_missing_test.clj @@ -12,7 +12,9 @@ (defn session-fixture [f] - (with-open [server (server/start-server :bind "localhost" :handler *handler*) + (with-open [^nrepl.server.Server + server (server/start-server :bind "localhost" :handler *handler*) + ^nrepl.transport.FnTransport transport (nrepl/connect :port (:port server))] (let [client (nrepl/client transport Long/MAX_VALUE)] (binding [*session* (nrepl/client-session client)] @@ -77,7 +79,7 @@ (t/is (= 'cljs.repl name)) (t/is (= :ns type))) (t/testing "Finds macros" - (let [{:keys [error] :as response} (message {:op :resolve-missing :symbol 'dir}) + (let [{:keys [^String error] :as response} (message {:op :resolve-missing :symbol 'dir}) {:keys [name type]} (first (edn/read-string (:candidates response)))] (when error (throw (RuntimeException. error)))