Paul Donald 3f1f75bf48 test/unit: spell fixes 3 months ago
..
misc 4b10338c23 test/misc/code: removed trailing spaces 1 year ago
mkinclude 3724400d6e test Adding test configuration starting point 9 years ago
mod_httpapitest 3764c79c21 test/mod_httpapitest: removed trailing spaces 1 year ago
travis 3ebec4db10 test: updated the link to wiki site 2 years ago
unit 3f1f75bf48 test/unit: spell fixes 3 months ago
README.md 3724400d6e test Adding test configuration starting point 9 years ago

README.md

Test directory

Modules

Note: Under development (2016-06-03 OEJ)

Modules found here test APIs in other modules or are just created for testing, not for production use. In order to use the existing build system, each module needs a directory named mod_something in test.

Module testing

Each module needs a subdirectory called "test" with a test configuration and a Makefile.

A typical test script load the htable module and execute tests in the [event:htable_init] event route when starting. Typically, if a test fails, it runs abort() from the cfg_utils module to abort the process.

Targets of the test makefile:

- "test":   Test syntax with "kamailio -c"
- "all":    Run full test

Ideas: We may need a way to exit kamailio from inside without dumping a core file, but simply stopping execution and returning different return values to the shell. That way a test config can run for a limited amount of time or until a test fails. We can also stop on an external action, like a RPC request calling the same function.