diff --git a/dev/user.clj b/dev/user.clj index 583ad0f..10dfd25 100644 --- a/dev/user.clj +++ b/dev/user.clj @@ -1,11 +1,14 @@ (ns user (:require + ;; this unfortunately precludes testing against nrepl/nrepl + ;; better to have this code as a script to include during development? [clojure.tools.nrepl] - [cider.piggieback :as pback] [cljs.repl :as repl] [cljs.repl.nashorn :as nash] [cljs.repl.node :as node])) +(require '[cider.piggieback :as pback]) + (defn cljs [] (pback/cljs-repl (nash/repl-env :verbose true :repl-verbose true))) diff --git a/test/cider/piggieback_test.clj b/test/cider/piggieback_test.clj index 74c2724..b656d34 100644 --- a/test/cider/piggieback_test.clj +++ b/test/cider/piggieback_test.clj @@ -1,9 +1,16 @@ (ns cider.piggieback-test - (:require [cider.piggieback :as pb] - [nrepl.core :as nrepl] - [nrepl.server :as server]) (:use clojure.test)) +(if (find-ns 'clojure.tools.nrepl) + (require + '[clojure.tools.nrepl :as nrepl] + '[clojure.tools.nrepl.server :as server]) + (require + '[nrepl.core :as nrepl] + '[nrepl.server :as server])) + +(require '[cider.piggieback :as pb]) + (def ^:dynamic *server-port* nil) (def ^:dynamic *session*)