OLD | NEW |
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 SequencedTaskRunner should | 5 // This class defines tests that implementations of SequencedTaskRunner should |
6 // pass in order to be conformant. See task_runner_test_template.h for a | 6 // pass in order to be conformant. See task_runner_test_template.h for a |
7 // description of how to use the constructs in this file; these work the same. | 7 // description of how to use the constructs in this file; these work the same. |
8 | 8 |
9 #ifndef BASE_SEQUENCED_TASK_RUNNER_TEST_TEMPLATE_H_ | 9 #ifndef BASE_SEQUENCED_TASK_RUNNER_TEST_TEMPLATE_H_ |
10 #define BASE_SEQUENCED_TASK_RUNNER_TEST_TEMPLATE_H_ | 10 #define BASE_SEQUENCED_TASK_RUNNER_TEST_TEMPLATE_H_ |
11 | 11 |
12 #include <cstddef> | 12 #include <cstddef> |
13 #include <iosfwd> | 13 #include <iosfwd> |
14 #include <vector> | 14 #include <vector> |
15 | 15 |
16 #include "base/basictypes.h" | 16 #include "base/basictypes.h" |
17 #include "base/bind.h" | 17 #include "base/bind.h" |
18 #include "base/callback.h" | 18 #include "base/callback.h" |
19 #include "base/memory/ref_counted.h" | 19 #include "base/memory/ref_counted.h" |
20 #include "base/sequenced_task_runner.h" | 20 #include "base/sequenced_task_runner.h" |
21 #include "base/synchronization/condition_variable.h" | 21 #include "base/synchronization/condition_variable.h" |
22 #include "base/synchronization/lock.h" | 22 #include "base/synchronization/lock.h" |
23 #include "base/time.h" | 23 #include "base/time/time.h" |
24 #include "testing/gtest/include/gtest/gtest.h" | 24 #include "testing/gtest/include/gtest/gtest.h" |
25 | 25 |
26 namespace base { | 26 namespace base { |
27 | 27 |
28 namespace internal { | 28 namespace internal { |
29 | 29 |
30 struct TaskEvent { | 30 struct TaskEvent { |
31 enum Type { POST, START, END }; | 31 enum Type { POST, START, END }; |
32 TaskEvent(int i, Type type); | 32 TaskEvent(int i, Type type); |
33 int i; | 33 int i; |
(...skipping 333 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
367 SequentialDelayedNonNestable, | 367 SequentialDelayedNonNestable, |
368 NonNestablePostFromNonNestableTask, | 368 NonNestablePostFromNonNestableTask, |
369 DelayedTaskBasic, | 369 DelayedTaskBasic, |
370 DelayedTasksSameDelay, | 370 DelayedTasksSameDelay, |
371 DelayedTaskAfterLongTask, | 371 DelayedTaskAfterLongTask, |
372 DelayedTaskAfterManyLongTasks); | 372 DelayedTaskAfterManyLongTasks); |
373 | 373 |
374 } // namespace base | 374 } // namespace base |
375 | 375 |
376 #endif // BASE_TASK_RUNNER_TEST_TEMPLATE_H_ | 376 #endif // BASE_TASK_RUNNER_TEST_TEMPLATE_H_ |
OLD | NEW |