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

Issue 1684643002: Avoid BrowserThread in profile_sync_service_autofill_unittest.cc (Closed)

Created:
4 years, 10 months ago by vabr (Chromium)
Modified:
4 years, 10 months ago
Reviewers:
Nicolas Zea, sdefresne
CC:
chromium-reviews, maxbogue+watch_chromium.org, plaree+watch_chromium.org, tim+watch_chromium.org, zea+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Avoid BrowserThread in profile_sync_service_autofill_unittest.cc This CL gets rid of the content-provided threads in profile_sync_service_autofill_unittest, in favour of base::Thread. This is in preparation to componentising this unit test. BUG=581640 Committed: https://crrev.com/6b1e9715eed76b95f079c82663d7d5c8dee9ef74 Cr-Commit-Position: refs/heads/master@{#376457}

Patch Set 1 : #

Total comments: 8

Patch Set 2 : Rebased, but pending self-review #

Patch Set 3 : Self reviewed #

Patch Set 4 : Does stopping the threads explicitly help with ASAN failures? #

Total comments: 4

Patch Set 5 : Just rebased #

Patch Set 6 : Clean up clean-up: what does ASAN say? #

Patch Set 7 : Just rebased #

Patch Set 8 : Fixing LSAN for Typed URLs? #

Patch Set 9 : Fix some leaks #

Patch Set 10 : Pulled the extra thread into the abstract test base + deleting properly on sync thread #

Patch Set 11 : Destroy SyncService in the base class #

Total comments: 23

Patch Set 12 : Rebase and address comments #

Patch Set 13 : Just rebased #

Patch Set 14 : Const ref scoped_refptr + fix scoped_ptr usage #

Total comments: 2

Patch Set 15 : Just rebased #

Unified diffs Side-by-side diffs Delta from patch set Stats (+120 lines, -178 lines) Patch
M chrome/browser/sync/abstract_profile_sync_service_test.h View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +4 lines, -2 lines 0 comments Download
M chrome/browser/sync/abstract_profile_sync_service_test.cc View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +2 lines, -14 lines 0 comments Download
M chrome/browser/sync/profile_sync_service_autofill_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 22 chunks +74 lines, -69 lines 0 comments Download
M chrome/browser/sync/profile_sync_service_typed_url_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 5 chunks +12 lines, -11 lines 0 comments Download
M chrome/browser/sync/test_profile_sync_service.h View 1 1 chunk +1 line, -1 line 0 comments Download
M components/browser_sync/browser/profile_sync_test_util.h View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +6 lines, -22 lines 0 comments Download
M components/browser_sync/browser/profile_sync_test_util.cc View 1 2 3 4 5 6 7 8 9 10 11 12 2 chunks +21 lines, -59 lines 0 comments Download

Depends on Patchset:

Dependent Patchsets:

Messages

