   (:require [oxcart.pattern :as p]
             [oxcart.test-util :refer :all]
             [clojure.test :refer :all]))
+
+
+(def ops
+  #{:binding :catch :const :def :do :fn :fn-method
+    :host-call :host-field :host-interop :if :invoke
+    :let :letfn :local :loop :map :maybe-class
+    :maybe-host-form :new :quote :recur :set :set!
+    :throw :try :var :vector :with-meta})
 
 
 (def foo



(deftest def?-tests
  (is (p/def? foo))
  (is (p/def? bar))
  (is-not (p/def? fail)))



(deftest let?-tests
  (doseq [op ops]
    (if (not= op :let)
      (is-not (p/let? {:op op}))
      (is (p/let? {:op op}))))
  (is-not (p/let? foo))
  (is-not (p/let? (:init foo)))
  (is-not (p/let? bar))
  (is-not (p/let? (:init bar)))
  (is (p/let? addition)))


(deftest letfn?-tests
  (doseq [op ops]
    (if (not= op :letfn)
      (is-not (p/letfn? {:op op}))
      (is (p/letfn? {:op op}))))
  (is-not (p/letfn? addition))
  (is-not (p/letfn? foo))
  (is-not (p/letfn? (:init foo)))
