mirror of
https://github.com/google/googletest.git
synced 2025-12-06 08:46:50 +08:00
Compare commits
2 Commits
cef5e9ca72
...
282de45a49
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
282de45a49 | ||
|
|
409017ae98 |
1
.gitignore
vendored
1
.gitignore
vendored
@ -87,3 +87,4 @@ googlemock/gtest
|
||||
/CMakeCache.txt
|
||||
/ALL_BUILD.vcxproj.filters
|
||||
/ALL_BUILD.vcxproj
|
||||
_codeql_*
|
||||
|
||||
@ -561,6 +561,15 @@ GTEST_API_ TestInfo* MakeAndRegisterTestInfo(
|
||||
TypeId fixture_class_id, SetUpTestSuiteFunc set_up_tc,
|
||||
TearDownTestSuiteFunc tear_down_tc, TestFactoryBase* factory);
|
||||
|
||||
// Backward-compatible overload for ABI compatibility with v1.14.0 and earlier.
|
||||
// This version takes const char* instead of std::string to avoid ABI issues
|
||||
// when passing std::string by value across library boundaries.
|
||||
GTEST_API_ TestInfo* MakeAndRegisterTestInfo(
|
||||
const char* test_suite_name, const char* name, const char* type_param,
|
||||
const char* value_param, CodeLocation code_location,
|
||||
TypeId fixture_class_id, SetUpTestSuiteFunc set_up_tc,
|
||||
TearDownTestSuiteFunc tear_down_tc, TestFactoryBase* factory);
|
||||
|
||||
// If *pstr starts with the given prefix, modifies *pstr to be right
|
||||
// past the prefix and returns true; otherwise leaves *pstr unchanged
|
||||
// and returns false. None of pstr, *pstr, and prefix can be NULL.
|
||||
|
||||
@ -2829,6 +2829,19 @@ TestInfo* MakeAndRegisterTestInfo(
|
||||
return test_info;
|
||||
}
|
||||
|
||||
// Backward-compatible overload for ABI compatibility with v1.14.0 and earlier.
|
||||
TestInfo* MakeAndRegisterTestInfo(
|
||||
const char* test_suite_name, const char* name, const char* type_param,
|
||||
const char* value_param, CodeLocation code_location,
|
||||
TypeId fixture_class_id, SetUpTestSuiteFunc set_up_tc,
|
||||
TearDownTestSuiteFunc tear_down_tc, TestFactoryBase* factory) {
|
||||
// Forward to the std::string version
|
||||
return MakeAndRegisterTestInfo(std::string(test_suite_name), name, type_param,
|
||||
value_param, std::move(code_location),
|
||||
fixture_class_id, set_up_tc, tear_down_tc,
|
||||
factory);
|
||||
}
|
||||
|
||||
void ReportInvalidTestSuiteType(const char* test_suite_name,
|
||||
const CodeLocation& code_location) {
|
||||
Message errors;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user