summaryrefslogtreecommitdiff
path: root/absl/debugging/failure_signal_handler_test.cc
diff options
context:
space:
mode:
authorGravatar Andy Getzendanner <durandal@google.com>2023-05-23 15:46:35 -0700
committerGravatar Copybara-Service <copybara-worker@google.com>2023-05-23 15:47:23 -0700
commit52747821480e6cadd8b27a0947af5d7933f9dfb4 (patch)
treecc42f6dc30fa8eca19047efd799c769ead59b6c4 /absl/debugging/failure_signal_handler_test.cc
parent79ca5d7aad63973c83a4962a66ab07cd623131ea (diff)
Migrate most RAW_LOGs and RAW_CHECKs in tests to regular LOG and CHECK.
The non-RAW_ versions provide better output but weren't available when most of these tests were written. There are just a couple spots where RAW_ is actually needed, e.g. signal handlers and malloc hooks. Also fix a couple warnings in layout_test.cc newly surfaced because the optimizer understands CHECK_XX differently than INTERNAL_CHECK. PiperOrigin-RevId: 534584435 Change-Id: I8d36fa809ffdaae5a3813064bd602cb8611c1613
Diffstat (limited to 'absl/debugging/failure_signal_handler_test.cc')
-rw-r--r--absl/debugging/failure_signal_handler_test.cc5
1 files changed, 3 insertions, 2 deletions
diff --git a/absl/debugging/failure_signal_handler_test.cc b/absl/debugging/failure_signal_handler_test.cc
index 6a62428b..72816a3e 100644
--- a/absl/debugging/failure_signal_handler_test.cc
+++ b/absl/debugging/failure_signal_handler_test.cc
@@ -22,11 +22,12 @@
#include <cstring>
#include <fstream>
-#include "gtest/gtest.h"
#include "gmock/gmock.h"
+#include "gtest/gtest.h"
#include "absl/base/internal/raw_logging.h"
#include "absl/debugging/stacktrace.h"
#include "absl/debugging/symbolize.h"
+#include "absl/log/check.h"
#include "absl/strings/match.h"
#include "absl/strings/str_cat.h"
@@ -87,7 +88,7 @@ std::string GetTmpDir() {
// This function runs in a fork()ed process on most systems.
void InstallHandlerWithWriteToFileAndRaise(const char* file, int signo) {
error_file = fopen(file, "w");
- ABSL_RAW_CHECK(error_file != nullptr, "Failed create error_file");
+ CHECK_NE(error_file, nullptr) << "Failed create error_file";
absl::FailureSignalHandlerOptions options;
options.writerfn = WriteToErrorFile;
absl::InstallFailureSignalHandler(options);