       (browser/wait-until #(= (first-element-text "h1") "Hello Test :)")))))
 
 (defn -main []
-  (test-basic))
+  (test-basic)
+  (doseq [opt chestnut/valid-options]
+    (test-basic opt)))

     (finally
       (browser/close))))

(defn generate-new-app []
  (println "--> Generating app in /tmp/sesame-seed")
  (rm-rf "/tmp/sesame-seed")
  (wait-for (spawn "LEIN NEW" "/tmp" "lein new chestnut sesame-seed --snapshot")))

(defn first-element-text [selector]
  (browser/text (first (browser/css-finder selector))))

(defn test-basic []
  (generate-new-app)
  (println "--> Starting REPL")
  (with-process [repl "REPL" "/tmp/sesame-seed" "lein repl"]
    (expect repl #"sesame-seed\.server=>" 90)
    (write-str repl "(run)\n")
    (expect repl #"notifying browser that file changed")
    (write-str repl "(browser-repl)\n")
    (expect repl #"sesame-seed\.core=>")


  (:require [clojure.java.io :as io]
            [mistletoe.process :refer :all]
            [mistletoe.test :refer :all]
            [clj-webdriver.taxi :as browser]
            [leiningen.new.chestnut :as chestnut]))

(def browser-type :chrome)

