Loading storaged/Android.bp +3 −0 Original line number Diff line number Diff line Loading @@ -115,6 +115,9 @@ cc_test { static_libs: [ "libstoraged", ], test_suites: [ "general-tests", ], } // AIDL interface between storaged and framework.jar Loading storaged/tests/storaged_test.cpp +8 −0 Original line number Diff line number Diff line Loading @@ -25,6 +25,7 @@ #include <gtest/gtest.h> #include <aidl/android/hardware/health/IHealth.h> #include <healthhalutils/HealthHalUtils.h> #include <storaged.h> // data structures #include <storaged_utils.h> // functions to test Loading Loading @@ -249,6 +250,13 @@ TEST(storaged_test, disk_stats_monitor) { // testing if detect() will return the right value disk_stats_monitor dsm_detect{healthService}; ASSERT_TRUE(dsm_detect.enabled()); // Even if enabled(), healthService may not support disk stats. Check if it is supported. std::vector<aidl::android::hardware::health::DiskStats> halStats; if (healthService->getDiskStats(&halStats).getExceptionCode() == EX_UNSUPPORTED_OPERATION) { GTEST_SKIP(); } // feed monitor with constant perf data for io perf baseline // using constant perf is reasonable since the functionality of stream_stats // has already been tested Loading Loading
storaged/Android.bp +3 −0 Original line number Diff line number Diff line Loading @@ -115,6 +115,9 @@ cc_test { static_libs: [ "libstoraged", ], test_suites: [ "general-tests", ], } // AIDL interface between storaged and framework.jar Loading
storaged/tests/storaged_test.cpp +8 −0 Original line number Diff line number Diff line Loading @@ -25,6 +25,7 @@ #include <gtest/gtest.h> #include <aidl/android/hardware/health/IHealth.h> #include <healthhalutils/HealthHalUtils.h> #include <storaged.h> // data structures #include <storaged_utils.h> // functions to test Loading Loading @@ -249,6 +250,13 @@ TEST(storaged_test, disk_stats_monitor) { // testing if detect() will return the right value disk_stats_monitor dsm_detect{healthService}; ASSERT_TRUE(dsm_detect.enabled()); // Even if enabled(), healthService may not support disk stats. Check if it is supported. std::vector<aidl::android::hardware::health::DiskStats> halStats; if (healthService->getDiskStats(&halStats).getExceptionCode() == EX_UNSUPPORTED_OPERATION) { GTEST_SKIP(); } // feed monitor with constant perf data for io perf baseline // using constant perf is reasonable since the functionality of stream_stats // has already been tested Loading