Commit 13b6f76fc1d for nodejs
commit 13b6f76fc1d1e16d01e57b456cfaa851c2a96694
Author: Node.js GitHub Bot <github-bot@iojs.org>
Date: Mon Nov 16 19:58:45 2026 -0500
deps: update googletest to e882c36410197464e3429546e6a7d5e217bde51e
PR-URL: https://github.com/nodejs/node/pull/67477
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Gürgün Dayıoğlu <hey@gurgun.day>
diff --git a/deps/googletest/include/gtest/gtest.h b/deps/googletest/include/gtest/gtest.h
index 7c003c5d60e..28a7fa8fbc2 100644
--- a/deps/googletest/include/gtest/gtest.h
+++ b/deps/googletest/include/gtest/gtest.h
@@ -300,12 +300,12 @@ class GTEST_API_ [[nodiscard]] Test {
// global context (before or after invocation of RUN_ALL_TESTS and from
// SetUp/TearDown method of Environment objects registered with Google
// Test) will be output as attributes of the <testsuites> element.
- static void RecordProperty(const std::string& key, const std::string& value);
+ static void RecordProperty(std::string_view key, std::string_view value);
// We do not define a custom serialization except for values that can be
// converted to int64_t, but other values could be logged in this way.
template <typename T, std::enable_if_t<std::is_convertible<T, int64_t>::value,
bool> = true>
- static void RecordProperty(const std::string& key, const T& value) {
+ static void RecordProperty(std::string_view key, const T& value) {
RecordProperty(key, (Message() << value).GetString());
}
@@ -376,7 +376,7 @@ class [[nodiscard]] TestProperty {
// C'tor. TestProperty does NOT have a default constructor.
// Always use this constructor (with parameters) to create a
// TestProperty object.
- TestProperty(const std::string& a_key, const std::string& a_value)
+ TestProperty(std::string_view a_key, std::string_view a_value)
: key_(a_key), value_(a_value) {}
// Gets the user supplied key.
@@ -386,7 +386,7 @@ class [[nodiscard]] TestProperty {
const char* value() const { return value_.c_str(); }
// Sets a new value, overriding the one supplied in the constructor.
- void SetValue(const std::string& new_value) { value_ = new_value; }
+ void SetValue(std::string_view new_value) { value_ = new_value; }
private:
// The key supplied by the user.
@@ -1261,7 +1261,7 @@ class GTEST_API_ [[nodiscard]] UnitTest {
// from SetUpTestSuite or TearDownTestSuite, or to the global property set
// when invoked elsewhere. If the result already contains a property with
// the same key, the value will be updated.
- void RecordProperty(const std::string& key, const std::string& value);
+ void RecordProperty(std::string_view key, std::string_view value);
// Gets the i-th test suite among all the test suites. i can range from 0 to
// total_test_suite_count() - 1. If i is not in that range, returns NULL.
diff --git a/deps/googletest/include/gtest/internal/gtest-port.h b/deps/googletest/include/gtest/internal/gtest-port.h
index 3b2947b852e..081b2facdae 100644
--- a/deps/googletest/include/gtest/internal/gtest-port.h
+++ b/deps/googletest/include/gtest/internal/gtest-port.h
@@ -676,7 +676,7 @@ typedef struct _RTL_CRITICAL_SECTION GTEST_CRITICAL_SECTION;
#if defined(GTEST_OS_WINDOWS_MOBILE) || defined(GTEST_OS_WINDOWS_PHONE) || \
defined(GTEST_OS_WINDOWS_RT) || defined(GTEST_OS_WINDOWS_GAMES) || \
defined(GTEST_OS_ESP8266) || defined(GTEST_OS_XTENSA) || \
- defined(GTEST_OS_QURT) || !GTEST_HAS_FILE_SYSTEM
+ defined(GTEST_OS_QURT) || defined(__wasi__) || !GTEST_HAS_FILE_SYSTEM
#define GTEST_HAS_STREAM_REDIRECTION 0
#else
#define GTEST_HAS_STREAM_REDIRECTION 1
@@ -706,8 +706,9 @@ typedef struct _RTL_CRITICAL_SECTION GTEST_CRITICAL_SECTION;
// Created by default when Death tests are supported, but other platforms can
// use the Premature exit file without Death test support (e.g. for detecting
// crashes).
-#if GTEST_HAS_DEATH_TEST || \
- (defined(GTEST_OS_EMSCRIPTEN) && GTEST_HAS_FILE_SYSTEM)
+#if GTEST_HAS_DEATH_TEST || \
+ ((defined(GTEST_OS_EMSCRIPTEN) || defined(GTEST_OS_IOS)) && \
+ GTEST_HAS_FILE_SYSTEM)
#define GTEST_INTERNAL_HAS_PREMATURE_EXIT_FILE 1
#endif
diff --git a/deps/googletest/src/gtest.cc b/deps/googletest/src/gtest.cc
index d66756e88f5..88b478e8083 100644
--- a/deps/googletest/src/gtest.cc
+++ b/deps/googletest/src/gtest.cc
@@ -2565,7 +2565,7 @@ void Test::SetUp() {}
void Test::TearDown() {}
// Allows user supplied key value pairs to be recorded for later output.
-void Test::RecordProperty(const std::string& key, const std::string& value) {
+void Test::RecordProperty(std::string_view key, std::string_view value) {
UnitTest::GetInstance()->RecordProperty(key, value);
}
@@ -5528,8 +5528,7 @@ void UnitTest::AddTestPartResult(TestPartResult::Type result_type,
// from SetUpTestSuite or TearDownTestSuite, or to the global property set
// when invoked elsewhere. If the result already contains a property with
// the same key, the value will be updated.
-void UnitTest::RecordProperty(const std::string& key,
- const std::string& value) {
+void UnitTest::RecordProperty(std::string_view key, std::string_view value) {
impl_->RecordProperty(TestProperty(key, value));
}