OLD | NEW |
(Empty) | |
| 1 // Copyright (c) 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_SESSION_USER_SESSION_MANAGER_TEST_API_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_SESSION_USER_SESSION_MANAGER_TEST_API_H_ |
| 7 |
| 8 #include "base/basictypes.h" |
| 9 #include "chrome/browser/chromeos/login/session/user_session_manager.h" |
| 10 |
| 11 namespace chromeos { |
| 12 namespace test { |
| 13 |
| 14 // Accesses private data from a UserSessionManager for testing. |
| 15 class UserSessionManagerTestApi { |
| 16 public: |
| 17 explicit UserSessionManagerTestApi(UserSessionManager* session_manager); |
| 18 |
| 19 // Injects |user_context| that will be used to create StubAuthenticator |
| 20 // instance when UserSessionManager::CreateAuthenticator() is called. |
| 21 void InjectStubUserContext(const UserContext& user_context); |
| 22 |
| 23 // Controls whether browser instance should be launched after sign in |
| 24 // (used in tests). |
| 25 void SetShouldLaunchBrowserInTests(bool should_launch_browser); |
| 26 |
| 27 private: |
| 28 UserSessionManager* session_manager_; // not owned |
| 29 |
| 30 DISALLOW_COPY_AND_ASSIGN(UserSessionManagerTestApi); |
| 31 }; |
| 32 |
| 33 } // namespace test |
| 34 } // namespace chromeos |
| 35 |
| 36 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_SESSION_USER_SESSION_MANAGER_TEST_API_H
_ |
OLD | NEW |