File indexing completed on 2025-10-14 08:02:34
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013 #include <boost/test/unit_test.hpp>
0014
0015 #include "Acts/ActsVersion.hpp"
0016
0017 #include <string_view>
0018
0019 BOOST_AUTO_TEST_CASE(Version) {
0020
0021 BOOST_CHECK_LT(0u, Acts::Version);
0022
0023
0024
0025 BOOST_CHECK_LE(0u, Acts::VersionMajor);
0026 BOOST_CHECK_LE(0u, Acts::VersionMinor);
0027 BOOST_CHECK_LE(0u, Acts::VersionPatch);
0028 }
0029
0030 BOOST_AUTO_TEST_CASE(CommitHash) {
0031
0032
0033 auto hash = Acts::CommitHash;
0034 auto hashShort = Acts::CommitHashShort;
0035 (void)hash;
0036 (void)hashShort;
0037 }
0038
0039 BOOST_AUTO_TEST_CASE(VersionInfo) {
0040
0041 auto headerInfo = Acts::VersionInfo::fromHeader();
0042 BOOST_CHECK_EQUAL(headerInfo.versionMajor, Acts::VersionMajor);
0043 BOOST_CHECK_EQUAL(headerInfo.versionMinor, Acts::VersionMinor);
0044 BOOST_CHECK_EQUAL(headerInfo.versionPatch, Acts::VersionPatch);
0045
0046
0047 auto libraryInfo = Acts::VersionInfo::fromLibrary();
0048 BOOST_CHECK_EQUAL(libraryInfo.versionMajor, Acts::VersionMajor);
0049 BOOST_CHECK_EQUAL(libraryInfo.versionMinor, Acts::VersionMinor);
0050 BOOST_CHECK_EQUAL(libraryInfo.versionPatch, Acts::VersionPatch);
0051 BOOST_CHECK(!libraryInfo.commitHash.has_value());
0052
0053
0054 BOOST_CHECK(libraryInfo == libraryInfo);
0055 }