c-convey icon indicating copy to clipboard operation
c-convey copied to clipboard

Convey testing framework for C.

C Convey Testing Framework

image:https://img.shields.io/badge/license-MIT-blue.svg[MIT License] image:https://img.shields.io/travis/gdamore/c-convey/master.svg?label=linux[Linux Status,link="https://travis-ci.org/gdamore/c-convey"] image:https://img.shields.io/appveyor/ci/gdamore/c-convey/master.svg?label=windows[Windows Status,link="https://ci.appveyor.com/project/gdamore/c-convey"] image:https://codecov.io/gh/gdamore/c-convey/branch/master/graph/badge.svg?label=coverage[Coverage,link="https://codecov.io/gh/gdamore/c-convey"] image:https://api.codacy.com/project/badge/Grade/c8689e4c1fea4f359183fbafcc2c699d["Codacy code quality", link="https://www.codacy.com/app/gdamore/c-convey?utm_source=github.com&utm_medium=referral&utm_content=gdamore/c-convey&utm_campaign=Badge_Grade"]

Inspired by the excellent https://github.com/smartystreets/goconvey/convey[GoConvey] framework, we have endeavored to create a similar framework for C programmers. This work was done in support of testing for a rewrite of https://github.com/nanomsg/nanomsg[nanomsg].

Easily Readable & Writeable Tests

image::screenshot_1.png[Convey Example]

Each Convey() block is run on its own, with the entire of Convey's in which it is nested restarted from the beginning. It also has support for clean Reset(), allowing test pre-conditions to be reset between each set.

Easily Readable Output

image::screenshot_2.png[Terminal Output]

The output is colored if yout terminal supports it, and tests can include extra debugging messages that will be inlined in the log in the appropriate calling order. (The test log is suppressed by default, and the above image shows a verbose, output, without the full debugging log.) The output above was generated by the demo.c program in this repository.