New issue
Advanced search Search tips

Issue 797931 link

Starred by 2 users

Issue metadata

Status: Started
Owner:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 1
Type: Bug

Blocked on:
issue 913872
issue 903718

Blocking:
issue 859882
issue 883318
issue 883330



Sign in to add a comment

Convert AccountConsistencyService and its unittest away from SigninManager, GaiaCookieManagerService, and ProfileOAuth2TokenService

Project Member Reported by blundell@chromium.org, Dec 28 2017

Issue description

AccountConsistencyService observes signin/signout events via SigninManager
It also gets primary account info via SigninManager. It does this right after observing a signin event.
Its unittest has dependencies.

Doing these conversions should be straightforward.

 
Components: Internals>Services>Identity
Blocking: 796544
Status: Available (was: Untriaged)
Blockedon: 903718 913872
Blocking: -796544 859882 883330 883318
Labels: -Pri-3 Proj-Servicification Proj-Servicification-VendorBug Pri-1
Summary: Convert AccountConsistencyService and its unittest away from SigninManager, GaiaCookieManagerService, and ProfileOAuth2TokenService (was: Convert account_consistency code to talk to Identity Service client lib)
Updating this bug to reflect the current state of the world.

Note that converting the production code away from GaiaCookieManagerService is necessary to convert the unittest away from ProfileOAuth2TokenService: the unittest constructs a FakePO2TS to pass in to the FakeGCMS that it then passes to the production code.

See the blocking bugs. Note that we should be able to do the conversion away from SigninManager even before the blocking bugs are fixed.
Owner: svil...@igalia.com
Status: Assigned (was: Available)
Working on this
Project Member

Comment 5 by bugdroid1@chromium.org, Jan 10

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/8853032ec0edd9f4656c7abaeda4c504934c6119

commit 8853032ec0edd9f4656c7abaeda4c504934c6119
Author: Sergio Villar Senin <svillar@igalia.com>
Date: Thu Jan 10 10:48:59 2019

Replace SigninManager by IdentityManager in AccountConsistencyService

It was using the SigninManager API to observe primary account sign-in
status changes and also to verify whether a primary account was set or
not. The IdentityManager API is a good replacement for those use cases.

Note that the class is still using GaiaCookieManagerService but in
order to move that code away from that dependency the unit test needs
to be converted away from any usage of ProfileOAuth2TokenService. That
will be done in a follow-up patch.

Bug: 797931
Change-Id: I0820d0c229dbba3ec2c2df1c9432f6275571db45
Reviewed-on: https://chromium-review.googlesource.com/c/1394525
Commit-Queue: Sergio Villar <svillar@igalia.com>
Reviewed-by: Colin Blundell <blundell@chromium.org>
Reviewed-by: Mihai Sardarescu <msarda@chromium.org>
Cr-Commit-Position: refs/heads/master@{#621536}
[modify] https://crrev.com/8853032ec0edd9f4656c7abaeda4c504934c6119/components/signin/ios/DEPS
[modify] https://crrev.com/8853032ec0edd9f4656c7abaeda4c504934c6119/components/signin/ios/browser/BUILD.gn
[modify] https://crrev.com/8853032ec0edd9f4656c7abaeda4c504934c6119/components/signin/ios/browser/account_consistency_service.h
[modify] https://crrev.com/8853032ec0edd9f4656c7abaeda4c504934c6119/components/signin/ios/browser/account_consistency_service.mm
[modify] https://crrev.com/8853032ec0edd9f4656c7abaeda4c504934c6119/components/signin/ios/browser/account_consistency_service_unittest.mm
[modify] https://crrev.com/8853032ec0edd9f4656c7abaeda4c504934c6119/ios/chrome/browser/signin/account_consistency_service_factory.mm

Status: Fixed (was: Assigned)
Status: Started (was: Fixed)
Re-opening this as the unittest still needs conversion. Sergio, are you actively planning on following up here, or should we mark it available?
Oh I closed it by mistake, I'm still actively working on it BTW.
Labels: Pri-2
Labels: -Pri-2 Pri-1
(this one is actually P1 as the GCMS conversion is needed to convert SigninManager and PO2TS)

Sign in to add a comment