Chromium Code Reviews| Index: base/android/path_utils_unittest.cc |
| diff --git a/base/android/path_utils_unittest.cc b/base/android/path_utils_unittest.cc |
| index 92728b5f6e0e6e6236644eb43363105777859f66..ede51144c0572837bc62ee6e91069b8e01bc5271 100644 |
| --- a/base/android/path_utils_unittest.cc |
| +++ b/base/android/path_utils_unittest.cc |
| @@ -4,6 +4,7 @@ |
| #include "base/android/path_utils.h" |
| #include "base/file_path.h" |
| +#include "base/file_util.h" |
| #include "testing/gtest/include/gtest/gtest.h" |
| @@ -38,8 +39,15 @@ TEST_F(PathUtilsTest, TestGetNativeLibraryDirectory) { |
| // org.chromium.native_test |
| FilePath path; |
| GetNativeLibraryDirectory(&path); |
| - EXPECT_STREQ("/data/data/org.chromium.native_test/lib", |
| - path.value().c_str()); |
| + // The exact location of the native library will depend on Android |
| + // implementation. We just check that there is at least one .so |
| + // in the returned directory. |
| + file_util::FileEnumerator enumerator( |
| + path, |
| + false, |
| + file_util::FileEnumerator::FILES, |
| + "*.so"); |
|
bulach
2012/11/21 12:04:48
maybe best to check that it contains at least libb
|
| + EXPECT_FALSE(enumerator.Next().empty()); |
| } |
| } // namespace android |