fix tests
This commit is contained in:
parent
ae397e20e7
commit
ce62b47085
1 changed files with 7 additions and 6 deletions
|
|
@ -1,6 +1,7 @@
|
||||||
(ns babashka.main-test
|
(ns babashka.main-test
|
||||||
{:clj-kondo/config '{:linters {:unresolved-symbol {:exclude [working?]}}}}
|
{:clj-kondo/config '{:linters {:unresolved-symbol {:exclude [working?]}}}}
|
||||||
(:require
|
(:require
|
||||||
|
[babashka.cli :as cli]
|
||||||
[babashka.main :as main]
|
[babashka.main :as main]
|
||||||
[babashka.test-utils :as test-utils]
|
[babashka.test-utils :as test-utils]
|
||||||
[clojure.edn :as edn]
|
[clojure.edn :as edn]
|
||||||
|
|
@ -30,17 +31,17 @@
|
||||||
|
|
||||||
(deftest parse-opts-test
|
(deftest parse-opts-test
|
||||||
(is (= {:nrepl "1667"}
|
(is (= {:nrepl "1667"}
|
||||||
(main/parse-opts ["--nrepl-server"])))
|
(cli/parse-opts ["--nrepl-server"])))
|
||||||
(is (= {:socket-repl "1666"}
|
(is (= {:socket-repl "1666"}
|
||||||
(main/parse-opts ["--socket-repl"])))
|
(cli/parse-opts ["--socket-repl"])))
|
||||||
(is (= {:nrepl "1667", :classpath "src"}
|
(is (= {:nrepl "1667", :classpath "src"}
|
||||||
(main/parse-opts ["--nrepl-server" "-cp" "src"])))
|
(cli/parse-opts ["--nrepl-server" "-cp" "src"])))
|
||||||
(is (= {:socket-repl "1666", :expressions ["123"]}
|
(is (= {:socket-repl "1666", :expressions ["123"]}
|
||||||
(main/parse-opts ["--socket-repl" "-e" "123"])))
|
(cli/parse-opts ["--socket-repl" "-e" "123"])))
|
||||||
(is (= {:socket-repl "1666", :expressions ["123"]}
|
(is (= {:socket-repl "1666", :expressions ["123"]}
|
||||||
(main/parse-opts ["--socket-repl" "1666" "-e" "123"])))
|
(cli/parse-opts ["--socket-repl" "1666" "-e" "123"])))
|
||||||
(is (= {:nrepl "1666", :expressions ["123"]}
|
(is (= {:nrepl "1666", :expressions ["123"]}
|
||||||
(main/parse-opts ["--nrepl-server" "1666" "-e" "123"])))
|
(cli/parse-opts ["--nrepl-server" "1666" "-e" "123"])))
|
||||||
(is (= 123 (bb nil "(println 123)")))
|
(is (= 123 (bb nil "(println 123)")))
|
||||||
(is (= 123 (bb nil "-e" "(println 123)")))
|
(is (= 123 (bb nil "-e" "(println 123)")))
|
||||||
(is (= 123 (bb nil "--eval" "(println 123)")))
|
(is (= 123 (bb nil "--eval" "(println 123)")))
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue