open-dis / open-dis-cpp

C++ implementation of the IEEE-1278.1 Distributed Interactive Simulation (DIS) application protocol v6 and v7
BSD 2-Clause "Simplified" License
90 stars 65 forks source link

Unit test resurrection #74

Closed wadehunk closed 1 year ago

wadehunk commented 1 year ago

Resurrected unit tests and re-wrote them using Catch2. This simplifies the test framework and uses a single header-only include file to remove outside dependencies on CppUnit. Should allow for easy addition of other tests in the future. Tests are optionally enabled using the BUILD_TESTS cmake variable (default OFF). Test results are uploaded to appveyor for reporting.

Closes #46

wadehunk commented 1 year ago

@leif81 As mentioned, this should bring the unit tests back up and running in the build system.

leif81 commented 1 year ago

Thank-you @wadehunk Will take a look shortly. On first look the 17k line catch2.hpp file is crashing my browser 😆

leif81 commented 1 year ago

This looks pretty great to me. Am really happy to see unit tests being resurrected 👍

I wasn't familiar with catch2 before seeing this PR, I don't have an opportunity to write a lot of C++ these days so have been a bit out of the loop on what is popular these days. I see on github the catch2 project seems very healthy (https://github.com/catchorg/Catch2).

I like that you've integrated the catch 2 unit tests results into the appveyor CI job. e.g. https://ci.appveyor.com/project/leif81/open-dis-cpp/build/tests

Great job