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

Unified Diff: chrome/browser/chromeos/gdata/gdata_mock.h

Issue 9662041: Implement copy and move operations within the same remote file system. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 9 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/gdata/gdata_mock.h
===================================================================
--- chrome/browser/chromeos/gdata/gdata_mock.h (revision 126063)
+++ chrome/browser/chromeos/gdata/gdata_mock.h (working copy)
@@ -8,6 +8,8 @@
#define CHROME_BROWSER_CHROMEOS_GDATA_GDATA_MOCK_H_
#pragma once
+#include <string>
+
#include "base/platform_file.h"
#include "base/memory/scoped_ptr.h"
#include "chrome/browser/chromeos/gdata/gdata.h"
@@ -25,7 +27,7 @@
virtual ~MockDocumentsService();
// DocumentServiceInterface overrides.
- MOCK_METHOD1(Initialize, void(Profile*));
+ MOCK_METHOD1(Initialize, void(Profile* profile));
MOCK_METHOD0(CancelAll, void(void));
MOCK_METHOD1(Authenticate, void(const AuthStatusCallback& callback));
MOCK_METHOD2(GetDocuments, void(const GURL& feed_url,
@@ -35,6 +37,21 @@
MOCK_METHOD3(DownloadDocument, void(const GURL& content_url,
DocumentExportFormat format,
const DownloadActionCallback& callback));
+ MOCK_METHOD3(CopyDocument, void(const GURL& document_url,
+ const FilePath::StringType& new_name,
+ const GetDataCallback& callback));
+ MOCK_METHOD3(RenameResource, void(const GURL& resource_url,
+ const FilePath::StringType& new_name,
+ const EntryActionCallback& callback));
+ MOCK_METHOD3(AddResourceToDirectory,
+ void(const GURL& parent_content_url,
+ const GURL& resource_url,
+ const EntryActionCallback& callback));
+ MOCK_METHOD4(RemoveResourceFromDirectory,
+ void(const GURL& parent_content_url,
+ const GURL& resource_url,
+ const std::string& resource_id,
+ const EntryActionCallback& callback));
MOCK_METHOD3(CreateDirectory,
void(const GURL& parent_content_url,
const FilePath::StringType& directory_name,
@@ -70,6 +87,28 @@
const DownloadActionCallback& callback);
// Will call |callback| with HTTP_SUCCESS and the current value of
+ // |document_data_|.
+ void CopyDocumentStub(const GURL& document_url,
+ const FilePath::StringType& new_name,
+ const GetDataCallback& callback);
+
+ // Will call |callback| with HTTP_SUCCESS and the |document_url|.
+ void RenameResourceStub(const GURL& document_url,
+ const FilePath::StringType& new_name,
+ const EntryActionCallback& callback);
+
+ // Will call |callback| with HTTP_SUCCESS and the |resource_url|.
+ void AddResourceToDirectoryStub(const GURL& parent_content_url,
+ const GURL& resource_url,
+ const EntryActionCallback& callback);
+
+ // Will call |callback| with HTTP_SUCCESS and the |resource_url|.
+ void RemoveResourceFromDirectoryStub(const GURL& parent_content_url,
+ const GURL& resource_url,
+ const std::string& resource_id,
+ const EntryActionCallback& callback);
+
+ // Will call |callback| with HTTP_SUCCESS and the current value of
// |directory_data_|.
void CreateDirectoryStub(const GURL& parent_content_url,
const FilePath::StringType& directory_name,
@@ -94,6 +133,9 @@
// Feed data to be returned from CreateDirectory.
scoped_ptr<base::Value> directory_data_;
+
+ // Feed data to be returned from CopyDocument.
+ scoped_ptr<base::Value> document_data_;
};
} // namespace gdata

Powered by Google App Engine
This is Rietveld 408576698