Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2030)

Unified Diff: base/test/test_file_util.h

Issue 75533002: Fix chrome upload with content uri (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 7 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: base/test/test_file_util.h
diff --git a/base/test/test_file_util.h b/base/test/test_file_util.h
index cf20221d76e7c09a930117efe6ac4f1a757f63a0..656babd8d78c114160b47a2ce7364cd404673014 100644
--- a/base/test/test_file_util.h
+++ b/base/test/test_file_util.h
@@ -12,6 +12,11 @@
#include "base/compiler_specific.h"
#include "base/files/file_path.h"
+#if defined(OS_ANDROID)
+#include <jni.h>
+#include "base/basictypes.h"
+#endif
+
namespace base {
class FilePath;
@@ -58,6 +63,15 @@ base::FilePath WStringAsFilePath(const std::wstring& path);
bool MakeFileUnreadable(const base::FilePath& path) WARN_UNUSED_RESULT;
bool MakeFileUnwritable(const base::FilePath& path) WARN_UNUSED_RESULT;
+#if defined(OS_ANDROID)
+// Register the ContentUriTestUrils JNI bindings.
+bool RegisterContentUriTestUtils(JNIEnv* env);
+
+// Insert an image file into the MediaStore, and retrieve the content URI for
+// testing purpose.
+base::FilePath InsertImageIntoMediaStore(const base::FilePath& path);
+#endif // defined(OS_ANDROID)
+
// Saves the current permissions for a path, and restores it on destruction.
class PermissionRestorer {
public:

Powered by Google App Engine
This is Rietveld 408576698