Commits

Meikel Brandmeyer committed 0f8b323

Added constant generator

* combinators.clj (unit): new function

Comments (0)

Files changed (1)

src/de/kotka/tap/clojurecheck/combinators.clj

                               [v `(arbitrary ~g ~size)]))
                           (partition 2 gen-bindings)))
          ~@body))))
+
+(defn unit
+  "unit returns a generator, which always returns the given value."
+  [x]
+  (constantly x))