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

Side by Side Diff: base/test/task_runner_test_template.h

Issue 10735044: Remove #pragma once. Just from base/ for now. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 5 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 | Annotate | Revision Log
« no previous file with comments | « base/test/sequenced_task_runner_test_template.h ('k') | base/test/test_file_util.h » ('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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 // This class defines tests that implementations of TaskRunner should 5 // This class defines tests that implementations of TaskRunner should
6 // pass in order to be conformant. Here's how you use it to test your 6 // pass in order to be conformant. Here's how you use it to test your
7 // implementation. 7 // implementation.
8 // 8 //
9 // Say your class is called MyTaskRunner. Then you need to define a 9 // Say your class is called MyTaskRunner. Then you need to define a
10 // class called MyTaskRunnerTestDelegate in my_task_runner_unittest.cc 10 // class called MyTaskRunnerTestDelegate in my_task_runner_unittest.cc
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 // Then you simply #include this file as well as gtest.h and add the 43 // Then you simply #include this file as well as gtest.h and add the
44 // following statement to my_task_runner_unittest.cc: 44 // following statement to my_task_runner_unittest.cc:
45 // 45 //
46 // INSTANTIATE_TYPED_TEST_CASE_P( 46 // INSTANTIATE_TYPED_TEST_CASE_P(
47 // MyTaskRunner, TaskRunnerTest, MyTaskRunnerTestDelegate); 47 // MyTaskRunner, TaskRunnerTest, MyTaskRunnerTestDelegate);
48 // 48 //
49 // Easy! 49 // Easy!
50 50
51 #ifndef BASE_TEST_TASK_RUNNER_TEST_TEMPLATE_H_ 51 #ifndef BASE_TEST_TASK_RUNNER_TEST_TEMPLATE_H_
52 #define BASE_TEST_TASK_RUNNER_TEST_TEMPLATE_H_ 52 #define BASE_TEST_TASK_RUNNER_TEST_TEMPLATE_H_
53 #pragma once
54 53
55 #include <cstddef> 54 #include <cstddef>
56 #include <map> 55 #include <map>
57 56
58 #include "base/basictypes.h" 57 #include "base/basictypes.h"
59 #include "base/bind.h" 58 #include "base/bind.h"
60 #include "base/callback.h" 59 #include "base/callback.h"
61 #include "base/memory/ref_counted.h" 60 #include "base/memory/ref_counted.h"
62 #include "base/synchronization/lock.h" 61 #include "base/synchronization/lock.h"
63 #include "base/task_runner.h" 62 #include "base/task_runner.h"
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after
207 EXPECT_EQ(expected_task_run_counts, 206 EXPECT_EQ(expected_task_run_counts,
208 this->task_tracker_->GetTaskRunCounts()); 207 this->task_tracker_->GetTaskRunCounts());
209 } 208 }
210 209
211 REGISTER_TYPED_TEST_CASE_P( 210 REGISTER_TYPED_TEST_CASE_P(
212 TaskRunnerTest, Basic, Delayed, RunsTasksOnCurrentThread); 211 TaskRunnerTest, Basic, Delayed, RunsTasksOnCurrentThread);
213 212
214 } // namespace base 213 } // namespace base
215 214
216 #endif //#define BASE_TEST_TASK_RUNNER_TEST_TEMPLATE_H_ 215 #endif //#define BASE_TEST_TASK_RUNNER_TEST_TEMPLATE_H_
OLDNEW
« no previous file with comments | « base/test/sequenced_task_runner_test_template.h ('k') | base/test/test_file_util.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698