notcurses/tests/version.cpp
2020-10-10 20:33:23 -04:00

14 lines
434 B
C++

#include "main.h"
TEST_CASE("Version") {
auto nc_ = testing_notcurses();
REQUIRE(nullptr != nc_);
int major, minor, patch, tweak;
notcurses_version_components(&major, &minor, &patch, &tweak);
CHECK(0 == notcurses_stop(nc_));
CHECK(atoi(NOTCURSES_VERSION_MAJOR) == major);
CHECK(atoi(NOTCURSES_VERSION_MINOR) == minor);
CHECK(atoi(NOTCURSES_VERSION_PATCH) == patch);
CHECK(atoi(NOTCURSES_VERSION_TWEAK) == tweak);
}