summaryrefslogtreecommitdiffstats
path: root/base/logging_test.cpp
diff options
context:
space:
mode:
authorDan Albert <danalbert@google.com>2015-03-27 11:20:14 -0700
committerDan Albert <danalbert@google.com>2015-04-03 16:22:39 -0700
commitb547c85b5b9d7fc565e47a5d0c734c3a66af242a (patch)
tree1e9490de3134c6383da548f15186ae9f13ea5b1b /base/logging_test.cpp
parentea975880112c27293800ede36e0323ff2a7b9322 (diff)
downloadsystem_core-b547c85b5b9d7fc565e47a5d0c734c3a66af242a.tar.gz
system_core-b547c85b5b9d7fc565e47a5d0c734c3a66af242a.tar.bz2
system_core-b547c85b5b9d7fc565e47a5d0c734c3a66af242a.zip
Support arbitrary loggers.
While the defaults (logd or stderr) make sense for most use cases, there are places that can only log to the kernel, or need to log to a file, etc. Allow the user to pass in an arbitrary logging object, and provide LogdLogger and StderrLogger as defaults. Change-Id: I62368acc795ff313242bb205d65017404bf64e88
Diffstat (limited to 'base/logging_test.cpp')
-rw-r--r--base/logging_test.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/base/logging_test.cpp b/base/logging_test.cpp
index 0a03e38ef..d947c1d9f 100644
--- a/base/logging_test.cpp
+++ b/base/logging_test.cpp
@@ -61,7 +61,7 @@ class CapturedStderr {
int old_stderr_;
};
-HOST_TEST(logging, CHECK) {
+TEST(logging, CHECK) {
ASSERT_DEATH(CHECK(false), "Check failed: false ");
CHECK(true);
@@ -82,7 +82,7 @@ std::string make_log_pattern(android::base::LogSeverity severity,
log_char, message);
}
-HOST_TEST(logging, LOG) {
+TEST(logging, LOG) {
ASSERT_DEATH(LOG(FATAL) << "foobar", "foobar");
{
@@ -136,7 +136,7 @@ HOST_TEST(logging, LOG) {
}
}
-HOST_TEST(logging, PLOG) {
+TEST(logging, PLOG) {
{
CapturedStderr cap;
errno = ENOENT;
@@ -152,7 +152,7 @@ HOST_TEST(logging, PLOG) {
}
}
-HOST_TEST(logging, UNIMPLEMENTED) {
+TEST(logging, UNIMPLEMENTED) {
{
CapturedStderr cap;
errno = ENOENT;