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

Issue 1132753008: Replaced TestNowSource with SimpleTestTickClock. (Closed)

Created:
5 years, 7 months ago by Ankur Verma
Modified:
5 years, 6 months ago
CC:
cc-bugs_chromium.org, chromium-reviews, deepak.s, erikwright+watch_chromium.org, scheduler-bugs_chromium.org, Paweł Hajdan Jr.
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Replaced TestNowSource with SimpleTestTickClock. Removed TestNowSource completely. Its usage updated under cc/test, cc/scheduler, cc/surfaces and components/scheduler with coressponding api of SimpleTestTickClock. Refactored num_now_calls_ functionality in NowNotCalledWhenThereAreNoDelayedTasks test to use TestAlwaysFailTimeSource BUG=440281, 494887 CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel Committed: https://crrev.com/2e4c4e14344779d903ea578ae1be4663801d9f05 Cr-Commit-Position: refs/heads/master@{#334341}

Patch Set 1 #

Patch Set 2 : Rebasing and additional code changes. #

Total comments: 6

Patch Set 3 : Removed TestNowSource. Updated components/scheduler too. No changes to base/test #

Patch Set 4 : Corrected typo. Minor changes to keep parity with TestNowSource. #

Total comments: 41

Patch Set 5 : Incorporated review comments: scoped leaking clocks, refactored num_now_calls_ functionality #

Total comments: 18

Patch Set 6 : Rebase only! #

Patch Set 7 : Incorporated review comments #

Patch Set 8 : Rebased again. Replaces TimeSource with TickClock in TestAlwaysFailTimeSource #

Total comments: 16

Patch Set 9 : Sami's review changes. Removed extra ctor from OrderedSimpletaskRunner. #

Patch Set 10 : Rebase only. #

Patch Set 11 : More review comment changes: updated comments for raw pointers of SimpleTestTickClock. #

Total comments: 11

Patch Set 12 : Sami's suggested changes on time units. #

Patch Set 13 : Rebased #

Patch Set 14 : Rebased again. #

Patch Set 15 : Rebased. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+469 lines, -603 lines) Patch
M AUTHORS View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +1 line, -0 lines 0 comments Download
M cc/BUILD.gn View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +0 lines, -2 lines 0 comments Download
M cc/cc_tests.gyp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +0 lines, -2 lines 0 comments Download
M cc/scheduler/begin_frame_source_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 12 chunks +34 lines, -30 lines 0 comments Download
M cc/scheduler/scheduler_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 14 chunks +26 lines, -24 lines 0 comments Download
M cc/surfaces/display_scheduler_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 14 chunks +22 lines, -22 lines 0 comments Download
M cc/surfaces/surface_display_output_surface_unittest.cc View 1 2 3 4 5 6 7 8 2 chunks +3 lines, -1 line 0 comments Download
M cc/test/begin_frame_args_test.h View 2 chunks +3 lines, -3 lines 0 comments Download
M cc/test/begin_frame_args_test.cc View 1 2 2 chunks +4 lines, -4 lines 0 comments Download
M cc/test/ordered_simple_task_runner.h View 1 2 3 4 5 6 7 8 4 chunks +6 lines, -5 lines 0 comments Download
M cc/test/ordered_simple_task_runner.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 9 chunks +23 lines, -26 lines 0 comments Download
M cc/test/ordered_simple_task_runner_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 8 chunks +23 lines, -26 lines 0 comments Download
M cc/test/scheduler_test_common.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 7 chunks +24 lines, -23 lines 0 comments Download
M cc/test/scheduler_test_common.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 6 chunks +7 lines, -7 lines 0 comments Download
D cc/test/test_now_source.h View 1 2 1 chunk +0 lines, -63 lines 0 comments Download
D cc/test/test_now_source.cc View 1 2 1 chunk +0 lines, -130 lines 0 comments Download
M components/components_tests.gyp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +2 lines, -0 lines 0 comments Download
M components/scheduler/BUILD.gn View 1 2 3 4 5 6 7 1 chunk +2 lines, -0 lines 0 comments Download
M components/scheduler/child/DEPS View 1 2 3 4 5 6 1 chunk +1 line, -0 lines 0 comments Download
M components/scheduler/child/idle_helper_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 42 chunks +89 lines, -87 lines 0 comments Download
M components/scheduler/child/scheduler_helper_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 4 chunks +7 lines, -6 lines 0 comments Download
M components/scheduler/child/task_queue_manager_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 10 chunks +22 lines, -21 lines 0 comments Download
M components/scheduler/child/test_time_source.h View 1 2 3 4 5 6 7 8 1 chunk +4 lines, -6 lines 0 comments Download
M components/scheduler/child/test_time_source.cc View 1 2 3 4 5 6 7 2 chunks +2 lines, -4 lines 0 comments Download
M components/scheduler/child/worker_scheduler_impl_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 7 chunks +21 lines, -19 lines 0 comments Download
M components/scheduler/renderer/deadline_task_runner_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 6 chunks +20 lines, -19 lines 0 comments Download
M components/scheduler/renderer/renderer_scheduler_impl_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 44 chunks +77 lines, -73 lines 0 comments Download
A components/scheduler/test/test_always_fail_time_source.h View 1 2 3 4 5 6 7 8 1 chunk +25 lines, -0 lines 0 comments Download
A components/scheduler/test/test_always_fail_time_source.cc View 1 2 3 4 5 6 7 8 1 chunk +21 lines, -0 lines 0 comments Download

