 ;;     (with-cookies cookies
 ;;       (is (= cookies [])))))
 
-;; (deftest test-page-source
-;;   (let-source src
-;;     (when-firefox
-;;         (is (str/starts-with? src "<html><head>")))
-;;     (skip-firefox
-;;         (is (str/starts-with? src "<!DOCTYPE html>")))))
+(deftest test-page-source
+  (let [src (get-source *driver*)]
+    (when-firefox *driver*
+      (is (str/starts-with? src "<html><head>")))
+    (skip-firefox *driver*
+     (is (str/starts-with? src "<!DOCTYPE html>")))))
 
 ;; (deftest test-element-properties
 ;;   (when-firefox

          (= "active-el-input")
          is))))

;; (deftest test-element-text
;;   (with-text "//*[@id='element-text']" text
;;     (is (= text "Element text goes here."))))

;; (deftest test-element-value
;;   (when-chrome
;;       (with-value "//*[@id='element-value']" value
;;         (is (= value "value text")))))

;; (deftest test-cookies
;;   (testing "getting all cookies"

            [etaoin.api :refer :all])
  (:import javax.imageio.ImageIO))

(defmacro with-tmp-file [prefix suffix bind & body]
  `(let [tmp# (java.io.File/createTempFile ~prefix ~suffix)
         ~bind (.getAbsolutePath tmp#)]
     (try
       ~@body
       (finally
         (.delete tmp#)))))

(defn numeric? [val]
  (or (instance? Double val)
