quickcheck
| Kind | kit |
|---|---|
| Categories | testing development-tools |
| Keywords | testing property-based quickcheck generators |
Property-based testing for Kit inspired by QuickCheck
Files
| File | Description |
|---|---|
kit.toml | Package manifest with metadata and dependencies |
src/main.kit | Generators, property checking, and shrinking functions |
tests/quickcheck.test.kit | Tests for generators, combinators, and property validation |
examples/basic.kit | Property testing for list and arithmetic laws |
LICENSE | MIT license file |
Dependencies
No Kit package dependencies.
Installation
kit add gitlab.com/kit-lang/packages/kit-quickcheck.gitUsage
import Kit.QuickcheckLicense
MIT License - see LICENSE for details.
Exported Functions & Types
gen-int
Int -> Int
gen-int-range
Int -> Int -> Int -> Int
gen-nat
Int -> Int
gen-bool?
Int -> Bool
gen-float
Int -> Float
gen-float-range
Float -> Float -> Int -> Float
gen-char
Int -> Char
gen-alpha-num
Int -> String
gen-lower
Int -> Char
gen-upper
Int -> Char
gen-string
Int -> String
gen-alpha-num-string
Int -> String
gen-list
(Int -> a) -> Int -> [a]
gen-non-empty-list
(Int -> a) -> Int -> [a]
gen-list-of-length
Int -> (Int -> a) -> Int -> [a]
gen-option
(Int -> a) -> Int -> Option a
gen-tuple2
(Int -> a) -> (Int -> b) -> Int -> (a, b)
gen-tuple3
(Int -> a) -> (Int -> b) -> (Int -> c) -> Int -> (a, b, c)
gen-one-of
[(Int -> a)] -> Int -> a
gen-frequency
[(Int, Int -> a)] -> Int -> a
gen-const
a -> Int -> a
gen-map
(a -> b) -> (Int -> a) -> Int -> b
gen-such-that
(a -> Bool) -> (Int -> a) -> Int -> a
sample
(Int -> a) -> a
sample-sized
Int -> (Int -> a) -> a
samples
(Int -> a) -> Int -> [a]
check
String -> (Int -> a) -> (a -> Bool) -> Result Int {tests: Int, value: a}
check-n
String -> Int -> (Int -> a) -> (a -> Bool) -> Result Int {tests: Int, value: a}
check-all
[(String, ((Int -> a), a -> Bool))] -> Result Int Int
shrink-int
Int -> [Int]
shrink-list
[a] -> [[a]]
shrink-str
String -> [String]