This repository has been archived by the owner. It is now read-only.
Randomized testing for Prolog à la QuickCheck
Prolog
Switch branches/tags
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
prolog
t
.gitignore
History.md
LICENSE
README.md
pack.pl

README.md

Synopsis

:- use_module(library(quickcheck)).

% reversing a list twice gives back the same list
prop_reverse_twice(L:list) :-
    reverse(L, R),
    reverse(R, L).

?- quickcheck(prop_reverse_twice/1).
100 tests OK
true.

Description

Randomized testing of program properties in the spirit of QuickCheck. Describe properties of your predicates and let library(quickheck) generate test cases for you.

A detailed tutorial is available.

Installation

Using SWI-Prolog 7.1 or later:

?- pack_install(quickcheck).

This module uses semantic versioning.

Source code available and pull requests accepted at http://github.com/mndrix/quickcheck