OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 "base/task_scheduler/scheduler_worker_pool_impl.h" | 5 #include "base/task_scheduler/scheduler_worker_pool_impl.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include <memory> | 9 #include <memory> |
10 #include <unordered_set> | 10 #include <unordered_set> |
11 #include <vector> | 11 #include <vector> |
12 | 12 |
13 #include "base/bind.h" | 13 #include "base/bind.h" |
14 #include "base/bind_helpers.h" | 14 #include "base/bind_helpers.h" |
15 #include "base/callback.h" | 15 #include "base/callback.h" |
16 #include "base/macros.h" | 16 #include "base/macros.h" |
17 #include "base/memory/ptr_util.h" | 17 #include "base/memory/ptr_util.h" |
18 #include "base/memory/ref_counted.h" | 18 #include "base/memory/ref_counted.h" |
19 #include "base/synchronization/condition_variable.h" | 19 #include "base/synchronization/condition_variable.h" |
20 #include "base/synchronization/lock.h" | 20 #include "base/synchronization/lock.h" |
21 #include "base/synchronization/waitable_event.h" | 21 #include "base/synchronization/waitable_event.h" |
22 #include "base/task_runner.h" | 22 #include "base/task_runner.h" |
23 #include "base/task_scheduler/delayed_task_manager.h" | 23 #include "base/task_scheduler/delayed_task_manager.h" |
24 #include "base/task_scheduler/sequence.h" | 24 #include "base/task_scheduler/sequence.h" |
25 #include "base/task_scheduler/sequence_sort_key.h" | 25 #include "base/task_scheduler/sequence_sort_key.h" |
26 #include "base/task_scheduler/task_tracker.h" | 26 #include "base/task_scheduler/task_tracker.h" |
27 #include "base/task_scheduler/test_task_factory.h" | 27 #include "base/task_scheduler/test_task_factory.h" |
28 #include "base/task_scheduler/test_utils.h" | 28 #include "base/test/gtest_util.h" |
29 #include "base/threading/platform_thread.h" | 29 #include "base/threading/platform_thread.h" |
30 #include "base/threading/simple_thread.h" | 30 #include "base/threading/simple_thread.h" |
31 #include "base/threading/thread_restrictions.h" | 31 #include "base/threading/thread_restrictions.h" |
32 #include "testing/gtest/include/gtest/gtest.h" | 32 #include "testing/gtest/include/gtest/gtest.h" |
33 | 33 |
34 namespace base { | 34 namespace base { |
35 namespace internal { | 35 namespace internal { |
36 namespace { | 36 namespace { |
37 | 37 |
38 const size_t kNumWorkersInWorkerPool = 4; | 38 const size_t kNumWorkersInWorkerPool = 4; |
(...skipping 340 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
379 | 379 |
380 INSTANTIATE_TEST_CASE_P(IOAllowed, | 380 INSTANTIATE_TEST_CASE_P(IOAllowed, |
381 TaskSchedulerWorkerPoolImplIORestrictionTest, | 381 TaskSchedulerWorkerPoolImplIORestrictionTest, |
382 ::testing::Values(IORestriction::ALLOWED)); | 382 ::testing::Values(IORestriction::ALLOWED)); |
383 INSTANTIATE_TEST_CASE_P(IODisallowed, | 383 INSTANTIATE_TEST_CASE_P(IODisallowed, |
384 TaskSchedulerWorkerPoolImplIORestrictionTest, | 384 TaskSchedulerWorkerPoolImplIORestrictionTest, |
385 ::testing::Values(IORestriction::DISALLOWED)); | 385 ::testing::Values(IORestriction::DISALLOWED)); |
386 | 386 |
387 } // namespace internal | 387 } // namespace internal |
388 } // namespace base | 388 } // namespace base |
OLD | NEW |