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

Unified Diff: base/task_scheduler/test_utils.h

Issue 2831883003: Do not inherit TaskPriority in TaskTraits. (Closed)
Patch Set: self-review Created 3 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: base/task_scheduler/test_utils.h
diff --git a/base/task_scheduler/test_utils.h b/base/task_scheduler/test_utils.h
index dbd1227f52b14e82e43332437ce11311e29d4b7c..7c1514c5c39bd1276f253549b5898840e03a21dd 100644
--- a/base/task_scheduler/test_utils.h
+++ b/base/task_scheduler/test_utils.h
@@ -5,6 +5,8 @@
#ifndef BASE_TASK_SCHEDULER_TEST_UTILS_H_
#define BASE_TASK_SCHEDULER_TEST_UTILS_H_
+#include "base/task_scheduler/task_traits.h"
+
namespace base {
namespace internal {
namespace test {
@@ -13,6 +15,10 @@ namespace test {
// parametrize relevant task_scheduler tests.
enum class ExecutionMode { PARALLEL, SEQUENCED, SINGLE_THREADED };
+// Returns TaskTraits with a non-INHERITED priority. This is useful because it
+// is invalid to initialize a Task with TaskTraits whose priority is INHERITED.
+TaskTraits CreateTaskTraits();
gab 2017/04/25 14:19:16 Can we instead hold a const bitfield in TaskTraits
fdoray 2017/04/25 15:21:19 Done.
+
} // namespace test
} // namespace internal
} // namespace base

Powered by Google App Engine
This is Rietveld 408576698