Total messages: 39 (13 generated)
vabr (Chromium)
Hi sdefresne@, Because you participated in the discussion leading to this CL, would you mind ...
4 years, 10 months ago (2016-02-10 10:39:24 UTC) #5
sdefresne
https://codereview.chromium.org/1684643002/diff/40001/chrome/browser/sync/profile_sync_service_autofill_unittest.cc File chrome/browser/sync/profile_sync_service_autofill_unittest.cc (right): https://codereview.chromium.org/1684643002/diff/40001/chrome/browser/sync/profile_sync_service_autofill_unittest.cc#newcode128 chrome/browser/sync/profile_sync_service_autofill_unittest.cc:128: base::SingleThreadTaskRunner* g_ui_thread = nullptr; nit: I personally would have ...
4 years, 10 months ago (2016-02-10 10:56:58 UTC) #6
sdefresne
lgtm to unblock you
4 years, 10 months ago (2016-02-12 14:31:09 UTC) #7
vabr (Chromium)
On 2016/02/12 14:31:09, sdefresne wrote: > lgtm to unblock you Hi Sylvain, Sorry for my ...
4 years, 10 months ago (2016-02-12 14:38:27 UTC) #8
vabr (Chromium)
On 2016/02/12 14:38:27, vabr (Chromium) wrote: > On 2016/02/12 14:31:09, sdefresne wrote: > > lgtm ...
4 years, 10 months ago (2016-02-12 14:42:04 UTC) #9
vabr (Chromium)
@sdefresne: Thanks for the review so far. I rebased on another CL, feel free to ...
4 years, 10 months ago (2016-02-12 23:10:21 UTC) #11
Nicolas Zea
A couple questions, otherwise LG https://codereview.chromium.org/1684643002/diff/100001/chrome/browser/sync/profile_sync_service_autofill_unittest.cc File chrome/browser/sync/profile_sync_service_autofill_unittest.cc (right): https://codereview.chromium.org/1684643002/diff/100001/chrome/browser/sync/profile_sync_service_autofill_unittest.cc#newcode410 chrome/browser/sync/profile_sync_service_autofill_unittest.cc:410: db_thread_.Stop(); Doesn't this always ...
4 years, 10 months ago (2016-02-13 01:28:56 UTC) #12
vabr (Chromium)
Thanks, Nicolas! Questions answered below. Cheers, Vaclav https://codereview.chromium.org/1684643002/diff/100001/chrome/browser/sync/profile_sync_service_autofill_unittest.cc File chrome/browser/sync/profile_sync_service_autofill_unittest.cc (right): https://codereview.chromium.org/1684643002/diff/100001/chrome/browser/sync/profile_sync_service_autofill_unittest.cc#newcode410 chrome/browser/sync/profile_sync_service_autofill_unittest.cc:410: db_thread_.Stop(); On ...
4 years, 10 months ago (2016-02-13 10:40:48 UTC) #13
vabr (Chromium)
> It does, the only question is with timing. My suspicion with the ASAN failures ...
4 years, 10 months ago (2016-02-13 21:29:28 UTC) #14
vabr (Chromium)
Patch set 6 fixed the use-after-free. I am still working on the leaks, but at ...
4 years, 10 months ago (2016-02-14 17:50:55 UTC) #15
sdefresne
lg, I'll delegate to zea for the full review
4 years, 10 months ago (2016-02-15 10:00:02 UTC) #16
vabr (Chromium)
On 2016/02/15 10:00:02, sdefresne wrote: > lg, I'll delegate to zea for the full review ...
4 years, 10 months ago (2016-02-15 10:52:05 UTC) #17
vabr (Chromium)
More update: Half of the LSAN failures are fixed, and I am close to fixing ...
4 years, 10 months ago (2016-02-15 17:03:50 UTC) #18
vabr (Chromium)
Hi Nicolas, This CL is now ready for review. Thanks! Vaclav https://codereview.chromium.org/1684643002/diff/240001/chrome/browser/sync/profile_sync_service_autofill_unittest.cc File chrome/browser/sync/profile_sync_service_autofill_unittest.cc (right): ...
4 years, 10 months ago (2016-02-16 16:41:57 UTC) #19
Nicolas Zea
https://codereview.chromium.org/1684643002/diff/240001/chrome/browser/sync/abstract_profile_sync_service_test.h File chrome/browser/sync/abstract_profile_sync_service_test.h (right): https://codereview.chromium.org/1684643002/diff/240001/chrome/browser/sync/abstract_profile_sync_service_test.h#newcode61 chrome/browser/sync/abstract_profile_sync_service_test.h:61: base::Thread extra_thread_; nit:I think "data_type_thread" is clearer Although, given ...
4 years, 10 months ago (2016-02-16 22:44:51 UTC) #20
Nicolas Zea
https://codereview.chromium.org/1684643002/diff/240001/chrome/browser/sync/profile_sync_service_typed_url_unittest.cc File chrome/browser/sync/profile_sync_service_typed_url_unittest.cc (right): https://codereview.chromium.org/1684643002/diff/240001/chrome/browser/sync/profile_sync_service_typed_url_unittest.cc#newcode220 chrome/browser/sync/profile_sync_service_typed_url_unittest.cc:220: base::WaitableEvent sync_loop_tasks_done(false, false); nit: seems like this could be ...
4 years, 10 months ago (2016-02-16 23:40:16 UTC) #21
vabr (Chromium)
Thanks, Nicolas. I addressed your comments. I also pushed back on passing scoped_refptr by reference, ...
4 years, 10 months ago (2016-02-17 13:55:45 UTC) #22
Nicolas Zea
https://codereview.chromium.org/1684643002/diff/240001/chrome/browser/sync/abstract_profile_sync_service_test.h File chrome/browser/sync/abstract_profile_sync_service_test.h (right): https://codereview.chromium.org/1684643002/diff/240001/chrome/browser/sync/abstract_profile_sync_service_test.h#newcode61 chrome/browser/sync/abstract_profile_sync_service_test.h:61: base::Thread extra_thread_; On 2016/02/17 13:55:45, vabr (Chromium) wrote: > ...
4 years, 10 months ago (2016-02-17 22:05:43 UTC) #23
vabr (Chromium)
Thanks, Nicolas! I addressed your comments, and also fixed one thing in the existing code ...
4 years, 10 months ago (2016-02-18 13:05:01 UTC) #24
Nicolas Zea
LGTM! Thanks for your patience! https://codereview.chromium.org/1684643002/diff/240001/chrome/browser/sync/abstract_profile_sync_service_test.h File chrome/browser/sync/abstract_profile_sync_service_test.h (right): https://codereview.chromium.org/1684643002/diff/240001/chrome/browser/sync/abstract_profile_sync_service_test.h#newcode61 chrome/browser/sync/abstract_profile_sync_service_test.h:61: base::Thread extra_thread_; On 2016/02/18 ...
4 years, 10 months ago (2016-02-18 19:02:42 UTC) #25
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1684643002/320001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1684643002/320001
4 years, 10 months ago (2016-02-19 09:29:26 UTC) #27
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1684643002/320001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1684643002/320001
4 years, 10 months ago (2016-02-19 13:07:25 UTC) #30
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
4 years, 10 months ago (2016-02-19 15:57:40 UTC) #32
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1684643002/320001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1684643002/320001
4 years, 10 months ago (2016-02-19 16:35:17 UTC) #35
commit-bot: I haz the power
Committed patchset #15 (id:320001)
4 years, 10 months ago (2016-02-19 16:45:11 UTC) #37
commit-bot: I haz the power
4 years, 10 months ago (2016-02-19 16:46:40 UTC) #39
Message was sent while issue was closed.
Patchset 15 (id:??) landed as
https://crrev.com/6b1e9715eed76b95f079c82663d7d5c8dee9ef74
Cr-Commit-Position: refs/heads/master@{#376457}

Powered by Google App Engine
This is Rietveld 408576698