EEVblog Electronics Community Forum
Products => Computers => Programming => Topic started by: cedric! on May 28, 2020, 02:17:02 pm
-
Hi All,
I've made a workflow to unit test C code for an AtMega32a. I've used a combination of the C test framework "unity"[1] and the AVR simulator "simavr"[2]. After I write the C code, I push it to a Gitlab server. The Gitlab server downloads and runs a docker container, installs gccavr, simavr to it, compiles the C code, and then runs the code in Simavr. Simavr pipes the messages from unity from the serial port to the console. When the tests are complete, the gitlab server sends me an e-mail with the results.
[1] http://www.throwtheswitch.org/unity (http://www.throwtheswitch.org/unity)
[2] https://github.com/buserror/simavr (https://github.com/buserror/simavr)
Now I would like to do the same, but this time with C++ code. I'm therefore looking for a C++ test suite that:
a) Is written in C++, or can be called from C++ code
b) Runs on an AVR
c) Can send it's messages to the serial port. (So I can run the code also in a real AtMega32a connected to a serial port of my PC)
Do you know of such a suite?
PS, I've also posted this question in the micro controller section, I'm unsure if this is the best place to ask this.
Cheers,
Cedric
-
CppUTest is similar to Unity but does C++. And C.
https://cpputest.github.io/