The com.gigamonkeys.test-framework Reference Manual

Next: , Previous: , Up: (dir)   [Contents][Index]

The com.gigamonkeys.test-framework Reference Manual

This is the com.gigamonkeys.test-framework Reference Manual, version 1.0, generated automatically by Declt version 4.0 beta 2 "William Riker" on Thu Sep 15 05:41:26 2022 GMT+0.

Table of Contents


1 Systems

The main system appears first, followed by any subsystem dependency.


Previous: , Up: Systems   [Contents][Index]

1.1 com.gigamonkeys.test-framework

Simple unit test framework for Common Lisp

Maintainer

Peter Seibel <peter@gigamonkeys.com>

Author

Peter Seibel <peter@gigamonkeys.com>

License

BSD

Long Description
Version

1.0

Dependency

com.gigamonkeys.macro-utilities (system).

Source

com.gigamonkeys.test-framework.asd.

Child Components

2 Files

Files are sorted by type and then listed depth-first from the systems components trees.


Previous: , Up: Files   [Contents][Index]

2.1 Lisp


2.1.1 com.gigamonkeys.test-framework/com.gigamonkeys.test-framework.asd

Source

com.gigamonkeys.test-framework.asd.

Parent Component

com.gigamonkeys.test-framework (system).

ASDF Systems

com.gigamonkeys.test-framework.

Packages

com.gigamonkeys.test-system.


2.1.3 com.gigamonkeys.test-framework/test.lisp

Dependency

packages.lisp (file).

Source

com.gigamonkeys.test-framework.asd.

Parent Component

com.gigamonkeys.test-framework (system).

Public Interface
Internals

2.1.4 com.gigamonkeys.test-framework/tests.lisp

Dependencies
Source

com.gigamonkeys.test-framework.asd.

Parent Component

com.gigamonkeys.test-framework (system).


2.1.5 com.gigamonkeys.test-framework/test-tests.lisp

Dependencies
Source

com.gigamonkeys.test-framework.asd.

Parent Component

com.gigamonkeys.test-framework (system).

Internals

3 Packages

Packages are listed by definition order.


Next: , Previous: , Up: Packages   [Contents][Index]

3.1 com.gigamonkeys.test-tests

Source

packages.lisp.

Use List

common-lisp.

Internals

3.2 com.gigamonkeys.test

Source

packages.lisp.

Use List
  • com.gigamonkeys.macro-utilities.
  • common-lisp.
Public Interface
Internals

3.3 com.gigamonkeys.test-system

Source

com.gigamonkeys.test-framework.asd.

Use List
  • asdf/interface.
  • common-lisp.

4 Definitions

Definitions are sorted by export status, category, package, and then by lexicographic order.


Next: , Previous: , Up: Definitions   [Contents][Index]

4.1 Public Interface


Next: , Previous: , Up: Public Interface   [Contents][Index]

4.1.1 Special variables

Special Variable: *debug*

If true, then the Lisp debugger is invoked when an unexpected condition is signalled during testing. See also: *debug-on-fail*.

Package

com.gigamonkeys.test.

Source

test.lisp.

Special Variable: *debug-on-fail*

If true, then the Lisp debugger is invoked when a test fails. See also: *debug*.

Package

com.gigamonkeys.test.

Source

test.lisp.


4.1.2 Macros

Macro: check (&body forms)

Run each expression in ‘forms’ as a test case.

Package

com.gigamonkeys.test.

Source

test.lisp.

Macro: deftest (name parameters &body body)

Define a test function. Within a test function we can call other test functions or use ‘check’ to run individual test cases.

Package

com.gigamonkeys.test.

Source

test.lisp.

Macro: expect (condition-type form)

Pass iff a condition of the given type is signaled while executing form.

Package

com.gigamonkeys.test.

Source

test.lisp.

Macro: test (name &rest arguments)

Run a named test.

Package

com.gigamonkeys.test.

Source

test.lisp.

Macro: with-test-cases ((&rest parameters) test-form &rest test-cases)

Check a single test form with multple test cases.

Package

com.gigamonkeys.test.

Source

test.lisp.


4.1.3 Ordinary functions

Function: clear-package-tests (&key package)
Package

com.gigamonkeys.test.

Source

test.lisp.

Function: remove-test-function (symbol)
Package

com.gigamonkeys.test.

Source

test.lisp.

Function: test-package (&key print summary package)
Package

com.gigamonkeys.test.

Source

test.lisp.


4.1.4 Standalone methods

Method: print-object ((result test-fail) stream)
Source

test.lisp.


4.2 Internals


Next: , Previous: , Up: Internals   [Contents][Index]

4.2.1 Special variables

Special Variable: *report-passes*
Package

com.gigamonkeys.test.

Source

test.lisp.

Special Variable: *test-name*
Package

com.gigamonkeys.test.

Source

test.lisp.


4.2.2 Macros

Macro: eval-with-values (form)

Transform ‘form’ into an equivalent form to be evaluated and an alist of sub-forms and their values.

Package

com.gigamonkeys.test.

