nancy.liao
2025-05-29 8d405b265285c368df2e9cf1c14acee7532e0ee7
test/functional/crack_test.cpp
@@ -1,3 +1,4 @@
#define BOOST_TEST_MODULE standard_license_test
#include <boost/test/unit_test.hpp>
@@ -9,7 +10,7 @@
#include <iostream>
#include "../../src/library/ini/SimpleIni.h"
#include "generate-license.h"
#include "../../src/library/base/FileUtils.hpp"
#include "../../src/library/base/file_utils.hpp"
namespace license {
namespace test {
@@ -17,6 +18,7 @@
using namespace license;
using namespace std;
//测试一个通用的许可证
/**
 * Test a generic license, passing a bad license number trough the api.
 * see projects/DEFAULT/include/licensecc/DEFAULT/licensecc_properties.h (magic should be 0)
@@ -30,7 +32,7 @@
   std::copy(licLocation.begin(), licLocation.end(), location.licenseData);
   // magic should be 0 for this build...
   CallerInformations callInfo{{0}, {0}, 42};
   const EVENT_TYPE result = acquire_license(&callInfo, &location, &license);
   const LCC_EVENT_TYPE result = acquire_license(&callInfo, &location, &license);
   BOOST_CHECK_EQUAL(result, LICENSE_CORRUPTED);
}