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

Issue 2864433003: [ARC] Add browser test of ArcAuthService (Closed)

Created:
3 years, 7 months ago by blundell
Modified:
3 years, 7 months ago
CC:
chromium-reviews, elijahtaylor+arcwatch_chromium.org, oshima+watch_chromium.org, yusukes+watch_chromium.org, hidehiko+watch_chromium.org, khmel+watch_chromium.org, lhchavez+watch_chromium.org, victorhsieh+watch_chromium.org, davemoore+watch_chromium.org
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

[ARC] Add browser test of ArcAuthService In preparation for changing ArcAuthService to consume signin information via the Identity Service, this CL adds a browsertest of ArcAuthService. The initial test tests the flow for a user (non-managed) account when background auth is performed. This is the flow that is the most significant consumer of the Identity Service in the ARC auth code. Specifically, we test that if Chrome is seeded with information for a given account via the signin code, then when AuthInstance connects to ArcAuthService and requests account info, it receives account info corresponding to the seeded information. Currently, we skip the merge session part of the auth flow in this test. The merge session is difficult to interact with in a testing context, and even with this flow skipped, the interaction between the ARC auth code and //components/signin is basically fully exercised by the test. In the future, we will aim to add tests of the following cases (some of which might be easy, and others quite difficult): - Error cases for background auth - Merge session - Manual authentication - Robot accounts - Managed accounts BUG=683120 Review-Url: https://codereview.chromium.org/2864433003 Cr-Commit-Position: refs/heads/master@{#473535} Committed: https://chromium.googlesource.com/chromium/src/+/cb01102e078c3dbd41aad1ba652f43f6465e9e84

Patch Set 1 #

Patch Set 2 : Browsertest #

Patch Set 3 : Self-review #

Patch Set 4 : Rebase #

Total comments: 15

Patch Set 5 : Response to review #

Total comments: 8

Patch Set 6 : Rebase #

Patch Set 7 : Response to reviews #

Unified diffs Side-by-side diffs Delta from patch set Stats (+270 lines, -25 lines) Patch
M chrome/browser/chromeos/arc/arc_auth_context.h View 1 2 3 4 2 chunks +7 lines, -0 lines 0 comments Download
M chrome/browser/chromeos/arc/arc_auth_context.cc View 1 2 3 4 1 chunk +6 lines, -0 lines 0 comments Download
M chrome/browser/chromeos/arc/arc_auth_service.h View 1 2 3 1 chunk +2 lines, -3 lines 0 comments Download
M chrome/browser/chromeos/arc/arc_auth_service.cc View 1 2 3 3 chunks +3 lines, -13 lines 0 comments Download
A chrome/browser/chromeos/arc/auth/arc_auth_service_browsertest.cc View 1 2 3 4 5 6 1 chunk +228 lines, -0 lines 0 comments Download
M chrome/browser/chromeos/arc/auth/arc_background_auth_code_fetcher.h View 1 2 3 4 5 6 1 chunk +3 lines, -0 lines 0 comments Download
M chrome/browser/chromeos/arc/auth/arc_background_auth_code_fetcher.cc View 1 2 3 4 5 6 3 chunks +5 lines, -7 lines 0 comments Download
M chrome/browser/chromeos/login/users/fake_chrome_user_manager.h View 1 3 chunks +7 lines, -0 lines 0 comments Download
M chrome/browser/chromeos/login/users/fake_chrome_user_manager.cc View 1 2 3 4 3 chunks +8 lines, -2 lines 0 comments Download
M chrome/test/BUILD.gn View 1 2 3 4 5 1 chunk +1 line, -0 lines 0 comments Download

Messages

Total messages: 46 (33 generated)
blundell
3 years, 7 months ago (2017-05-11 15:24:45 UTC) #17
Luis Héctor Chávez
More tests are always welcome :) Thanks so much for doing this! https://codereview.chromium.org/2864433003/diff/60001/chrome/browser/chromeos/arc/arc_auth_context.h File chrome/browser/chromeos/arc/arc_auth_context.h ...
3 years, 7 months ago (2017-05-11 16:57:55 UTC) #18
blundell
Thanks! https://codereview.chromium.org/2864433003/diff/60001/chrome/browser/chromeos/arc/arc_auth_context.h File chrome/browser/chromeos/arc/arc_auth_context.h (right): https://codereview.chromium.org/2864433003/diff/60001/chrome/browser/chromeos/arc/arc_auth_context.h#newcode79 chrome/browser/chromeos/arc/arc_auth_context.h:79: bool skip_merge_session_for_testing_; On 2017/05/11 16:57:54, Luis Héctor Chávez ...
3 years, 7 months ago (2017-05-12 09:09:32 UTC) #19
Luis Héctor Chávez
lgtm! Also, for consistency with the rest of the codebase, can you amend the commit ...
3 years, 7 months ago (2017-05-12 15:45:56 UTC) #24
khmel
https://codereview.chromium.org/2864433003/diff/80001/chrome/browser/chromeos/arc/auth/arc_auth_service_browsertest.cc File chrome/browser/chromeos/arc/auth/arc_auth_service_browsertest.cc (right): https://codereview.chromium.org/2864433003/diff/80001/chrome/browser/chromeos/arc/auth/arc_auth_service_browsertest.cc#newcode57 chrome/browser/chromeos/arc/auth/arc_auth_service_browsertest.cc:57: class FakeAuthInstance : public mojom::AuthInstance { Up to you ...
3 years, 7 months ago (2017-05-12 15:52:28 UTC) #26
blundell
Thanks for the reviews! https://codereview.chromium.org/2864433003/diff/80001/chrome/browser/chromeos/arc/auth/arc_auth_service_browsertest.cc File chrome/browser/chromeos/arc/auth/arc_auth_service_browsertest.cc (right): https://codereview.chromium.org/2864433003/diff/80001/chrome/browser/chromeos/arc/auth/arc_auth_service_browsertest.cc#newcode57 chrome/browser/chromeos/arc/auth/arc_auth_service_browsertest.cc:57: class FakeAuthInstance : public mojom::AuthInstance ...
3 years, 7 months ago (2017-05-15 08:32:32 UTC) #29
blundell
alemate@: Can you do an OWNERS review of //chrome/browser/chromeos/login? Thanks!
3 years, 7 months ago (2017-05-15 08:33:27 UTC) #33
blundell
alemate@: friendly ping :)
3 years, 7 months ago (2017-05-16 13:38:57 UTC) #36
blundell
achuith@: Can you do an OWNERS review of //chrome/browser/chromeos/login? Thanks!
3 years, 7 months ago (2017-05-17 09:42:46 UTC) #38
achuithb
On 2017/05/17 09:42:46, blundell (OOO until May 22) wrote: > achuith@: Can you do an ...
3 years, 7 months ago (2017-05-18 21:38:21 UTC) #39
Alexander Alekseev
lgtm
3 years, 7 months ago (2017-05-20 00:17:58 UTC) #40
commit-bot: I haz the power
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2864433003/120001
3 years, 7 months ago (2017-05-22 08:37:35 UTC) #43
commit-bot: I haz the power
3 years, 7 months ago (2017-05-22 09:53:35 UTC) #46
Message was sent while issue was closed.
Committed patchset #7 (id:120001) as
https://chromium.googlesource.com/chromium/src/+/cb01102e078c3dbd41aad1ba652f...

Powered by Google App Engine
This is Rietveld 408576698