team-charls / charls

CharLS, a C++ JPEG-LS library implementation
BSD 3-Clause "New" or "Revised" License
180 stars 74 forks source link

Replace Visual Studio C++ unit testing framework with a cross platform C++ unit testing framework #52

Open vbaderks opened 5 years ago

vbaderks commented 5 years ago

The initial V1.0 release of CharLS had its own unit test framework (in charlstest.exe)

Modern development environments come with support for C++ unit tests. CharLS start with Visual Studio C++ unit test framework as this was the only unit test framework with integrated unit test support. Recent versions of Visual Studio come with adapters to use all kind of unit tests, like google test, boost test, catch2, etc. These unit test frameworks are all cross-platform, while VS unit test framework is limited to Windows. By moving to a cross-platform, the unit test can be all moved to a single executable that integrates well and is usable on multiple platforms.

Note: which unit test framework to use is not yet decided.

malaterre commented 2 years ago

Currently, the closest unit test suite available in charls is:

$ test/charlstest -unittest

However:

  1. It never return EXIT_FAILURE (exception is caught)
  2. It requires extra binary data to be available in the source tree
barracuda156 commented 1 year ago

@malaterre Seems not to be able to run correctly: https://github.com/team-charls/charls/issues/281