Index of all namespaces
QuickCheck clone for Clojure
A QuickCheck clone for Clojure.
A ->Arbitrary arbitrary arbitrary-ascii-char arbitrary-ascii-letter arbitrary-ascii-string arbitrary-boolean arbitrary-byte arbitrary-byte-array arbitrary-char arbitrary-float arbitrary-function arbitrary-int arbitrary-int-like arbitrary-integer arbitrary-integer-from-to arbitrary-keyword arbitrary-list arbitrary-long arbitrary-map arbitrary-mixed arbitrary-natural arbitrary-one-of arbitrary-printable-ascii-char arbitrary-printable-ascii-string arbitrary-rational arbitrary-record arbitrary-sequence-like arbitrary-set arbitrary-short arbitrary-string arbitrary-symbol arbitrary-symbol-like arbitrary-tuple arbitrary-unsigned-byte arbitrary-unsigned-int arbitrary-unsigned-long arbitrary-unsigned-short arbitrary-vector
C ->Check-result ->Config check check-results choose-alphanumeric-char choose-ascii-char choose-ascii-letter choose-byte choose-byte-array choose-char choose-char-with-property choose-float choose-int choose-integer choose-keyword choose-list choose-long choose-map choose-mixed choose-non-numeric-char choose-one-of choose-printable-ascii-char choose-set choose-short choose-string choose-symbol choose-unsigned-byte choose-unsigned-int choose-unsigned-long choose-unsigned-short choose-vector choose-with-frequencies classify coarbitrary coerce->generator coerce->result-generator collect
A Clojure port of the original Haskell QuickCheck.
(We looked at ClojureCheck,
clojure.test.generative, but neither seems faithful to the original, particularly concerning the reproducibility of test runs, and a set of generator combinators that includes random generation of functions.
test.check is going down the right path, but it’s lacking some features we want, and is moving too slow for our purposes.
This library, however, is a straighforward port of the Haskell code from John Hughes’s original paper.
Releases and Dependency Information
Latest stable release: 0.3.0
Leiningen dependency information:
(quickcheck (property [xs (list integer) ys (list integer)] (= (reverse (concat xs ys)) (concat (reverse ys) (reverse xs)))))
(deftest reverse-distributes-over-concat (testing "reverse distributes over concat" (is (quickcheck (property [xs (list integer) ys (list integer)] (= (reverse (concat xs ys)) (concat (reverse ys) (reverse xs))))))))
Copyright © 2013 Active Group GmbH
Distributed under the Eclipse Public License, the same as Clojure.