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

Side by Side Diff: ios/chrome/test/ios_chrome_scoped_testing_chrome_browser_state_manager.h

Issue 2622913002: Simplify registration of a test ChromeBrowserStateManager. (Closed)
Patch Set: Fix typo in naming variable. Created 3 years, 11 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
(Empty)
1 // Copyright 2017 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 IOS_CHROME_TEST_IOS_CHROME_SCOPED_TESTING_CHROME_BROWSER_STATE_MANAGER_H _
6 #define IOS_CHROME_TEST_IOS_CHROME_SCOPED_TESTING_CHROME_BROWSER_STATE_MANAGER_H _
7
8 #include <memory>
9
10 #include "base/macros.h"
11
12 namespace ios {
13 class ChromeBrowserStateManager;
14 }
15
16 // Helper class to register an ios::ChromeBrowserStateManager against
17 // the TestApplicationContext using local scoping to do proper cleanup.
18 class IOSChromeScopedTestingChromeBrowserStateManager {
19 public:
20 explicit IOSChromeScopedTestingChromeBrowserStateManager(
21 std::unique_ptr<ios::ChromeBrowserStateManager> browser_state_manager);
22 ~IOSChromeScopedTestingChromeBrowserStateManager();
23
24 private:
25 std::unique_ptr<ios::ChromeBrowserStateManager> browser_state_manager_;
26 ios::ChromeBrowserStateManager* saved_browser_state_manager_;
27
28 DISALLOW_COPY_AND_ASSIGN(IOSChromeScopedTestingChromeBrowserStateManager);
29 };
30
31 #endif // IOS_CHROME_TEST_IOS_CHROME_SCOPED_TESTING_CHROME_BROWSER_STATE_MANAGE R_H_
OLDNEW
« no previous file with comments | « ios/chrome/test/BUILD.gn ('k') | ios/chrome/test/ios_chrome_scoped_testing_chrome_browser_state_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698