cpp-terminal icon indicating copy to clipboard operation
cpp-terminal copied to clipboard

Unit testing

Open MCWertGaming opened this issue 4 years ago • 2 comments

The doctest.h file in the root of the repository claims to be gerated by cmake - but that's a lie. I would sugest to let it really be generated by cmake, or at least get updated every now and then. We are using 2.3.4, newest version is 2.4.5. I would remove the file and setup doctest as cmake sub-project.

Another solution would be moving to gtest (the unit testing framework, I usually use). It's basially the same but if I got it right, it can even test colors and stuff like that. I'll definietely test it a bit in terms of benefits for cpp-terminal and I understand, if you don't want to move yet. Do you know that testing framework at all?

MCWertGaming avatar Feb 13 '21 12:02 MCWertGaming

I just copied the doctest from upstream. That is the easiest way to get it working. I wouldn't worry about it too much.

certik avatar Feb 13 '21 16:02 certik

I quickly wanted to note, that the latest version of doctest is not compiling on windows, [an issue on that is open since 10 days but it's not fixed yet. But the owner of the repository already answered that issue with "I'm open to PRs". https://github.com/onqtam/doctest/issues/465 Maybe we shouldn't update it yet.

MCWertGaming avatar Feb 13 '21 18:02 MCWertGaming

Moved into #182.

MCWertGaming avatar Aug 22 '22 11:08 MCWertGaming