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

Unified Diff: chrome/test/live_sync/live_sessions_sync_test.h

Issue 6465005: [Sync] Initial support for encrypting any datatype (no UI hookup yet). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Comments. Rest of unit tests. Created 9 years, 10 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/test/live_sync/live_sessions_sync_test.h
diff --git a/chrome/test/live_sync/live_sessions_sync_test.h b/chrome/test/live_sync/live_sessions_sync_test.h
index e081ad7c8aaca1bd8aaf69a1d85495e3ca3fcf20..38a414d18ad3cf351cca4a6044c5321a6ebdb15a 100644
--- a/chrome/test/live_sync/live_sessions_sync_test.h
+++ b/chrome/test/live_sync/live_sessions_sync_test.h
@@ -16,6 +16,8 @@
#include "chrome/browser/sessions/base_session_service.h"
#include "chrome/browser/sessions/session_service_test_helper.h"
#include "chrome/browser/sessions/session_types.h"
+#include "chrome/browser/sync/profile_sync_service_harness.h"
+#include "chrome/browser/sync/syncable/nigori_util.h"
#include "chrome/test/live_sync/live_sync_test.h"
class GURL;
@@ -97,6 +99,16 @@ class LiveSessionsSyncTest : public LiveSyncTest {
// Sets up the TestSessionService helper and the new browser windows.
bool SetupClients();
+ // Encrypt sessions datatype.
+ bool EnableEncryption(int index) {
+ return GetClient(index)->EnableEncryptionForType(syncable::SESSIONS);
+ }
+
+ // Check if Sessions are encrypted.
+ bool IsEncrypted(int index) {
+ return GetClient(index)->IsTypeEncrypted(syncable::SESSIONS);
+ }
+
// Open a single tab and return the TabContents. TabContents must be checked
// to ensure the tab opened successsfully.
TabContents* OpenTab(int index, GURL url) WARN_UNUSED_RESULT;

Powered by Google App Engine
This is Rietveld 408576698