Embedded Testing Suites

At Prairie.Code() I provided an example embedded project to demonstrate test driven development as part of an Arduino workshop. The example I gave used the Unity testing framework, but there are several others and they're worth exploring.



I love Unity for its compactness, and how easy it is to use. It's small enough to include the complete source in your project without bloating it. The examples in my presentations were all written with Unity.

The site ThrowTheSwitch.org is also generally fun reading if you enjoy embedded development. The authors seem like they really enjoy their work, and want to make embedded development easy and fun for everyone.

Google Test


This is a full-featured testing and mocking suite. It's fairly large, but it has a lot of advanced testing and mocking features that make working on complex projects easier. This is without a doubt my goto test framework when I am writing C and C++ code. It also intgrates well with common IDEs and Continuous Integration systems.



This library is a good half way point between Unity and Google Test. It installs as a separate library on your system. It is intended to mesh well with Autotools builds, but it is easy to integrate into any build. For a pure C project, this is rapidly becoming my favorite testing suite. It has an easy to follow syntax, good support for complicated test suites, and nice output for test failures.


Part of the Boost library for C++, the Test library gets lots of happy reviews from users. I haven't personally used it, but like most C++ developers I really like the Boost libraries in general. Even if you don't use the Test library, you should look at Boost for all of the great libraries that can make your work easier and more fun.