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

Side by Side Diff: content/browser/startup_task_runner_unittest.cc

Issue 678073006: Standardize usage of virtual/override/final specifiers. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix bogus formatting Created 6 years, 1 month 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 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 "content/browser/startup_task_runner.h" 5 #include "content/browser/startup_task_runner.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/bind_helpers.h" 8 #include "base/bind_helpers.h"
9 #include "base/callback.h" 9 #include "base/callback.h"
10 #include "base/location.h" 10 #include "base/location.h"
(...skipping 24 matching lines...) Expand all
35 return true; 35 return true;
36 } 36 }
37 37
38 void Observer(int result) { 38 void Observer(int result) {
39 observer_calls++; 39 observer_calls++;
40 observer_result = result; 40 observer_result = result;
41 } 41 }
42 42
43 class StartupTaskRunnerTest : public testing::Test { 43 class StartupTaskRunnerTest : public testing::Test {
44 public: 44 public:
45 45 void SetUp() override {
46 virtual void SetUp() {
47 last_task_ = 0; 46 last_task_ = 0;
48 observer_calls = 0; 47 observer_calls = 0;
49 task_count = 0; 48 task_count = 0;
50 } 49 }
51 50
52 int Task1() { 51 int Task1() {
53 last_task_ = 1; 52 last_task_ = 1;
54 task_count++; 53 task_count++;
55 return 0; 54 return 0;
56 } 55 }
(...skipping 254 matching lines...) Expand 10 before | Expand all | Expand 10 after
311 EXPECT_EQ(observer_calls, 1); 310 EXPECT_EQ(observer_calls, 1);
312 EXPECT_EQ(observer_result, 1); 311 EXPECT_EQ(observer_result, 1);
313 312
314 // Check that running synchronously now doesn't do anything 313 // Check that running synchronously now doesn't do anything
315 runner.RunAllTasksNow(); 314 runner.RunAllTasksNow();
316 EXPECT_EQ(observer_calls, 1); 315 EXPECT_EQ(observer_calls, 1);
317 EXPECT_EQ(task_count, 1); 316 EXPECT_EQ(task_count, 1);
318 } 317 }
319 } // namespace 318 } // namespace
320 } // namespace content 319 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/speech/speech_recognizer_impl_unittest.cc ('k') | content/browser/storage_partition_impl_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698