Source

test.lisp.

Macro: ignore-results (&body body)

Ignore results signaled in ‘body’. This is, at the very least, handy when writing tests for the test framework itself.

Package

com.gigamonkeys.test.

Source

test.lisp.

Macro: with-test-results ((&key print summary) &body body)

Collect test results signaled in ‘body’ (except from forms in the dynamic extent of an IGNORE-RESULTS.

Package

com.gigamonkeys.test.

Source

test.lisp.


Next: , Previous: , Up: Internals   [Contents][Index]

4.2.3 Ordinary functions

Function: function-name-p (name)
Package

com.gigamonkeys.test.

Source

test.lisp.

Function: ignore-result (&optional condition)
Package

com.gigamonkeys.test.

Source

test.lisp.

Function: listify (thing)
Package

com.gigamonkeys.test.

Source

test.lisp.

Function: print-result-summary (ok passes failures aborts)
Package

com.gigamonkeys.test.

Source

test.lisp.

Function: proceed (&optional condition)
Package

com.gigamonkeys.test.

Source

test.lisp.

Function: process (sexp vars)
Package

com.gigamonkeys.test.

Source

test.lisp.

Function: report-abort (message)
Package

com.gigamonkeys.test.

Source

test.lisp.

Function: report-result (result form sub-forms)

Report the results of a single test case. Called by ‘check’.

Package

com.gigamonkeys.test.

Source

test.lisp.

Function: test-function (symbol)
Package

com.gigamonkeys.test.

Source

test.lisp.


Next: , Previous: , Up: Internals   [Contents][Index]

4.2.4 Generic functions

Generic Reader: form (condition)
Package

com.gigamonkeys.test.

Methods
Reader Method: form ((condition test-result))
Source

test.lisp.

Target Slot

form.

Generic Reader: name (condition)
Package

com.gigamonkeys.test.

Methods
Reader Method: name ((condition test-result))
Source

test.lisp.

Target Slot

name.

Generic Function: print-result (result)
Package

com.gigamonkeys.test.

Source

test.lisp.

Methods
Method: print-result ((result test-fail))
Method: print-result ((result test-result))
Generic Function: process-for-op (op sexp vars)

Define special processing for macros and
special operators which would otherwise be opaque. It is important to preserve the proper evaluation of the subforms.

Package

com.gigamonkeys.test.

Source

test.lisp.

Methods
Method: process-for-op ((op (eql if)) sexp vars)
Method: process-for-op (op sexp vars)
Generic Function: report-unexpected-error (error)
Package

com.gigamonkeys.test.

Source

test.lisp.

Methods
Method: report-unexpected-error ((error error))
Method: report-unexpected-error ((error cell-error))
Method: report-unexpected-error :around (error)
Generic Reader: result (condition)
Package

com.gigamonkeys.test.

Methods
Reader Method: result ((condition test-result))
Source

test.lisp.

Target Slot

result.

Generic Function: run-test (thing &rest arguments)
Package

com.gigamonkeys.test.

Source

test.lisp.

Methods
Method: run-test ((name symbol) &rest arguments)
Generic Reader: sub-forms (condition)
Package

com.gigamonkeys.test.

Methods
Reader Method: sub-forms ((condition test-result))
Source

test.lisp.

Target Slot

sub-forms.


Previous: , Up: Internals   [Contents][Index]

4.2.5 Conditions

Condition: foo-condition
Package

com.gigamonkeys.test-tests.

Source

test-tests.lisp.

Direct superclasses

condition.

Condition: foo-error
Package

com.gigamonkeys.test-tests.

Source

test-tests.lisp.

Direct superclasses

error.

Condition: test-abort
Package

com.gigamonkeys.test.

Source

test.lisp.

Direct superclasses

test-result.

Condition: test-fail
Package

com.gigamonkeys.test.

Source

test.lisp.

Direct superclasses

test-result.

Direct methods
Condition: test-pass
Package

com.gigamonkeys.test.

Source

test.lisp.

Direct superclasses

test-result.

Condition: test-result
Package

com.gigamonkeys.test.

Source

test.lisp.

Direct superclasses

condition.

Direct subclasses
Direct methods
Direct slots
Slot: result
Initargs

:result

Readers

result.

Writers

This slot is read-only.

Slot: name
Initargs

:name

Readers

name.

Writers

This slot is read-only.

Slot: form
Initargs

:form

Readers

form.

Writers

This slot is read-only.

Slot: sub-forms
Initargs

:sub-forms

Readers

sub-forms.

Writers

This slot is read-only.


Appendix A Indexes


Next: , Previous: , Up: Indexes   [Contents][Index]

A.1 Concepts


Next: , Previous: , Up: Indexes   [Contents][Index]

A.2 Functions

Jump to:   C   D   E   F   G   I   L   M   N   P   R   S   T   W  
Index Entry  Section

C
check: Public macros
clear-package-tests: Public ordinary functions

D
deftest: Public macros

E
eval-with-values: Private macros
expect: Public macros

F
form: Private generic functions
form: Private generic functions
Function, clear-package-tests: Public ordinary functions
Function, function-name-p: Private ordinary functions
Function, ignore-result: Private ordinary functions
Function, listify: Private ordinary functions
Function, print-result-summary: Private ordinary functions
Function, proceed: Private ordinary functions
Function, process: Private ordinary functions
Function, remove-test-function: Public ordinary functions
Function, report-abort: Private ordinary functions
Function, report-result: Private ordinary functions
Function, test-function: Private ordinary functions
Function, test-package: Public ordinary functions
function-name-p: Private ordinary functions

G
Generic Function, form: Private generic functions
Generic Function, name: Private generic functions
Generic Function, print-result: Private generic functions
Generic Function, process-for-op: Private generic functions
Generic Function, report-unexpected-error: Private generic functions
Generic Function, result: Private generic functions
Generic Function, run-test: Private generic functions
Generic Function, sub-forms: Private generic functions

I
ignore-result: Private ordinary functions
ignore-results: Private macros

L
listify: Private ordinary functions

M
Macro, check: Public macros
Macro, deftest: Public macros
Macro, eval-with-values: Private macros
Macro, expect: Public macros
Macro, ignore-results: Private macros
Macro, test: Public macros
Macro, with-test-cases: Public macros
Macro, with-test-results: Private macros
Method, form: Private generic functions
Method, name: Private generic functions
Method, print-object: Public standalone methods
Method, print-result: Private generic functions
Method, print-result: Private generic functions
Method, process-for-op: Private generic functions
Method, process-for-op: Private generic functions
Method, report-unexpected-error: Private generic functions
Method, report-unexpected-error: Private generic functions
Method, report-unexpected-error: Private generic functions
Method, result: Private generic functions
Method, run-test: Private generic functions
Method, sub-forms: Private generic functions

N
name: Private generic functions
name: Private generic functions

P
print-object: Public standalone methods
print-result: Private generic functions
print-result: Private generic functions
print-result: Private generic functions
print-result-summary: Private ordinary functions
proceed: Private ordinary functions
process: Private ordinary functions
process-for-op: Private generic functions
process-for-op: Private generic functions
process-for-op: Private generic functions

R
remove-test-function: Public ordinary functions
report-abort: Private ordinary functions
report-result: Private ordinary functions
report-unexpected-error: Private generic functions
report-unexpected-error: Private generic functions
report-unexpected-error: Private generic functions
report-unexpected-error: Private generic functions
result: Private generic functions
result: Private generic functions
run-test: Private generic functions
run-test: Private generic functions

S
sub-forms: Private generic functions
sub-forms: Private generic functions

T
test: Public macros
test-function: Private ordinary functions
test-package: Public ordinary functions

W
with-test-cases: Public macros
with-test-results: Private macros

Jump to:   C   D   E   F   G   I   L   M   N   P   R   S   T   W  

Previous: , Up: Indexes   [Contents][Index]

A.4 Data types

Jump to:   C   F   P   S   T  
Index Entry  Section

C
com.gigamonkeys.test: The com․gigamonkeys․test package
com.gigamonkeys.test-framework: The com․gigamonkeys․test-framework system
com.gigamonkeys.test-framework.asd: The com․gigamonkeys․test-framework/com․gigamonkeys․test-framework․asd file
com.gigamonkeys.test-system: The com․gigamonkeys․test-system package
com.gigamonkeys.test-tests: The com․gigamonkeys․test-tests package
Condition, foo-condition: Private conditions
Condition, foo-error: Private conditions
Condition, test-abort: Private conditions
Condition, test-fail: Private conditions
Condition, test-pass: Private conditions
Condition, test-result: Private conditions

F
File, com.gigamonkeys.test-framework.asd: The com․gigamonkeys․test-framework/com․gigamonkeys․test-framework․asd file
File, packages.lisp: The com․gigamonkeys․test-framework/packages․lisp file
File, test-tests.lisp: The com․gigamonkeys․test-framework/test-tests․lisp file
File, test.lisp: The com․gigamonkeys․test-framework/test․lisp file
File, tests.lisp: The com․gigamonkeys․test-framework/tests․lisp file
foo-condition: Private conditions
foo-error: Private conditions

P
Package, com.gigamonkeys.test: The com․gigamonkeys․test package
Package, com.gigamonkeys.test-system: The com․gigamonkeys․test-system package
Package, com.gigamonkeys.test-tests: The com․gigamonkeys․test-tests package
packages.lisp: The com․gigamonkeys․test-framework/packages․lisp file

S
System, com.gigamonkeys.test-framework: The com․gigamonkeys․test-framework system

T
test-abort: Private conditions
test-fail: Private conditions
test-pass: Private conditions
test-result: Private conditions
test-tests.lisp: The com․gigamonkeys․test-framework/test-tests․lisp file
test.lisp: The com․gigamonkeys․test-framework/test․lisp file
tests.lisp: The com․gigamonkeys․test-framework/tests․lisp file

Jump to:   C   F   P   S   T