net: Port NetworkContextConfigurationBrowserTest to desktop Android [chromium/src : main]

0 views
Skip to first unread message

James Cook (Gerrit)

unread,
Apr 1, 2026, 11:24:24 PM (4 days ago) Apr 1
to Matt Mueller, Achuith Bhandarkar, AyeAye, Chromium LUCI CQ, chromium...@chromium.org, chromium-a...@chromium.org, extension...@chromium.org, net-r...@chromium.org
Attention needed from Matt Mueller

James Cook added 4 comments

Patchset-level comments
File-level comment, Patchset 11 (Latest):
James Cook . resolved

Matt, please take a look. Thanks!

File chrome/browser/net/network_context_configuration_browsertest.cc
Line 321, Patchset 11 (Latest): BrowserWindowInterface* CreateIncognitoBrowserWindow() {
James Cook . unresolved

This is a cross-platform (desktop + Android) way to create an incognito window. Window creation is async on Android, hence the TestFuture.

Line 561, Patchset 11 (Latest): // Android.
James Cook . unresolved

I think this might be due to the Android emulator configuration used on the bots (I think networking is disabled at the OS level). I've seen similar networking test failures on Android in other suites.

Line 908, Patchset 11 (Latest): // Use fetch() because service workers don't support XMLHttpRequest.
James Cook . unresolved

and we have to use a service worker for manifest V3.

Open in Gerrit

Related details

Attention is currently required from:
  • Matt Mueller
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement is not satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
  • requirement is not satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: I554854092a5b4cf9dd0c0652ea510b8bd5be1fcd
Gerrit-Change-Number: 7713121
Gerrit-PatchSet: 11
Gerrit-Owner: James Cook <jame...@chromium.org>
Gerrit-Reviewer: James Cook <jame...@chromium.org>
Gerrit-Reviewer: Matt Mueller <ma...@chromium.org>
Gerrit-CC: Achuith Bhandarkar <ach...@chromium.org>
Gerrit-Attention: Matt Mueller <ma...@chromium.org>
Gerrit-Comment-Date: Thu, 02 Apr 2026 03:24:10 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
satisfied_requirement
unsatisfied_requirement
open
diffy

Matt Mueller (Gerrit)

unread,
Apr 2, 2026, 8:28:52 PM (3 days ago) Apr 2
to James Cook, Matt Mueller, Achuith Bhandarkar, AyeAye, Chromium LUCI CQ, chromium...@chromium.org, chromium-a...@chromium.org, extension...@chromium.org, net-r...@chromium.org
Attention needed from James Cook

Matt Mueller added 5 comments

Patchset-level comments
Matt Mueller . resolved

generally lgtm, one question about the incognito flag

File chrome/browser/net/network_context_configuration_browsertest.cc
Line 238, Patchset 11 (Latest): // Needed to support incognito on desktop Android.
Matt Mueller . unresolved

is this comment accurate? Looking at https://source.chromium.org/chromium/chromium/src/+/main:components/feed/README.md I'm confused why incognito would require a "feed" feature flag.

Line 321, Patchset 11 (Latest): BrowserWindowInterface* CreateIncognitoBrowserWindow() {
James Cook . resolved

This is a cross-platform (desktop + Android) way to create an incognito window. Window creation is async on Android, hence the TestFuture.

Matt Mueller

Acknowledged

James Cook . resolved

I think this might be due to the Android emulator configuration used on the bots (I think networking is disabled at the OS level). I've seen similar networking test failures on Android in other suites.

Matt Mueller

that's weird since I would think the resolution should get caught by the TestHostResolver which shouldn't touch the real networking stack at all, but I guess there could be some layer that is saying "oh a resolution failed, and it looks like there's no networking so I'll return INTERNET_DISCONNECTED instead of the actual error"? dunno. :shrug:

Line 908, Patchset 11 (Latest): // Use fetch() because service workers don't support XMLHttpRequest.
James Cook . resolved

and we have to use a service worker for manifest V3.

Matt Mueller

Acknowledged

Open in Gerrit

Related details

Attention is currently required from:
  • James Cook
Submit Requirements:
  • requirement satisfiedCode-Coverage
  • requirement is not satisfiedCode-Owners
  • requirement is not satisfiedCode-Review
  • requirement is not satisfiedNo-Unresolved-Comments
  • requirement is not satisfiedReview-Enforcement
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
Gerrit-MessageType: comment
Gerrit-Project: chromium/src
Gerrit-Branch: main
Gerrit-Change-Id: I554854092a5b4cf9dd0c0652ea510b8bd5be1fcd
Gerrit-Change-Number: 7713121
Gerrit-PatchSet: 11
Gerrit-Owner: James Cook <jame...@chromium.org>
Gerrit-Reviewer: James Cook <jame...@chromium.org>
Gerrit-Reviewer: Matt Mueller <ma...@chromium.org>
Gerrit-CC: Achuith Bhandarkar <ach...@chromium.org>
Gerrit-Attention: James Cook <jame...@chromium.org>
Gerrit-Comment-Date: Fri, 03 Apr 2026 00:28:41 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: James Cook <jame...@chromium.org>
satisfied_requirement
unsatisfied_requirement
open
diffy

James Cook (Gerrit)

unread,
Apr 3, 2026, 1:06:42 PM (2 days ago) Apr 3
to Matt Mueller, Achuith Bhandarkar, AyeAye, Chromium LUCI CQ, chromium...@chromium.org, chromium-a...@chromium.org, extension...@chromium.org, net-r...@chromium.org
Attention needed from Matt Mueller

James Cook added 2 comments

Patchset-level comments
James Cook . resolved

Matt, please take another look.

File chrome/browser/net/network_context_configuration_browsertest.cc
Line 238, Patchset 11 (Latest): // Needed to support incognito on desktop Android.
Matt Mueller . resolved

is this comment accurate? Looking at https://source.chromium.org/chromium/chromium/src/+/main:components/feed/README.md I'm confused why incognito would require a "feed" feature flag.

James Cook

Sadly, it's required, at least for now.

See ExtensionBrowserTest:
https://source.chromium.org/chromium/chromium/src/+/main:chrome/browser/extensions/extension_browsertest.cc;drc=734942efce8a4fba157de5cb8f0ae7eec787d36b;l=191

Or BrowserWindowAndroidBrowserTestBase:
https://source.chromium.org/chromium/chromium/src/+/main:chrome/browser/ui/browser_window/test/android/browser_window_android_browsertest_base.cc;drc=1b064913f23efc41aefe42c7a3810da86f857d91;l=16

Mobile Android can open a "window" with a mix of incognito and regular profiles. But for desktop Android we want incognito in a separate window, like Win/Mac/Linux. That's what this flag does. I don't know why it's in namespace `feed` though.

Open in Gerrit

Related details

Attention is currently required from:
  • Matt Mueller
Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement is not satisfiedCode-Owners
    • requirement is not satisfiedCode-Review
    • requirement is not satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: I554854092a5b4cf9dd0c0652ea510b8bd5be1fcd
    Gerrit-Change-Number: 7713121
    Gerrit-PatchSet: 11
    Gerrit-Owner: James Cook <jame...@chromium.org>
    Gerrit-Reviewer: James Cook <jame...@chromium.org>
    Gerrit-Reviewer: Matt Mueller <ma...@chromium.org>
    Gerrit-CC: Achuith Bhandarkar <ach...@chromium.org>
    Gerrit-Attention: Matt Mueller <ma...@chromium.org>
    Gerrit-Comment-Date: Fri, 03 Apr 2026 17:06:31 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: No
    Comment-In-Reply-To: Matt Mueller <ma...@chromium.org>
    satisfied_requirement
    unsatisfied_requirement
    open
    diffy

    Matt Mueller (Gerrit)

    unread,
    Apr 3, 2026, 2:19:16 PM (2 days ago) Apr 3
    to James Cook, Matt Mueller, Achuith Bhandarkar, AyeAye, Chromium LUCI CQ, chromium...@chromium.org, chromium-a...@chromium.org, extension...@chromium.org, net-r...@chromium.org
    Attention needed from James Cook

    Matt Mueller voted Code-Review+1

    Code-Review+1
    Open in Gerrit

    Related details

    Attention is currently required from:
    • James Cook
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement satisfiedCode-Owners
    • requirement satisfiedCode-Review
    • requirement satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: I554854092a5b4cf9dd0c0652ea510b8bd5be1fcd
    Gerrit-Change-Number: 7713121
    Gerrit-PatchSet: 11
    Gerrit-Owner: James Cook <jame...@chromium.org>
    Gerrit-Reviewer: James Cook <jame...@chromium.org>
    Gerrit-Reviewer: Matt Mueller <ma...@chromium.org>
    Gerrit-CC: Achuith Bhandarkar <ach...@chromium.org>
    Gerrit-Attention: James Cook <jame...@chromium.org>
    Gerrit-Comment-Date: Fri, 03 Apr 2026 18:19:06 +0000
    Gerrit-HasComments: No
    Gerrit-Has-Labels: Yes
    satisfied_requirement
    open
    diffy

    James Cook (Gerrit)

    unread,
    Apr 3, 2026, 2:21:11 PM (2 days ago) Apr 3
    to Matt Mueller, Achuith Bhandarkar, AyeAye, Chromium LUCI CQ, chromium...@chromium.org, chromium-a...@chromium.org, extension...@chromium.org, net-r...@chromium.org

    James Cook voted and added 1 comment

    Votes added by James Cook

    Commit-Queue+2

    1 comment

    Patchset-level comments
    James Cook . resolved

    Thanks for the review!

    Open in Gerrit

    Related details

    Attention set is empty
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement satisfiedCode-Owners
    • requirement satisfiedCode-Review
    • requirement satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: comment
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: I554854092a5b4cf9dd0c0652ea510b8bd5be1fcd
    Gerrit-Change-Number: 7713121
    Gerrit-PatchSet: 11
    Gerrit-Owner: James Cook <jame...@chromium.org>
    Gerrit-Reviewer: James Cook <jame...@chromium.org>
    Gerrit-Reviewer: Matt Mueller <ma...@chromium.org>
    Gerrit-CC: Achuith Bhandarkar <ach...@chromium.org>
    Gerrit-Comment-Date: Fri, 03 Apr 2026 18:20:59 +0000
    Gerrit-HasComments: Yes
    Gerrit-Has-Labels: Yes
    satisfied_requirement
    open
    diffy

    Chromium LUCI CQ (Gerrit)

    unread,
    Apr 3, 2026, 4:28:17 PM (2 days ago) Apr 3
    to James Cook, Matt Mueller, Achuith Bhandarkar, AyeAye, chromium...@chromium.org, chromium-a...@chromium.org, extension...@chromium.org, net-r...@chromium.org

    Chromium LUCI CQ submitted the change

    Change information

    Commit message:
    net: Port NetworkContextConfigurationBrowserTest to desktop Android

    This is part of the effort to support extensions on desktop Android.
    This test suite contains a test of third-party cookie behavior for
    extensions.

    - Use ENABLE_EXTENSIONS_CORE instead of ENABLE_EXTENSIONS, so that
    desktop Android will be included
    - Eliminate usage of Browser, especially browser()->profile()
    - Switch to cross-platform GetProfile() and rename an existing
    GetProfile() helper method
    - Use TabListInterface instead of TabStripModel
    - Convert the test extension from manifest V2 to V3
    - Replace XMLHttpRequest with fetch() as the former is not supported
    in service workers, which MV3 requires

    Flakiness checks are skipped because this test suite contains tests
    with PRE_ steps and the Android flakiness detector does not support
    them (and reports false positive flakes). I ran the flake detector
    on an earlier patchset (see comments about flake in the CL).
    Bug: 494643383, 498341268, 425432018
    Validate-Test-Flakiness: skip
    Change-Id: I554854092a5b4cf9dd0c0652ea510b8bd5be1fcd
    Reviewed-by: Matt Mueller <ma...@chromium.org>
    Commit-Queue: James Cook <jame...@chromium.org>
    Cr-Commit-Position: refs/heads/main@{#1609941}
    Files:
    • M chrome/browser/net/network_context_configuration_browsertest.cc
    • M chrome/test/BUILD.gn
    Change size: M
    Delta: 2 files changed, 146 insertions(+), 80 deletions(-)
    Branch: refs/heads/main
    Submit Requirements:
    • requirement satisfiedCode-Review: +1 by Matt Mueller
    Open in Gerrit
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: merged
    Gerrit-Project: chromium/src
    Gerrit-Branch: main
    Gerrit-Change-Id: I554854092a5b4cf9dd0c0652ea510b8bd5be1fcd
    Gerrit-Change-Number: 7713121
    Gerrit-PatchSet: 12
    Gerrit-Owner: James Cook <jame...@chromium.org>
    Gerrit-Reviewer: Chromium LUCI CQ <chromiu...@luci-project-accounts.iam.gserviceaccount.com>
    Gerrit-Reviewer: James Cook <jame...@chromium.org>
    Gerrit-Reviewer: Matt Mueller <ma...@chromium.org>
    Gerrit-CC: Achuith Bhandarkar <ach...@chromium.org>
    open
    diffy
    satisfied_requirement

    luci-bisection@appspot.gserviceaccount.com (Gerrit)

    unread,
    Apr 4, 2026, 9:54:45 AM (yesterday) Apr 4
    to James Cook, Chromium LUCI CQ, Matt Mueller, Achuith Bhandarkar, AyeAye, chromium...@chromium.org, chromium-a...@chromium.org, extension...@chromium.org, net-r...@chromium.org

    Related details

    Attention set is empty
    Submit Requirements:
    • requirement satisfiedCode-Coverage
    • requirement satisfiedCode-Owners
    • requirement satisfiedCode-Review
    • requirement satisfiedReview-Enforcement
    Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. DiffyGerrit
    Gerrit-MessageType: revert
    satisfied_requirement
    open
    diffy
    Reply all
    Reply to author
    Forward
    0 new messages