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

Unified Diff: chrome/browser/chromeos/extensions/external_filesystem_apitest.cc

Issue 10067021: Postpone setting up file handler's file permissions if handler is running lazy background page. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years, 8 months 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: chrome/browser/chromeos/extensions/external_filesystem_apitest.cc
diff --git a/chrome/browser/chromeos/extensions/external_filesystem_apitest.cc b/chrome/browser/chromeos/extensions/external_filesystem_apitest.cc
index 2f3aa93500b890d45c5880076e270069c36934f2..a5ee851d132a81b019dfa86b4c0875d8f38a07a8 100644
--- a/chrome/browser/chromeos/extensions/external_filesystem_apitest.cc
+++ b/chrome/browser/chromeos/extensions/external_filesystem_apitest.cc
@@ -11,6 +11,7 @@
#include "chrome/browser/extensions/extension_apitest.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/ui/browser.h"
+#include "chrome/common/chrome_switches.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "webkit/fileapi/file_system_context.h"
#include "webkit/fileapi/file_system_mount_point_provider.h"
@@ -118,6 +119,11 @@ class FileSystemExtensionApiTest : public ExtensionApiTest {
virtual ~FileSystemExtensionApiTest() {}
+ void SetUpCommandLine(CommandLine* command_line) {
tbarzic 2012/04/13 02:58:30 I messed up indent here..
+ ExtensionApiTest::SetUpCommandLine(command_line);
+ command_line->AppendSwitch(switches::kEnableExperimentalExtensionApis);
+ }
+
// Adds a local mount point at at mount point /tmp.
void AddTmpMountPoint() {
fileapi::ExternalFileSystemMountPointProvider* provider =
@@ -191,6 +197,14 @@ IN_PROC_BROWSER_TEST_F(FileSystemExtensionApiTest, FileBrowserTest) {
"filebrowser_component", "read.html", kComponentFlags)) << message_;
}
+IN_PROC_BROWSER_TEST_F(FileSystemExtensionApiTest, FileBrowserTestLazy) {
+ AddTmpMountPoint();
+ ASSERT_TRUE(RunExtensionTest("filesystem_handler_lazy_background"))
+ << message_;
+ ASSERT_TRUE(RunExtensionSubtest(
+ "filebrowser_component", "read.html", kComponentFlags)) << message_;
+}
+
IN_PROC_BROWSER_TEST_F(FileSystemExtensionApiTest, FileBrowserTestWrite) {
AddTmpMountPoint();
ASSERT_TRUE(RunExtensionTest("filesystem_handler_write")) << message_;

Powered by Google App Engine
This is Rietveld 408576698