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

Unified Diff: base/task_scheduler/task_tracker_unittest.cc

Issue 2386653002: Replace base::Callback with base::OnceCallback in base::PendingTask (Closed)
Patch Set: revert most of task_scheduler changes Created 4 years, 2 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/task_tracker_unittest.cc
diff --git a/base/task_scheduler/task_tracker_unittest.cc b/base/task_scheduler/task_tracker_unittest.cc
index 57dca1f3909b129724fb5fce288d5f8fc3e8c85e..18ceae793bbd722d6b38b6954d6a78ac8b4a4442 100644
--- a/base/task_scheduler/task_tracker_unittest.cc
+++ b/base/task_scheduler/task_tracker_unittest.cc
@@ -498,9 +498,9 @@ TEST_P(TaskSchedulerTaskTrackerTest, FlushPendingDelayedTask) {
}
TEST_P(TaskSchedulerTaskTrackerTest, FlushPendingUndelayedTask) {
- const Task undelayed_task(FROM_HERE, Bind(&DoNothing),
- TaskTraits().WithShutdownBehavior(GetParam()),
- TimeDelta());
+ Task undelayed_task(FROM_HERE, Bind(&DoNothing),
+ TaskTraits().WithShutdownBehavior(GetParam()),
+ TimeDelta());
tracker_.WillPostTask(&undelayed_task);
// Flush() shouldn't return before the undelayed task runs.
@@ -514,9 +514,9 @@ TEST_P(TaskSchedulerTaskTrackerTest, FlushPendingUndelayedTask) {
}
TEST_P(TaskSchedulerTaskTrackerTest, PostTaskDuringFlush) {
- const Task undelayed_task(FROM_HERE, Bind(&DoNothing),
- TaskTraits().WithShutdownBehavior(GetParam()),
- TimeDelta());
+ Task undelayed_task(FROM_HERE, Bind(&DoNothing),
+ TaskTraits().WithShutdownBehavior(GetParam()),
+ TimeDelta());
tracker_.WillPostTask(&undelayed_task);
// Flush() shouldn't return before the undelayed task runs.
@@ -525,9 +525,9 @@ TEST_P(TaskSchedulerTaskTrackerTest, PostTaskDuringFlush) {
VERIFY_ASYNC_FLUSH_IN_PROGRESS();
// Simulate posting another undelayed task.
- const Task other_undelayed_task(FROM_HERE, Bind(&DoNothing),
- TaskTraits().WithShutdownBehavior(GetParam()),
- TimeDelta());
+ Task other_undelayed_task(FROM_HERE, Bind(&DoNothing),
+ TaskTraits().WithShutdownBehavior(GetParam()),
+ TimeDelta());
tracker_.WillPostTask(&other_undelayed_task);
// Run the first undelayed task.
@@ -544,13 +544,13 @@ TEST_P(TaskSchedulerTaskTrackerTest, PostTaskDuringFlush) {
TEST_P(TaskSchedulerTaskTrackerTest, RunDelayedTaskDuringFlush) {
// Simulate posting a delayed and an undelayed task.
- const Task delayed_task(FROM_HERE, Bind(&DoNothing),
- TaskTraits().WithShutdownBehavior(GetParam()),
- TimeDelta::FromDays(1));
+ Task delayed_task(FROM_HERE, Bind(&DoNothing),
+ TaskTraits().WithShutdownBehavior(GetParam()),
+ TimeDelta::FromDays(1));
tracker_.WillPostTask(&delayed_task);
- const Task undelayed_task(FROM_HERE, Bind(&DoNothing),
- TaskTraits().WithShutdownBehavior(GetParam()),
- TimeDelta());
+ Task undelayed_task(FROM_HERE, Bind(&DoNothing),
+ TaskTraits().WithShutdownBehavior(GetParam()),
+ TimeDelta());
tracker_.WillPostTask(&undelayed_task);
// Flush() shouldn't return before the undelayed task runs.

Powered by Google App Engine
This is Rietveld 408576698