lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


It occurs to me that I haven't shared this yet. It's quite similar to other
unit test frameworks. A few things that made me write it and like it:

1) Lua 5.1 module
2) Framework is a single file.
3) Define utility functions separate from and available to test functions.
4) Control the order that tests are run (by renaming functions).
5) ANSI (for conforming terminals) or HTML (for TextMate or e) output.
6) Sensible (to me) injection of functions while preserving global scope.
7) Rich set of assertions and custom error messages.
   (Including assertion for comparing tables of values.)

Enjoy (or not) as you like:
http://phrogz.net/lua/lunity.lua