Skip to content

Commit

Permalink
Switch to testing via lein test. Refs #34.
Browse files Browse the repository at this point in the history
  • Loading branch information
candera committed Jan 18, 2012
1 parent c4b268f commit fb5c6ff
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 26 deletions.
22 changes: 21 additions & 1 deletion test/one/sample/test/integration.clj
Expand Up @@ -2,7 +2,27 @@
"Tests which cross the client server boundary." "Tests which cross the client server boundary."
(:use [clojure.test] (:use [clojure.test]
[one.sample.api :only (*database*)] [one.sample.api :only (*database*)]
[one.test :only (cljs-eval cljs-wait-for)])) [one.test :only (cljs-eval cljs-wait-for)]
[clojure.java.browse :only (browse-url)]
[cljs.repl :only (-setup -tear-down)]
[cljs.repl.browser :only (repl-env)]
[one.test :only (*eval-env*)]
[one.sample.dev-server :only (run-server)]))

(defn setup
"Start the development server and connect to the browser so that
ClojureScript code can be evaluated from tests."
[f]
(let [server (run-server)
eval-env (repl-env)]
(-setup eval-env)
(browse-url "http://localhost:8080/development")
(binding [*eval-env* eval-env]
(f))
(-tear-down eval-env)
(.stop server)))

(use-fixtures :once setup)


(deftest test-enter-new-name (deftest test-enter-new-name
(reset! *database* #{}) (reset! *database* #{})
Expand Down
25 changes: 0 additions & 25 deletions test/one/sample/test/suite.clj

This file was deleted.

0 comments on commit fb5c6ff

Please sign in to comment.