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

Side by Side Diff: chrome/browser/sync/test/integration/single_client_sessions_sync_test.cc

Issue 2345843003: [Sync] Merge //components/browser_sync into one directory. (Closed)
Patch Set: Address comment + rebase. Created 4 years, 3 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 unified diff | Download patch
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/macros.h" 5 #include "base/macros.h"
6 #include "base/test/histogram_tester.h" 6 #include "base/test/histogram_tester.h"
7 #include "chrome/browser/sessions/session_service.h" 7 #include "chrome/browser/sessions/session_service.h"
8 #include "chrome/browser/sync/test/integration/profile_sync_service_harness.h" 8 #include "chrome/browser/sync/test/integration/profile_sync_service_harness.h"
9 #include "chrome/browser/sync/test/integration/sessions_helper.h" 9 #include "chrome/browser/sync/test/integration/sessions_helper.h"
10 #include "chrome/browser/sync/test/integration/sync_integration_test_util.h" 10 #include "chrome/browser/sync/test/integration/sync_integration_test_util.h"
11 #include "chrome/browser/sync/test/integration/sync_test.h" 11 #include "chrome/browser/sync/test/integration/sync_test.h"
12 #include "chrome/browser/sync/test/integration/typed_urls_helper.h" 12 #include "chrome/browser/sync/test/integration/typed_urls_helper.h"
13 #include "chrome/common/url_constants.h" 13 #include "chrome/common/url_constants.h"
14 #include "components/browser_sync/browser/profile_sync_service.h" 14 #include "components/browser_sync/profile_sync_service.h"
15 #include "components/history/core/browser/history_types.h" 15 #include "components/history/core/browser/history_types.h"
16 #include "components/sessions/core/session_types.h" 16 #include "components/sessions/core/session_types.h"
17 #include "components/sync/base/time.h" 17 #include "components/sync/base/time.h"
18 #include "components/sync/test/fake_server/fake_server_verifier.h" 18 #include "components/sync/test/fake_server/fake_server_verifier.h"
19 #include "components/sync/test/fake_server/sessions_hierarchy.h" 19 #include "components/sync/test/fake_server/sessions_hierarchy.h"
20 20
21 using fake_server::SessionsHierarchy; 21 using fake_server::SessionsHierarchy;
22 using sessions_helper::CheckInitialState; 22 using sessions_helper::CheckInitialState;
23 using sessions_helper::GetLocalWindows; 23 using sessions_helper::GetLocalWindows;
24 using sessions_helper::GetSessionData; 24 using sessions_helper::GetSessionData;
(...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after
198 // Verify the cookie jar mismatch bool is set to false. 198 // Verify the cookie jar mismatch bool is set to false.
199 ASSERT_TRUE(GetFakeServer()->GetLastCommitMessage(&message)); 199 ASSERT_TRUE(GetFakeServer()->GetLastCommitMessage(&message));
200 ASSERT_FALSE(message.commit().config_params().cookie_jar_mismatch()); 200 ASSERT_FALSE(message.commit().config_params().cookie_jar_mismatch());
201 201
202 // Verify the histograms were recorded properly. 202 // Verify the histograms were recorded properly.
203 histogram_tester.ExpectTotalCount("Sync.CookieJarMatchOnNavigation", 2); 203 histogram_tester.ExpectTotalCount("Sync.CookieJarMatchOnNavigation", 2);
204 histogram_tester.ExpectBucketCount("Sync.CookieJarMatchOnNavigation", true, 204 histogram_tester.ExpectBucketCount("Sync.CookieJarMatchOnNavigation", true,
205 1); 205 1);
206 histogram_tester.ExpectUniqueSample("Sync.CookieJarEmptyOnMismatch", true, 1); 206 histogram_tester.ExpectUniqueSample("Sync.CookieJarEmptyOnMismatch", true, 1);
207 } 207 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698