diff options
-rw-r--r-- | fs_mgr/libsnapshot/snapshot_test.cpp | 4 | ||||
-rw-r--r-- | fs_mgr/libsnapshot/vts_ota_config_test.cpp | 7 | ||||
-rw-r--r-- | fs_mgr/tests/vts_fs_test.cpp | 4 |
3 files changed, 13 insertions, 2 deletions
diff --git a/fs_mgr/libsnapshot/snapshot_test.cpp b/fs_mgr/libsnapshot/snapshot_test.cpp index 6a348b4e5..c145da718 100644 --- a/fs_mgr/libsnapshot/snapshot_test.cpp +++ b/fs_mgr/libsnapshot/snapshot_test.cpp @@ -2755,6 +2755,10 @@ bool IsDaemonRequired() { return false; } + if (!IsCompressionEnabled()) { + return false; + } + const std::string UNKNOWN = "unknown"; const std::string vendor_release = android::base::GetProperty("ro.vendor.build.version.release_or_codename", UNKNOWN); diff --git a/fs_mgr/libsnapshot/vts_ota_config_test.cpp b/fs_mgr/libsnapshot/vts_ota_config_test.cpp index afc2d81a4..02bcc3438 100644 --- a/fs_mgr/libsnapshot/vts_ota_config_test.cpp +++ b/fs_mgr/libsnapshot/vts_ota_config_test.cpp @@ -17,7 +17,14 @@ #include <android-base/properties.h> #include <gtest/gtest.h> +static int GetVsrLevel() { + return android::base::GetIntProperty("ro.vendor.api_level", -1); +} + TEST(VAB, Enabled) { ASSERT_TRUE(android::base::GetBoolProperty("ro.virtual_ab.enabled", false)); + if (GetVsrLevel() < __ANDROID_API_T__) { + GTEST_SKIP(); + } ASSERT_TRUE(android::base::GetBoolProperty("ro.virtual_ab.userspace.snapshots.enabled", false)); } diff --git a/fs_mgr/tests/vts_fs_test.cpp b/fs_mgr/tests/vts_fs_test.cpp index aac2cfd9b..ae8e45992 100644 --- a/fs_mgr/tests/vts_fs_test.cpp +++ b/fs_mgr/tests/vts_fs_test.cpp @@ -28,8 +28,8 @@ static int GetVsrLevel() { } TEST(fs, ErofsSupported) { - // S and higher for this test. - if (GetVsrLevel() < __ANDROID_API_S__) { + // T-launch GKI kernels and higher must support EROFS. + if (GetVsrLevel() < __ANDROID_API_T__) { GTEST_SKIP(); } |