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

Issue 823143004: Add TestMockTimeTaskRunner in base/test. (Closed)

Created:
5 years, 11 months ago by engedy
Modified:
5 years, 11 months ago
CC:
chromium-reviews, sadrul, nkostylev+watch_chromium.org, oshima+watch_chromium.org, kalyank, erikwright+watch_chromium.org, stevenjb+watch_chromium.org, davemoore+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Add TestMockTimeTaskRunner in base/test. Multiple implementations of this functionality exist with slight modifications. This CL consolidates them. BUG=329911 TBR=thestig@chromium.org # For base/base.gyp changes. Committed: https://crrev.com/8d897fb17470c526155b2a9e86752be9a7f33c03 Cr-Commit-Position: refs/heads/master@{#311091}

Patch Set 1 #

Patch Set 2 : Add synchronization for PostTask(). #

Total comments: 76

Patch Set 3 : Addressed comments from bartfab@. #

Total comments: 14

Patch Set 4 : Addressed comments from stevenjb@. #

Total comments: 4

Patch Set 5 : Update year in copyright notice. Rebase. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+437 lines, -477 lines) Patch
M ash/system/chromeos/session/logout_confirmation_controller_unittest.cc View 1 2 11 chunks +15 lines, -151 lines 0 comments Download
M base/base.gyp View 1 2 3 4 1 chunk +2 lines, -0 lines 0 comments Download
M base/test/BUILD.gn View 1 chunk +2 lines, -0 lines 0 comments Download
A base/test/test_mock_time_task_runner.h View 1 2 3 4 1 chunk +121 lines, -0 lines 0 comments Download
A base/test/test_mock_time_task_runner.cc View 1 2 3 4 1 chunk +157 lines, -0 lines 0 comments Download
M chrome/browser/chromeos/session_length_limiter_unittest.cc View 1 2 15 chunks +19 lines, -121 lines 0 comments Download
M chrome/browser/chromeos/system/automatic_reboot_manager_unittest.cc View 1 2 3 71 chunks +121 lines, -205 lines 0 comments Download

Messages