Messages

Total messages: 49 (8 generated)
Ankur Verma
Please have a look. Thanks!
5 years, 7 months ago (2015-05-14 07:02:21 UTC) #2
mithro-old
Hi Ankur, Before we proceed you'll need to check with OWNERS of base/test to see ...
5 years, 7 months ago (2015-05-19 02:20:40 UTC) #3
Ankur Verma
Thanks for taking a look, Tim. I've re-based the patch onto latest code since the ...
5 years, 7 months ago (2015-05-19 11:22:08 UTC) #4
Ankur Verma
Hi Pawel, Could you please review changes under base/test/? I've added few api's to SimpleTestTickClock ...
5 years, 7 months ago (2015-05-19 11:28:57 UTC) #6
Ankur Verma
Hi Pawel, Gentle reminder. Could you please take a look at minor changes to base/test/simple_test_tick_clock.* ...
5 years, 7 months ago (2015-05-26 07:11:25 UTC) #7
Paweł Hajdan Jr.
https://codereview.chromium.org/1132753008/diff/20001/base/test/simple_test_tick_clock.h File base/test/simple_test_tick_clock.h (right): https://codereview.chromium.org/1132753008/diff/20001/base/test/simple_test_tick_clock.h#newcode22 base/test/simple_test_tick_clock.h:22: SimpleTestTickClock(int64_t initial); Why are these additional ctors needed? https://codereview.chromium.org/1132753008/diff/20001/base/test/simple_test_tick_clock.h#newcode27 ...
5 years, 7 months ago (2015-05-26 11:30:25 UTC) #8
Ankur Verma
Need to remove additions to SimpleTestTickClock and update usage accordingly under cc/test. Will upload updated ...
5 years, 7 months ago (2015-05-26 12:58:29 UTC) #9
Ankur Verma
Hello Tim & Sami. PTAL.
5 years, 6 months ago (2015-05-28 14:15:00 UTC) #11
Ankur Verma
@Tim I've removed TestNowSource completely. I realized that my previous changes broke components_unittests, thus updated ...
5 years, 6 months ago (2015-05-29 04:45:43 UTC) #12
mithro-old
Generally looks good (there is a bit of weirdness from stuff unrelated to this patch). ...
5 years, 6 months ago (2015-05-29 08:26:48 UTC) #13
Sami
Thanks, I've added a few comments. https://codereview.chromium.org/1132753008/diff/60001/components/scheduler/child/idle_helper_unittest.cc File components/scheduler/child/idle_helper_unittest.cc (right): https://codereview.chromium.org/1132753008/diff/60001/components/scheduler/child/idle_helper_unittest.cc#newcode142 components/scheduler/child/idle_helper_unittest.cc:142: clock_->Advance(base::TimeDelta::FromInternalValue(5000)); Do any ...
5 years, 6 months ago (2015-05-29 14:00:58 UTC) #14
mithro-old
On 2015/05/29 14:00:58, Sami wrote: > Thanks, I've added a few comments. > > https://codereview.chromium.org/1132753008/diff/60001/components/scheduler/child/idle_helper_unittest.cc ...
5 years, 6 months ago (2015-06-01 03:34:13 UTC) #15
mithro-old
Hi, Answers for Sami about a couple of his questions. Tim 'mithro' Ansell https://codereview.chromium.org/1132753008/diff/60001/components/scheduler/child/idle_helper_unittest.cc File ...
5 years, 6 months ago (2015-06-01 03:37:37 UTC) #16
Ankur Verma
Thanks Tim & Sami for the review. I've responded to your queries with comments. @Tim, ...
5 years, 6 months ago (2015-06-01 05:30:44 UTC) #17
mithro-old
On 2015/06/01 05:30:44, Ankur Verma wrote: > Thanks Tim & Sami for the review. > ...
5 years, 6 months ago (2015-06-01 07:13:16 UTC) #18
mithro-old
https://codereview.chromium.org/1132753008/diff/60001/components/scheduler/child/idle_helper_unittest.cc File components/scheduler/child/idle_helper_unittest.cc (right): https://codereview.chromium.org/1132753008/diff/60001/components/scheduler/child/idle_helper_unittest.cc#newcode142 components/scheduler/child/idle_helper_unittest.cc:142: clock_->Advance(base::TimeDelta::FromInternalValue(5000)); On 2015/06/01 05:30:44, Ankur Verma wrote: > On ...
5 years, 6 months ago (2015-06-01 07:32:16 UTC) #19
Ankur Verma
@Tim, Pls refer to my comments. I suppose i'll first upload a patch for review ...
5 years, 6 months ago (2015-06-01 09:21:41 UTC) #20
mithro-old
> I suppose i'll first upload a patch for review with review comments incorporated > ...
5 years, 6 months ago (2015-06-01 11:31:20 UTC) #21
Ankur Verma
Hello Tim & Sami, I've incorporated the review comment changes. Scoped leaking clocks and refactored ...
5 years, 6 months ago (2015-06-03 14:56:11 UTC) #22
mithro-old
Please do a rebase ASAP so we can make sure this runs on the trybots. ...
5 years, 6 months ago (2015-06-04 07:40:43 UTC) #23
mithro-old
Please do a rebase ASAP so we can make sure this runs on the trybots. ...
5 years, 6 months ago (2015-06-04 07:41:10 UTC) #24
Sami
+1 for putting this through the trybots. https://codereview.chromium.org/1132753008/diff/80001/components/components_tests.gyp File components/components_tests.gyp (right): https://codereview.chromium.org/1132753008/diff/80001/components/components_tests.gyp#newcode475 components/components_tests.gyp:475: 'scheduler/child/test_always_fail_time_source.cc', Could ...
5 years, 6 months ago (2015-06-04 14:47:07 UTC) #25
Ankur Verma
Thanks Tim & Sami for reviewing again. I have just uploaded a rebase of this ...
5 years, 6 months ago (2015-06-04 15:25:08 UTC) #26
Ankur Verma
Tim & Sami, PTAL. I've updated all review comment changes except one mentioned below. @Tim, ...
5 years, 6 months ago (2015-06-05 14:39:17 UTC) #27
Sami
Thanks, I've added a few comments. https://codereview.chromium.org/1132753008/diff/140001/AUTHORS File AUTHORS (right): https://codereview.chromium.org/1132753008/diff/140001/AUTHORS#newcode608 AUTHORS:608: Ankur Verma <ankur1.verma@samsung.com> ...
5 years, 6 months ago (2015-06-05 17:11:07 UTC) #28
Ankur Verma
Hello Sami & Tim, Have updated all review changes. PTAL. Kindly trigger trybots as well. ...
5 years, 6 months ago (2015-06-08 07:11:35 UTC) #29
Sami
Thanks for the fixes. Just a couple of comments about time units. https://codereview.chromium.org/1132753008/diff/200001/cc/test/ordered_simple_task_runner.cc File cc/test/ordered_simple_task_runner.cc ...
5 years, 6 months ago (2015-06-08 13:59:02 UTC) #30
Ankur Verma
@Sami, I have a query on previous review comments. Please clarify. https://codereview.chromium.org/1132753008/diff/200001/cc/test/ordered_simple_task_runner.cc File cc/test/ordered_simple_task_runner.cc (right): ...
5 years, 6 months ago (2015-06-09 07:53:48 UTC) #31
Sami
https://codereview.chromium.org/1132753008/diff/200001/cc/test/ordered_simple_task_runner.cc File cc/test/ordered_simple_task_runner.cc (right): https://codereview.chromium.org/1132753008/diff/200001/cc/test/ordered_simple_task_runner.cc#newcode283 cc/test/ordered_simple_task_runner.cc:283: state->SetInteger("now_in_microseconds", On 2015/06/09 07:53:47, Ankur Verma wrote: > On ...
5 years, 6 months ago (2015-06-09 10:16:02 UTC) #32
Ankur Verma
Hello Sami & Tim, Have incorporated review changes. PTAL. https://codereview.chromium.org/1132753008/diff/200001/cc/test/ordered_simple_task_runner.cc File cc/test/ordered_simple_task_runner.cc (right): https://codereview.chromium.org/1132753008/diff/200001/cc/test/ordered_simple_task_runner.cc#newcode283 cc/test/ordered_simple_task_runner.cc:283: ...
5 years, 6 months ago (2015-06-09 13:53:43 UTC) #33
Ankur Verma
Hello Tim & Sami, Rebased again. PTAL if you have time. Please trigger trybots too.
5 years, 6 months ago (2015-06-11 08:37:24 UTC) #35
Sami
Thanks for your patience. lgtm.
5 years, 6 months ago (2015-06-11 13:58:42 UTC) #36
mithro-old
lgtm
5 years, 6 months ago (2015-06-12 13:13:57 UTC) #38
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1132753008/280001
5 years, 6 months ago (2015-06-12 13:14:07 UTC) #39
commit-bot: I haz the power
Try jobs failed on following builders: chromium_presubmit on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presubmit/builds/70486)
5 years, 6 months ago (2015-06-12 13:20:29 UTC) #41
mithro-old
Hi, I tried to send this patch to the commit queue but it looks like ...
5 years, 6 months ago (2015-06-12 13:26:47 UTC) #42
Ankur Verma
Thanks Tim & Sami for the review. Apologies for the delayed response, had to take ...
5 years, 6 months ago (2015-06-13 11:34:26 UTC) #43
mithro-old
lgtm
5 years, 6 months ago (2015-06-13 12:00:52 UTC) #45
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1132753008/300001
5 years, 6 months ago (2015-06-13 12:01:03 UTC) #47
commit-bot: I haz the power
Committed patchset #15 (id:300001)
5 years, 6 months ago (2015-06-13 13:38:41 UTC) #48
commit-bot: I haz the power
5 years, 6 months ago (2015-06-13 13:39:21 UTC) #49
Message was sent while issue was closed.
Patchset 15 (id:??) landed as
https://crrev.com/2e4c4e14344779d903ea578ae1be4663801d9f05
Cr-Commit-Position: refs/heads/master@{#334341}

Powered by Google App Engine
This is Rietveld 408576698