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

Side by Side Diff: chrome/browser/profile_resetter/profile_resetter_unittest.cc

Issue 624173002: replace OVERRIDE and FINAL with override and final in chrome/browser/[j-q]* (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase on master Created 6 years, 2 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 (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 "chrome/browser/profile_resetter/profile_resetter.h" 5 #include "chrome/browser/profile_resetter/profile_resetter.h"
6 6
7 #include "base/json/json_string_value_serializer.h" 7 #include "base/json/json_string_value_serializer.h"
8 #include "base/prefs/pref_service.h" 8 #include "base/prefs/pref_service.h"
9 #include "base/strings/utf_string_conversions.h" 9 #include "base/strings/utf_string_conversions.h"
10 #include "base/test/scoped_path_override.h" 10 #include "base/test/scoped_path_override.h"
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 // ProfileResetterTest -------------------------------------------------------- 96 // ProfileResetterTest --------------------------------------------------------
97 97
98 // ProfileResetterTest sets up the extension, WebData and TemplateURL services. 98 // ProfileResetterTest sets up the extension, WebData and TemplateURL services.
99 class ProfileResetterTest : public extensions::ExtensionServiceTestBase, 99 class ProfileResetterTest : public extensions::ExtensionServiceTestBase,
100 public ProfileResetterTestBase { 100 public ProfileResetterTestBase {
101 public: 101 public:
102 ProfileResetterTest(); 102 ProfileResetterTest();
103 virtual ~ProfileResetterTest(); 103 virtual ~ProfileResetterTest();
104 104
105 protected: 105 protected:
106 virtual void SetUp() OVERRIDE; 106 virtual void SetUp() override;
107 107
108 TestingProfile* profile() { return profile_.get(); } 108 TestingProfile* profile() { return profile_.get(); }
109 109
110 static KeyedService* CreateTemplateURLService( 110 static KeyedService* CreateTemplateURLService(
111 content::BrowserContext* context); 111 content::BrowserContext* context);
112 112
113 private: 113 private:
114 #if defined(OS_WIN) 114 #if defined(OS_WIN)
115 base::ScopedPathOverride user_desktop_override_; 115 base::ScopedPathOverride user_desktop_override_;
116 base::ScopedPathOverride app_dir_override_; 116 base::ScopedPathOverride app_dir_override_;
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
154 profile, Profile::EXPLICIT_ACCESS), 154 profile, Profile::EXPLICIT_ACCESS),
155 scoped_ptr<TemplateURLServiceClient>(), NULL, NULL, base::Closure()); 155 scoped_ptr<TemplateURLServiceClient>(), NULL, NULL, base::Closure());
156 } 156 }
157 157
158 158
159 // PinnedTabsResetTest -------------------------------------------------------- 159 // PinnedTabsResetTest --------------------------------------------------------
160 160
161 class PinnedTabsResetTest : public BrowserWithTestWindowTest, 161 class PinnedTabsResetTest : public BrowserWithTestWindowTest,
162 public ProfileResetterTestBase { 162 public ProfileResetterTestBase {
163 protected: 163 protected:
164 virtual void SetUp() OVERRIDE; 164 virtual void SetUp() override;
165 165
166 content::WebContents* CreateWebContents(); 166 content::WebContents* CreateWebContents();
167 }; 167 };
168 168
169 void PinnedTabsResetTest::SetUp() { 169 void PinnedTabsResetTest::SetUp() {
170 BrowserWithTestWindowTest::SetUp(); 170 BrowserWithTestWindowTest::SetUp();
171 resetter_.reset(new ProfileResetter(profile())); 171 resetter_.reset(new ProfileResetter(profile()));
172 } 172 }
173 173
174 content::WebContents* PinnedTabsResetTest::CreateWebContents() { 174 content::WebContents* PinnedTabsResetTest::CreateWebContents() {
175 return content::WebContents::Create( 175 return content::WebContents::Create(
176 content::WebContents::CreateParams(profile())); 176 content::WebContents::CreateParams(profile()));
177 } 177 }
178 178
179 179
180 // ConfigParserTest ----------------------------------------------------------- 180 // ConfigParserTest -----------------------------------------------------------
181 181
182 // URLFetcher delegate that simply records the upload data. 182 // URLFetcher delegate that simply records the upload data.
183 struct URLFetcherRequestListener : net::URLFetcherDelegate { 183 struct URLFetcherRequestListener : net::URLFetcherDelegate {
184 URLFetcherRequestListener(); 184 URLFetcherRequestListener();
185 virtual ~URLFetcherRequestListener(); 185 virtual ~URLFetcherRequestListener();
186 186
187 virtual void OnURLFetchComplete(const net::URLFetcher* source) OVERRIDE; 187 virtual void OnURLFetchComplete(const net::URLFetcher* source) override;
188 188
189 std::string upload_data; 189 std::string upload_data;
190 net::URLFetcherDelegate* real_delegate; 190 net::URLFetcherDelegate* real_delegate;
191 }; 191 };
192 192
193 URLFetcherRequestListener::URLFetcherRequestListener() 193 URLFetcherRequestListener::URLFetcherRequestListener()
194 : real_delegate(NULL) { 194 : real_delegate(NULL) {
195 } 195 }
196 196
197 URLFetcherRequestListener::~URLFetcherRequestListener() { 197 URLFetcherRequestListener::~URLFetcherRequestListener() {
(...skipping 898 matching lines...) Expand 10 before | Expand all | Expand 10 after
1096 new ResettableSettingsSnapshot(profile())); 1096 new ResettableSettingsSnapshot(profile()));
1097 deleted_snapshot->RequestShortcuts(base::Bind(&FeedbackCapture::Fail, 1097 deleted_snapshot->RequestShortcuts(base::Bind(&FeedbackCapture::Fail,
1098 base::Unretained(&capture))); 1098 base::Unretained(&capture)));
1099 deleted_snapshot.reset(); 1099 deleted_snapshot.reset();
1100 // Running remaining tasks shouldn't trigger the callback to be called as 1100 // Running remaining tasks shouldn't trigger the callback to be called as
1101 // |deleted_snapshot| was deleted before it could run. 1101 // |deleted_snapshot| was deleted before it could run.
1102 base::MessageLoop::current()->RunUntilIdle(); 1102 base::MessageLoop::current()->RunUntilIdle();
1103 } 1103 }
1104 1104
1105 } // namespace 1105 } // namespace
OLDNEW
« no previous file with comments | « chrome/browser/profile_resetter/profile_resetter_browsertest.cc ('k') | chrome/browser/profiles/avatar_menu.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698