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

Side by Side Diff: extensions/renderer/api_test_base.cc

Issue 622343002: replace OVERRIDE and FINAL with override and final in extensions/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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
« no previous file with comments | « extensions/renderer/api_test_base.h ('k') | extensions/renderer/api_test_base_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "extensions/renderer/api_test_base.h" 5 #include "extensions/renderer/api_test_base.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/run_loop.h" 9 #include "base/run_loop.h"
10 #include "extensions/common/extension_urls.h" 10 #include "extensions/common/extension_urls.h"
(...skipping 13 matching lines...) Expand all
24 // Natives for the implementation of the unit test version of chrome.test. Calls 24 // Natives for the implementation of the unit test version of chrome.test. Calls
25 // the provided |quit_closure| when either notifyPass or notifyFail is called. 25 // the provided |quit_closure| when either notifyPass or notifyFail is called.
26 class TestNatives : public gin::Wrappable<TestNatives> { 26 class TestNatives : public gin::Wrappable<TestNatives> {
27 public: 27 public:
28 static gin::Handle<TestNatives> Create(v8::Isolate* isolate, 28 static gin::Handle<TestNatives> Create(v8::Isolate* isolate,
29 const base::Closure& quit_closure) { 29 const base::Closure& quit_closure) {
30 return gin::CreateHandle(isolate, new TestNatives(quit_closure)); 30 return gin::CreateHandle(isolate, new TestNatives(quit_closure));
31 } 31 }
32 32
33 virtual gin::ObjectTemplateBuilder GetObjectTemplateBuilder( 33 virtual gin::ObjectTemplateBuilder GetObjectTemplateBuilder(
34 v8::Isolate* isolate) OVERRIDE { 34 v8::Isolate* isolate) override {
35 return Wrappable<TestNatives>::GetObjectTemplateBuilder(isolate) 35 return Wrappable<TestNatives>::GetObjectTemplateBuilder(isolate)
36 .SetMethod("Log", &TestNatives::Log) 36 .SetMethod("Log", &TestNatives::Log)
37 .SetMethod("NotifyPass", &TestNatives::NotifyPass) 37 .SetMethod("NotifyPass", &TestNatives::NotifyPass)
38 .SetMethod("NotifyFail", &TestNatives::NotifyFail); 38 .SetMethod("NotifyFail", &TestNatives::NotifyFail);
39 } 39 }
40 40
41 void Log(const std::string& value) { logs_ += value + "\n"; } 41 void Log(const std::string& value) { logs_ += value + "\n"; }
42 void NotifyPass() { FinishTesting(); } 42 void NotifyPass() { FinishTesting(); }
43 43
44 void NotifyFail(const std::string& message) { 44 void NotifyFail(const std::string& message) {
(...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after
212 } 212 }
213 213
214 void ApiTestBase::RunPromisesAgain() { 214 void ApiTestBase::RunPromisesAgain() {
215 RunResolvedPromises(); 215 RunResolvedPromises();
216 base::MessageLoop::current()->PostTask( 216 base::MessageLoop::current()->PostTask(
217 FROM_HERE, 217 FROM_HERE,
218 base::Bind(&ApiTestBase::RunPromisesAgain, base::Unretained(this))); 218 base::Bind(&ApiTestBase::RunPromisesAgain, base::Unretained(this)));
219 } 219 }
220 220
221 } // namespace extensions 221 } // namespace extensions
OLDNEW
« no previous file with comments | « extensions/renderer/api_test_base.h ('k') | extensions/renderer/api_test_base_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698