TestingClauseTheories

An object containing a collection of notable databases to be used when testing Solver functionality.

Alongside PrologStandardExampleTheories (the manual's own worked examples), this gathers hand-written theories exercising cut, conjunction, backtracking, recursion/non-termination and custom list predicates, each paired with its expected goal-to-Solutions mapping; both are consumed by TestSolver via allPrologTestingTheoriesToRespectiveGoalsAndSolutions.

Author

Enrico

Properties

Link copied to clipboard

a(A) :- b(A), d(Z). b(B) :- c(B), d(W). d(_). c(1).

Link copied to clipboard

Catch primitive request goals and respective expected Solutions

Link copied to clipboard

A database that implements custom "range" to generate lists; it should test backtracking functionality along with arithmetic

Link copied to clipboard

A database that implements custom "reverse" over lists; it should test backtracking functionality

Link copied to clipboard

A database containing the following rules:

Link copied to clipboard

Halt primitive request goals and respective expected Solutions

Link copied to clipboard

A database containing the following rules:

Link copied to clipboard

A database containing the following rules:

Link copied to clipboard

A database containing the following rules:

Link copied to clipboard

Notable simpleCutTheory request goals and respective expected Solutions

Link copied to clipboard

A database containing the following facts:

Link copied to clipboard

Notable simpleFactTheory request goals and respective expected Solutions

Functions

fun allPrologTestingTheoriesToRespectiveGoalsAndSolutions(callErrorSignature: Signature, nafErrorSignature: Signature, notErrorSignature: Signature): Map<Theory, List<Pair<Struct, List<Solution>>>>

Collection of all Prolog example (custom created and from Prolog Standard) databases and their respective callable goals with expected solutions

Link copied to clipboard

Call primitive request goals and respective expected Solutions