LuaRocks.org had a security incident in September 2026. Read the incident report.

doccotest

Doctest for Lua commented with Docco

$ luarocks install doccotest

The doccotest tool is a port of Python's doctest to the Lua programming
language. It runs tests defined within code comments and compares their
output with a reference one, given also within code comments.

doccotest is designed to work on source code written in Lua, and commented
in markdown. The documentation for the code can be generated using docco or
locco, and embeds the tests and their expected results.

Versions

0.3-111 years ago244 downloads
0.2-211 years ago79 downloads
0.2-111 years ago(revision: 4)1,420 downloads
0.1-211 years ago200 downloads
0.1-111 years ago79 downloads

Dependencies

i18n >= 0
lua >= 5.1
luacov >= 0.7
Rings >= 1
serpent >= 0

Labels

Manifests