| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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/memory/scoped_vector.h" | 5 #include "base/memory/scoped_vector.h" |
| 6 #include "chrome/browser/sessions/session_service.h" | 6 #include "chrome/browser/sessions/session_service.h" |
| 7 #include "chrome/browser/sync/profile_sync_service_harness.h" | 7 #include "chrome/browser/sync/profile_sync_service_harness.h" |
| 8 #include "chrome/browser/sync/sessions/session_state.h" | 8 #include "chrome/browser/sync/test/integration/sessions_helper.h" |
| 9 #include "chrome/browser/sync/test/integration/sync_test.h" | 9 #include "chrome/browser/sync/test/integration/sync_test.h" |
| 10 #include "chrome/browser/sync/test/integration/sessions_helper.h" | 10 #include "sync/sessions/session_state.h" |
| 11 | 11 |
| 12 using sessions_helper::CheckInitialState; | 12 using sessions_helper::CheckInitialState; |
| 13 using sessions_helper::DeleteForeignSession; | 13 using sessions_helper::DeleteForeignSession; |
| 14 using sessions_helper::GetLocalWindows; | 14 using sessions_helper::GetLocalWindows; |
| 15 using sessions_helper::GetSessionData; | 15 using sessions_helper::GetSessionData; |
| 16 using sessions_helper::OpenTabAndGetLocalWindows; | 16 using sessions_helper::OpenTabAndGetLocalWindows; |
| 17 using sessions_helper::ScopedWindowMap; | 17 using sessions_helper::ScopedWindowMap; |
| 18 using sessions_helper::SyncedSessionVector; | 18 using sessions_helper::SyncedSessionVector; |
| 19 using sessions_helper::WindowsMatch; | 19 using sessions_helper::WindowsMatch; |
| 20 | 20 |
| (...skipping 440 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 461 ASSERT_FALSE(GetSessionData(1, &sessions1)); | 461 ASSERT_FALSE(GetSessionData(1, &sessions1)); |
| 462 | 462 |
| 463 // Client 0 becomes active again with a new tab. | 463 // Client 0 becomes active again with a new tab. |
| 464 ASSERT_TRUE(OpenTabAndGetLocalWindows(0, GURL(kURL2), | 464 ASSERT_TRUE(OpenTabAndGetLocalWindows(0, GURL(kURL2), |
| 465 client0_windows.GetMutable())); | 465 client0_windows.GetMutable())); |
| 466 ASSERT_TRUE(GetClient(0)->AwaitMutualSyncCycleCompletion(GetClient(1))); | 466 ASSERT_TRUE(GetClient(0)->AwaitMutualSyncCycleCompletion(GetClient(1))); |
| 467 ASSERT_TRUE(GetSessionData(1, &sessions1)); | 467 ASSERT_TRUE(GetSessionData(1, &sessions1)); |
| 468 ASSERT_EQ(1U, sessions1.size()); | 468 ASSERT_EQ(1U, sessions1.size()); |
| 469 ASSERT_TRUE(WindowsMatch(sessions1[0]->windows, *client0_windows.Get())); | 469 ASSERT_TRUE(WindowsMatch(sessions1[0]->windows, *client0_windows.Get())); |
| 470 } | 470 } |
| OLD | NEW |