From 067e8a0725137e9286a0b33474db21354d3699bd Mon Sep 17 00:00:00 2001 From: Mark Salyzyn Date: Wed, 24 May 2017 15:24:55 -0700 Subject: [PATCH] liblog: test: CTS: enoent does not qualify Eliminate liblog@enoent CTS test as it is bypassed on "user" builds in commit "liblog: test: enoent requires userdebug or eng to run". This prevents time wasted running a test that bypasses during CTS. Test: CtsLiblogTestCases_list --gtest_list_tests | (grep enoent && echo FAILED) Bug: 62030441 Change-Id: Ia440db3e74dacdc5c311c640aab3a11844cc195a --- liblog/tests/liblog_test.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/liblog/tests/liblog_test.cpp b/liblog/tests/liblog_test.cpp index 71f74abb1..46ec5ef64 100644 --- a/liblog/tests/liblog_test.cpp +++ b/liblog/tests/liblog_test.cpp @@ -1720,6 +1720,7 @@ TEST(liblog, is_loggable) { // Kills logd and toss all collected data, equivalent to logcat -b all -c, // except we also return errors to the logging callers. #ifdef USING_LOGGER_DEFAULT +#ifdef __ANDROID__ #ifdef TEST_PREFIX // helper to liblog.enoent to count end-to-end matching logging messages. static int count_matching_ts(log_time ts) { @@ -1832,7 +1833,8 @@ TEST(liblog, enoent) { GTEST_LOG_(INFO) << "This test does nothing.\n"; #endif } -#endif // USING_LOCAL_LOGD +#endif // __ANDROID__ +#endif // USING_LOGGER_DEFAULT // Below this point we run risks of setuid(AID_SYSTEM) which may affect others.