Total messages: 27 (7 generated)
engedy
@Bartosz, I am about to use this in a 4th location, so this seems to ...
5 years, 11 months ago (2015-01-07 17:34:21 UTC) #2
bartfab (slow)
My take on the two open questions: 1) I think the name is not that ...
5 years, 11 months ago (2015-01-07 17:55:42 UTC) #3
engedy
On 2015/01/07 17:55:42, bartfab wrote: > My take on the two open questions: > > ...
5 years, 11 months ago (2015-01-07 18:02:15 UTC) #4
engedy
On 2015/01/07 18:02:15, engedy wrote: > On 2015/01/07 17:55:42, bartfab wrote: > > My take ...
5 years, 11 months ago (2015-01-08 11:48:48 UTC) #5
bartfab (slow)
LGTM. Thanks for taking care of this long-standing clean-up. I will reassign the bug to ...
5 years, 11 months ago (2015-01-08 14:14:36 UTC) #6
engedy
Apologies for forgetting cleaning up the includes. https://codereview.chromium.org/823143004/diff/20001/ash/system/chromeos/session/logout_confirmation_controller_unittest.cc File ash/system/chromeos/session/logout_confirmation_controller_unittest.cc (right): https://codereview.chromium.org/823143004/diff/20001/ash/system/chromeos/session/logout_confirmation_controller_unittest.cc#newcode7 ash/system/chromeos/session/logout_confirmation_controller_unittest.cc:7: #include <queue> ...
5 years, 11 months ago (2015-01-08 16:41:27 UTC) #8
engedy
@Pawel, could you please review base/test/? @Steven, could you please review the 3 unittest changes ...
5 years, 11 months ago (2015-01-08 16:47:57 UTC) #10
stevenjb
https://codereview.chromium.org/823143004/diff/60001/base/test/test_mock_time_task_runner.cc File base/test/test_mock_time_task_runner.cc (right): https://codereview.chromium.org/823143004/diff/60001/base/test/test_mock_time_task_runner.cc#newcode20 base/test/test_mock_time_task_runner.cc:20: virtual ~MockTickClock(); override https://codereview.chromium.org/823143004/diff/60001/base/test/test_mock_time_task_runner.cc#newcode23 base/test/test_mock_time_task_runner.cc:23: virtual TimeTicks NowTicks() override; ...
5 years, 11 months ago (2015-01-08 17:39:19 UTC) #11
engedy
https://codereview.chromium.org/823143004/diff/60001/base/test/test_mock_time_task_runner.cc File base/test/test_mock_time_task_runner.cc (right): https://codereview.chromium.org/823143004/diff/60001/base/test/test_mock_time_task_runner.cc#newcode20 base/test/test_mock_time_task_runner.cc:20: virtual ~MockTickClock(); On 2015/01/08 17:39:19, stevenjb wrote: > override ...
5 years, 11 months ago (2015-01-08 19:01:34 UTC) #12
stevenjb
lgtm
5 years, 11 months ago (2015-01-08 19:03:05 UTC) #13
Paweł Hajdan Jr.
LGTM w/nits https://codereview.chromium.org/823143004/diff/80001/base/test/test_mock_time_task_runner.cc File base/test/test_mock_time_task_runner.cc (right): https://codereview.chromium.org/823143004/diff/80001/base/test/test_mock_time_task_runner.cc#newcode1 base/test/test_mock_time_task_runner.cc:1: // Copyright 2014 The Chromium Authors. All ...
5 years, 11 months ago (2015-01-12 15:42:10 UTC) #14
engedy
https://codereview.chromium.org/823143004/diff/80001/base/test/test_mock_time_task_runner.cc File base/test/test_mock_time_task_runner.cc (right): https://codereview.chromium.org/823143004/diff/80001/base/test/test_mock_time_task_runner.cc#newcode1 base/test/test_mock_time_task_runner.cc:1: // Copyright 2014 The Chromium Authors. All rights reserved. ...
5 years, 11 months ago (2015-01-12 16:11:11 UTC) #15
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/823143004/100001
5 years, 11 months ago (2015-01-12 16:11:45 UTC) #17
commit-bot: I haz the power
Try jobs failed on following builders: chromium_presubmit on tryserver.chromium.linux (http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presubmit/builds/35093)
5 years, 11 months ago (2015-01-12 16:17:27 UTC) #19
engedy
@Lei, could you please sign off on the changes to base.gyp?
5 years, 11 months ago (2015-01-12 17:24:46 UTC) #21
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/823143004/100001
5 years, 11 months ago (2015-01-12 18:35:47 UTC) #23
Lei Zhang
lgtm
5 years, 11 months ago (2015-01-12 19:15:08 UTC) #24
commit-bot: I haz the power
Committed patchset #5 (id:100001)
5 years, 11 months ago (2015-01-12 20:02:09 UTC) #25
commit-bot: I haz the power
Patchset 5 (id:??) landed as https://crrev.com/8d897fb17470c526155b2a9e86752be9a7f33c03 Cr-Commit-Position: refs/heads/master@{#311091}
5 years, 11 months ago (2015-01-12 20:03:03 UTC) #26
Elliot Glaysher
5 years, 11 months ago (2015-01-12 21:37:27 UTC) #27
Message was sent while issue was closed.
A revert of this CL (patchset #5 id:100001) has been created in
https://codereview.chromium.org/844353002/ by erg@chromium.org.

The reason for reverting is: Suspect that this patch broke the chromeos asan
bots. It looks like all the
AutomaticRebootManagerTestInstance/AutomaticRebootManagerTest tests now leak
memory:

https://build.chromium.org/p/chromium.memory/builders/Linux%20Chromium%20OS%2....

Powered by Google App Engine
This is Rietveld 408576698