diff --git a/DEPS b/DEPS index 048064f..5db031d9 100644 --- a/DEPS +++ b/DEPS
@@ -185,7 +185,7 @@ 'checkout_fuchsia_for_arm64_host': False, # By default, download the fuchsia sdk from the public sdk directory. - 'fuchsia_sdk_cipd_prefix': 'fuchsia/sdk/core/', + 'fuchsia_sdk_cipd_prefix': 'fuchsia/sdk/gn/', # By default, download the fuchsia images from the fuchsia GCS bucket. 'fuchsia_images_bucket': 'fuchsia', @@ -269,7 +269,7 @@ # Three lines of non-changing comments so that # the commit queue can handle CLs rolling Skia # and whatever else without interference from each other. - 'skia_revision': 'b894c69abba556f596d75033aa60fa7a9404a26a', + 'skia_revision': 'e8968dce7a99f3eb14f89f05294f8d34a018bd11', # Three lines of non-changing comments so that # the commit queue can handle CLs rolling V8 # and whatever else without interference from each other. @@ -277,15 +277,15 @@ # Three lines of non-changing comments so that # the commit queue can handle CLs rolling ANGLE # and whatever else without interference from each other. - 'angle_revision': '9053a641bf5d58b3365a398d4bfbb6c0c3f0d6d6', + 'angle_revision': '9865ed8b8117a083eb138247bbcb029a6bb0f2e4', # Three lines of non-changing comments so that # the commit queue can handle CLs rolling SwiftShader # and whatever else without interference from each other. - 'swiftshader_revision': '643179694ec75904ae26664bf43d30cf4cd99909', + 'swiftshader_revision': '2e793ae0800255ec73c23fc89da2526ccf5361e7', # Three lines of non-changing comments so that # the commit queue can handle CLs rolling PDFium # and whatever else without interference from each other. - 'pdfium_revision': 'ee0c29691b42600190db18168cb94e16e913d97f', + 'pdfium_revision': 'da3804049084366e75fed155e099da2360ca77d1', # Three lines of non-changing comments so that # the commit queue can handle CLs rolling BoringSSL # and whatever else without interference from each other. @@ -340,7 +340,7 @@ # Three lines of non-changing comments so that # the commit queue can handle CLs rolling catapult # and whatever else without interference from each other. - 'catapult_revision': '05b7cd33df9e93b54c69d89ed957a4eb4e026c83', + 'catapult_revision': '67079d94e0910b398d659b5fc715e739c8c7494d', # Three lines of non-changing comments so that # the commit queue can handle CLs rolling libFuzzer # and whatever else without interference from each other. @@ -348,7 +348,7 @@ # Three lines of non-changing comments so that # the commit queue can handle CLs rolling devtools-frontend # and whatever else without interference from each other. - 'devtools_frontend_revision': '5cae797b182cd7c7ce0e5ebf467d92ca64d38637', + 'devtools_frontend_revision': '3ad1a317f78a83015da6b6566145099fad25a088', # Three lines of non-changing comments so that # the commit queue can handle CLs rolling libprotobuf-mutator # and whatever else without interference from each other. @@ -914,7 +914,7 @@ 'packages': [ { 'package': 'chromium/third_party/androidx', - 'version': 'gA0vvkGrsh9eQymdSOfRTYnYJpY-Wq7wonB0rx2eiMcC', + 'version': 'Da4Gfq0cbANF8TBzxjWyFxNZLsHhNw0miO3ApOghW7YC', }, ], 'condition': 'checkout_android', @@ -1130,7 +1130,7 @@ }, 'src/third_party/depot_tools': - Var('chromium_git') + '/chromium/tools/depot_tools.git' + '@' + '23ddab223518bcc9ad953686628247e4d7a0bd6e', + Var('chromium_git') + '/chromium/tools/depot_tools.git' + '@' + '08a30b20f221a4bdb8e8c151d9555d971dd1a0a7', 'src/third_party/devtools-frontend/src': Var('chromium_git') + '/devtools/devtools-frontend' + '@' + Var('devtools_frontend_revision'), @@ -1527,7 +1527,7 @@ }, 'src/third_party/perfetto': - Var('android_git') + '/platform/external/perfetto.git' + '@' + '69bc804a183b29d2eeaa9a61a589127db9228fe1', + Var('android_git') + '/platform/external/perfetto.git' + '@' + '268fb40af72db84076b1e61b93c4ed2580ef82de', 'src/third_party/perl': { 'url': Var('chromium_git') + '/chromium/deps/perl.git' + '@' + '6f3e5028eb65d0b4c5fdd792106ac4c84eee1eb3', @@ -1608,7 +1608,7 @@ 'packages': [ { 'package': 'fuchsia/third_party/android/aemu/release/linux-amd64', - 'version': '8gsJImrRZ2wpj9930nEuB3uxTE0KSfi7YkhtGiEMTB0C' + 'version': 'GcjUw68fmihG8tkuoeNqmjpK1Q4ikeoY8Y_-A64bw-sC' }, ], 'condition': 'host_os == "linux" and checkout_fuchsia', @@ -1754,10 +1754,10 @@ Var('chromium_git') + '/external/khronosgroup/webgl.git' + '@' + 'cf04aebdf9b53bb2853f22a81465688daf879ec6', 'src/third_party/webgpu-cts/src': - Var('chromium_git') + '/external/github.com/gpuweb/cts.git' + '@' + 'ecf4804228d1473df8596c3c87e5b7e32649e2de', + Var('chromium_git') + '/external/github.com/gpuweb/cts.git' + '@' + 'a6e1f5b7c86c723e045cf3c2c5b0068f1cfa8621', 'src/third_party/webrtc': - Var('webrtc_git') + '/src.git' + '@' + '31e31c8c0a9adbd9861267a3c81bfee9149d74e6', + Var('webrtc_git') + '/src.git' + '@' + '9e334b7d9973cf405439c088bad6dddb22dd4ec0', 'src/third_party/libgifcodec': Var('skia_git') + '/libgifcodec' + '@'+ Var('libgifcodec_revision'), @@ -1830,7 +1830,7 @@ Var('chromium_git') + '/v8/v8.git' + '@' + Var('v8_revision'), 'src-internal': { - 'url': 'https://chrome-internal.googlesource.com/chrome/src-internal.git@144248f8b53a91874ec52bda65d9b9672356de91', + 'url': 'https://chrome-internal.googlesource.com/chrome/src-internal.git@499fabc42fc2f7aaa77597b5c494f551c5daf811', 'condition': 'checkout_src_internal', }, @@ -1871,7 +1871,7 @@ 'packages': [ { 'package': 'chromeos_internal/apps/media_app/app', - 'version': 'whtlcNpoS3yXW5MkBK5x_wlfpid2geTTH_hI5C5Dx6wC', + 'version': 'S3pWzmJCCVf-J8HtHnPKIW3GYQ7I7TyTZfl9_TMUDe4C', }, ], 'condition': 'checkout_chromeos and checkout_src_internal',
diff --git a/android_webview/java/src/org/chromium/android_webview/common/ProductionSupportedFlagList.java b/android_webview/java/src/org/chromium/android_webview/common/ProductionSupportedFlagList.java index 50557d1..8235e3d 100644 --- a/android_webview/java/src/org/chromium/android_webview/common/ProductionSupportedFlagList.java +++ b/android_webview/java/src/org/chromium/android_webview/common/ProductionSupportedFlagList.java
@@ -4,6 +4,7 @@ package org.chromium.android_webview.common; +import org.chromium.base.BaseFeatures; import org.chromium.base.BaseSwitches; import org.chromium.blink_public.common.BlinkFeatures; import org.chromium.cc.base.CcSwitches; @@ -316,6 +317,8 @@ Flag.baseFeature(BlinkFeatures.DECODE_SCRIPT_SOURCE_OFF_THREAD, "If enabled, script source text will be decoded and hashed off the main" + "thread."), + Flag.baseFeature(BaseFeatures.OPTIMIZE_DATA_URLS, + "Optimizes parsing and loading of data: URLs."), // Add new commandline switches and features above. The final entry should have a // trailing comma for cleaner diffs. };
diff --git a/android_webview/nonembedded/java/AndroidManifest.xml b/android_webview/nonembedded/java/AndroidManifest.xml index db2151f..27cc6f28 100644 --- a/android_webview/nonembedded/java/AndroidManifest.xml +++ b/android_webview/nonembedded/java/AndroidManifest.xml
@@ -5,6 +5,13 @@ LICENSE file. --> +<!-- +Note: This is a jinja2 template, processed at build time into the final manifest. + +Blocks denoted with { % block some_name % }foo{ % endblock % } can be overridden +by a child template that "extends" this file. +--> + <manifest xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" package="{{manifest_package|default('com.android.webview')}}" @@ -174,6 +181,8 @@ android:externalService="true" tools:ignore="ExportedService" android:visibleToInstantApps="true" /> + {% block extra_application_definitions %} + {% endblock %} {% endif %} {% endmacro %} {{ common(manifest_package|default('com.android.webview'), library|default('libwebviewchromium.so')) }}
diff --git a/ash/BUILD.gn b/ash/BUILD.gn index 2224d61..c9aebe3 100644 --- a/ash/BUILD.gn +++ b/ash/BUILD.gn
@@ -1841,8 +1841,6 @@ "wm/desks/templates/desks_templates_icon_container.h", "wm/desks/templates/desks_templates_icon_view.cc", "wm/desks/templates/desks_templates_icon_view.h", - "wm/desks/templates/desks_templates_item_view.cc", - "wm/desks/templates/desks_templates_item_view.h", "wm/desks/templates/desks_templates_metrics_util.cc", "wm/desks/templates/desks_templates_metrics_util.h", "wm/desks/templates/desks_templates_presenter.cc", @@ -1855,6 +1853,8 @@ "wm/desks/templates/save_desk_template_button.h", "wm/desks/templates/save_desk_template_button_container.cc", "wm/desks/templates/save_desk_template_button_container.h", + "wm/desks/templates/saved_desk_item_view.cc", + "wm/desks/templates/saved_desk_item_view.h", "wm/desks/templates/saved_desk_name_view.cc", "wm/desks/templates/saved_desk_name_view.h", "wm/desks/zero_state_button.cc",
diff --git a/ash/app_list/views/app_list_bubble_view_unittest.cc b/ash/app_list/views/app_list_bubble_view_unittest.cc index d96abba6..1746640c 100644 --- a/ash/app_list/views/app_list_bubble_view_unittest.cc +++ b/ash/app_list/views/app_list_bubble_view_unittest.cc
@@ -219,7 +219,7 @@ auto* search_icon = search_box_view->search_icon(); gfx::Rect search_icon_bounds = search_icon->ConvertRectToWidget(search_icon->GetLocalBounds()); - EXPECT_EQ("17,17 24x24", search_icon_bounds.ToString()); + EXPECT_EQ("17,19 20x20", search_icon_bounds.ToString()); // Check height of search box view. EXPECT_EQ(56, search_box_view->height());
diff --git a/ash/app_list/views/search_box_view.cc b/ash/app_list/views/search_box_view.cc index 38903bd..502870b 100644 --- a/ash/app_list/views/search_box_view.cc +++ b/ash/app_list/views/search_box_view.cc
@@ -298,7 +298,7 @@ const gfx::VectorIcon& icon = search_engine_is_google ? google_icon : kSearchEngineNotGoogleIcon; SetSearchIconImage( - gfx::CreateVectorIcon(icon, kSearchBoxIconSize, + gfx::CreateVectorIcon(icon, GetSearchBoxIconSize(), AppListColorProvider::Get()->GetSearchBoxIconColor( SkColorSetARGB(0xDE, 0x00, 0x00, 0x00)))); } @@ -353,7 +353,7 @@ gfx::Point icon_origin; views::View::ConvertPointToTarget(search_icon(), this, &icon_origin); PaintFocusBar(canvas, gfx::Point(0, icon_origin.y()), - /*height=*/kSearchBoxIconSize); + /*height=*/GetSearchBoxIconSize()); } } } @@ -400,7 +400,7 @@ views::ImageButton* close = close_button(); close->SetImage( views::ImageButton::STATE_NORMAL, - gfx::CreateVectorIcon(views::kIcCloseIcon, kSearchBoxIconSize, + gfx::CreateVectorIcon(views::kIcCloseIcon, GetSearchBoxIconSize(), AppListColorProvider::Get()->GetSearchBoxIconColor( gfx::kGoogleGrey700))); close->SetVisible(false); @@ -557,9 +557,11 @@ int target_state_height) { // Horizontal margins are selected to match search box icon's vertical // margins. - const int horizontal_spacing = (target_state_height - kSearchBoxIconSize) / 2; + const int horizontal_spacing = + (target_state_height - GetSearchBoxIconSize()) / 2; const int horizontal_right_padding = - horizontal_spacing - (kSearchBoxButtonSizeDip - kSearchBoxIconSize) / 2; + horizontal_spacing - + (GetSearchBoxButtonSize() - GetSearchBoxIconSize()) / 2; box_layout()->set_inside_border_insets( gfx::Insets::TLBR(0, horizontal_spacing, 0, horizontal_right_padding)); box_layout()->set_between_child_spacing(horizontal_spacing); @@ -688,6 +690,18 @@ return !IsTrimmedQueryEmpty(current_query_); } +int SearchBoxView::GetSearchBoxIconSize() { + if (features::IsProductivityLauncherEnabled()) + return kBubbleLauncherSearchBoxIconSize; + return kClassicSearchBoxIconSize; +} + +int SearchBoxView::GetSearchBoxButtonSize() { + if (features::IsProductivityLauncherEnabled()) + return kBubbleLauncherSearchBoxButtonSizeDip; + return kClassicSearchBoxButtonSizeDip; +} + void SearchBoxView::UpdateTextColor() { if (is_app_list_bubble_) { // Bubble launcher uses standard text colors (light-on-dark by default). @@ -1087,7 +1101,7 @@ views::ImageButton* assistant = assistant_button(); assistant->SetImage( views::ImageButton::STATE_NORMAL, - gfx::CreateVectorIcon(chromeos::kAssistantIcon, kSearchBoxIconSize, + gfx::CreateVectorIcon(chromeos::kAssistantIcon, GetSearchBoxIconSize(), AppListColorProvider::Get()->GetSearchBoxIconColor( gfx::kGoogleGrey700))); std::u16string assistant_button_label(
diff --git a/ash/app_list/views/search_box_view.h b/ash/app_list/views/search_box_view.h index 9fc9c8e..7ace559 100644 --- a/ash/app_list/views/search_box_view.h +++ b/ash/app_list/views/search_box_view.h
@@ -156,6 +156,10 @@ // Whether the search box has a non-empty, non-whitespace query. bool HasValidQuery(); + // Calculates the correct sizing for search box icons and buttons. + int GetSearchBoxIconSize(); + int GetSearchBoxButtonSize(); + private: class FocusRingLayer;
diff --git a/ash/app_list/views/search_box_view_unittest.cc b/ash/app_list/views/search_box_view_unittest.cc index 25d805b5..783c0a0c 100644 --- a/ash/app_list/views/search_box_view_unittest.cc +++ b/ash/app_list/views/search_box_view_unittest.cc
@@ -353,7 +353,7 @@ SetSearchEngineIsGoogle(true); SetSearchBoxActive(false, ui::ET_UNKNOWN); const gfx::ImageSkia expected_icon = gfx::CreateVectorIcon( - kGoogleBlackIcon, kSearchBoxIconSize, kDefaultSearchboxColor); + kGoogleBlackIcon, view()->GetSearchBoxIconSize(), kDefaultSearchboxColor); const gfx::ImageSkia actual_icon = view()->search_icon()->GetImage(); @@ -365,9 +365,9 @@ TEST_P(SearchBoxViewTest, SearchBoxActiveSearchEngineGoogle) { SetSearchEngineIsGoogle(true); SetSearchBoxActive(true, ui::ET_MOUSE_PRESSED); - const gfx::ImageSkia expected_icon = - gfx::CreateVectorIcon(vector_icons::kGoogleColorIcon, kSearchBoxIconSize, - kDefaultSearchboxColor); + const gfx::ImageSkia expected_icon = gfx::CreateVectorIcon( + vector_icons::kGoogleColorIcon, view()->GetSearchBoxIconSize(), + kDefaultSearchboxColor); const gfx::ImageSkia actual_icon = view()->search_icon()->GetImage(); @@ -380,7 +380,8 @@ SetSearchEngineIsGoogle(false); SetSearchBoxActive(false, ui::ET_UNKNOWN); const gfx::ImageSkia expected_icon = gfx::CreateVectorIcon( - kSearchEngineNotGoogleIcon, kSearchBoxIconSize, kDefaultSearchboxColor); + kSearchEngineNotGoogleIcon, view()->GetSearchBoxIconSize(), + kDefaultSearchboxColor); const gfx::ImageSkia actual_icon = view()->search_icon()->GetImage(); @@ -393,7 +394,8 @@ SetSearchEngineIsGoogle(false); SetSearchBoxActive(true, ui::ET_UNKNOWN); const gfx::ImageSkia expected_icon = gfx::CreateVectorIcon( - kSearchEngineNotGoogleIcon, kSearchBoxIconSize, kDefaultSearchboxColor); + kSearchEngineNotGoogleIcon, view()->GetSearchBoxIconSize(), + kDefaultSearchboxColor); const gfx::ImageSkia actual_icon = view()->search_icon()->GetImage();
diff --git a/ash/capture_mode/capture_mode_bar_view.cc b/ash/capture_mode/capture_mode_bar_view.cc index f515ab86..e4af92b3 100644 --- a/ash/capture_mode/capture_mode_bar_view.cc +++ b/ash/capture_mode/capture_mode_bar_view.cc
@@ -21,6 +21,7 @@ #include "ash/shelf/shelf_layout_manager.h" #include "ash/strings/grit/ash_strings.h" #include "ash/style/ash_color_provider.h" +#include "ash/style/system_shadow.h" #include "base/bind.h" #include "ui/aura/window.h" #include "ui/base/l10n/l10n_util.h" @@ -70,7 +71,10 @@ close_button_(AddChildView(std::make_unique<CaptureModeButton>( base::BindRepeating(&CaptureModeBarView::OnCloseButtonPressed, base::Unretained(this)), - kCaptureModeCloseIcon))) { + kCaptureModeCloseIcon))), + shadow_(this, + SystemShadow::GetElevationFromType( + SystemShadow::Type::kElevation12)) { SetPaintToLayer(); auto* color_provider = AshColorProvider::Get(); SkColor background_color = color_provider->GetBaseLayerColor( @@ -115,6 +119,8 @@ SetBorder(std::make_unique<views::HighlightBorder>( kBorderRadius, views::HighlightBorder::Type::kHighlightBorder2, /*use_light_colors=*/false)); + shadow_.shadow()->SetShadowStyle(gfx::ShadowStyle::kChromeOSSystemUI); + shadow_.SetRoundedCornerRadius(kBorderRadius); } }
diff --git a/ash/capture_mode/capture_mode_bar_view.h b/ash/capture_mode/capture_mode_bar_view.h index f18d4c26..042c332 100644 --- a/ash/capture_mode/capture_mode_bar_view.h +++ b/ash/capture_mode/capture_mode_bar_view.h
@@ -7,6 +7,7 @@ #include "ash/ash_export.h" #include "ash/capture_mode/capture_mode_types.h" +#include "ash/public/cpp/view_shadow.h" #include "ui/base/metadata/metadata_header_macros.h" #include "ui/views/view.h" @@ -85,6 +86,7 @@ views::Separator* separator_2_; CaptureModeToggleButton* settings_button_; CaptureModeButton* close_button_; + ViewShadow shadow_; }; } // namespace ash
diff --git a/ash/components/arc/input_overlay/resources/com.datavisionstudio.roguelike.json b/ash/components/arc/input_overlay/resources/com.datavisionstudio.roguelike.json new file mode 100644 index 0000000..a2b91ab --- /dev/null +++ b/ash/components/arc/input_overlay/resources/com.datavisionstudio.roguelike.json
@@ -0,0 +1,36 @@ +// Copyright 2022 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +{ + "move": [ + { + "id": 0, + "input_sources": [ + "keyboard" + ], + "name": "Virtual Joystick", + "keys": [ + "KeyW", + "KeyA", + "KeyS", + "KeyD" + ], + "location": [ + { + "type": "dependent_position", + "anchor": [ + 0, + 1 + ], + "anchor_to_target": [ + 0.4995141, + -0.22689995 + ], + "y_on_x": 0.807393 + } + ], + "radius": 0.085019134 + } + ] +}
diff --git a/ash/components/arc/input_overlay/resources/input_overlay_resources.grd b/ash/components/arc/input_overlay/resources/input_overlay_resources.grd index e8aa07f1..1616bea4 100644 --- a/ash/components/arc/input_overlay/resources/input_overlay_resources.grd +++ b/ash/components/arc/input_overlay/resources/input_overlay_resources.grd
@@ -20,6 +20,7 @@ <include name="IDR_IO_COM_FINGERSOFT_HILLCLIMB" file="com.fingersoft.hillclimb.json" type="BINDATA" /> <include name="IDR_IO_COM_ANDROBABY_GAME2048" file="com.androbaby.game2048.json" type="BINDATA" /> <include name="IDR_IO_CO_IMBA_ARCHERO" file="co.imba.archero.json" type="BINDATA" /> + <include name="IDR_IO_COM_DATAVISIONSTUDIO_ROGUELIKE" file="com.datavisionstudio.roguelike.json" type="BINDATA" /> </includes> </release> </grit>
diff --git a/ash/components/hid_detection/bluetooth_hid_detector.cc b/ash/components/hid_detection/bluetooth_hid_detector.cc index becd565..4e4bd07 100644 --- a/ash/components/hid_detection/bluetooth_hid_detector.cc +++ b/ash/components/hid_detection/bluetooth_hid_detector.cc
@@ -8,6 +8,25 @@ namespace ash { namespace hid_detection { +BluetoothHidPairingState::BluetoothHidPairingState(const std::string& code, + uint8_t num_keys_entered) + : code(code), num_keys_entered(num_keys_entered) {} + +BluetoothHidPairingState::BluetoothHidPairingState( + BluetoothHidPairingState&& other) { + code = std::move(other.code); + num_keys_entered = other.num_keys_entered; +} + +BluetoothHidPairingState& BluetoothHidPairingState::operator=( + BluetoothHidPairingState&& other) { + code = std::move(other.code); + num_keys_entered = other.num_keys_entered; + return *this; +} + +BluetoothHidPairingState::~BluetoothHidPairingState() = default; + BluetoothHidDetector::BluetoothHidMetadata::BluetoothHidMetadata( std::string name, BluetoothHidType type) @@ -31,18 +50,22 @@ BluetoothHidDetector::BluetoothHidDetectionStatus::BluetoothHidDetectionStatus( absl::optional<BluetoothHidDetector::BluetoothHidMetadata> - current_pairing_device) - : current_pairing_device(std::move(current_pairing_device)) {} + current_pairing_device, + absl::optional<BluetoothHidPairingState> pairing_state) + : current_pairing_device(std::move(current_pairing_device)), + pairing_state(std::move(pairing_state)) {} BluetoothHidDetector::BluetoothHidDetectionStatus::BluetoothHidDetectionStatus( BluetoothHidDetectionStatus&& other) { current_pairing_device = std::move(other.current_pairing_device); + pairing_state = std::move(other.pairing_state); } BluetoothHidDetector::BluetoothHidDetectionStatus& BluetoothHidDetector::BluetoothHidDetectionStatus::operator=( BluetoothHidDetectionStatus&& other) { current_pairing_device = std::move(other.current_pairing_device); + pairing_state = std::move(other.pairing_state); return *this; }
diff --git a/ash/components/hid_detection/bluetooth_hid_detector.h b/ash/components/hid_detection/bluetooth_hid_detector.h index 1ae70de..1518605 100644 --- a/ash/components/hid_detection/bluetooth_hid_detector.h +++ b/ash/components/hid_detection/bluetooth_hid_detector.h
@@ -12,6 +12,21 @@ namespace ash { namespace hid_detection { +// TODO(gordonseto): Move this to HidDetectionManager when that class is +// created. +struct BluetoothHidPairingState { + BluetoothHidPairingState(const std::string& code, uint8_t num_keys_entered); + BluetoothHidPairingState(BluetoothHidPairingState&& other); + BluetoothHidPairingState& operator=(BluetoothHidPairingState&& other); + ~BluetoothHidPairingState(); + + // The code required to be entered for the HID to pair. + std::string code; + + // The number of keys of the code which have been entered. + uint8_t num_keys_entered; +}; + // Manages searching for unpaired Bluetooth human interactive devices and // automatically attempting to pairing with them if their device type is not // currently paired with. @@ -42,8 +57,9 @@ // Struct representing the current status of BluetoothHidDetector. struct BluetoothHidDetectionStatus { - explicit BluetoothHidDetectionStatus( - absl::optional<BluetoothHidMetadata> current_pairing_device); + BluetoothHidDetectionStatus( + absl::optional<BluetoothHidMetadata> current_pairing_device, + absl::optional<BluetoothHidPairingState> pairing_state); BluetoothHidDetectionStatus(BluetoothHidDetectionStatus&& other); BluetoothHidDetectionStatus& operator=(BluetoothHidDetectionStatus&& other); ~BluetoothHidDetectionStatus(); @@ -51,7 +67,9 @@ // The metadata of the device currently being paired with. absl::optional<BluetoothHidMetadata> current_pairing_device; - // TODO(crbug.com/1299099): Add |pairing_state|. + // Set if the current pairing requires a code that should be displayed to + // the user to enter. + absl::optional<BluetoothHidPairingState> pairing_state; }; class Delegate {
diff --git a/ash/components/hid_detection/bluetooth_hid_detector_impl.cc b/ash/components/hid_detection/bluetooth_hid_detector_impl.cc index 868b1c6..e3cf911 100644 --- a/ash/components/hid_detection/bluetooth_hid_detector_impl.cc +++ b/ash/components/hid_detection/bluetooth_hid_detector_impl.cc
@@ -120,13 +120,26 @@ BluetoothHidDetectorImpl::GetBluetoothHidDetectionStatus() { if (!current_pairing_device_.has_value()) { return BluetoothHidDetectionStatus( - /*current_pairing_device*/ absl::nullopt); + /*current_pairing_device*/ absl::nullopt, + /*pairing_state=*/absl::nullopt); } - // TODO(crbug.com/1299099): Add |pairing_state|. - return BluetoothHidDetectionStatus{BluetoothHidMetadata{ - base::UTF16ToUTF8(current_pairing_device_.value()->public_name), - GetBluetoothHidType(current_pairing_device_.value()).value()}}; + absl::optional<BluetoothHidPairingState> pairing_state; + if (current_pairing_state_.has_value()) { + pairing_state = BluetoothHidPairingState{ + current_pairing_state_.value().code, + current_pairing_state_.value().num_keys_entered}; + } + + absl::optional<BluetoothHidType> hid_type = + GetBluetoothHidType(current_pairing_device_.value()); + DCHECK(hid_type) << " |current_pairing_device_| has an invalid HID type"; + + return BluetoothHidDetectionStatus{ + BluetoothHidMetadata{ + base::UTF16ToUTF8(current_pairing_device_.value()->public_name), + hid_type.value()}, + std::move(pairing_state)}; } void BluetoothHidDetectorImpl::OnPropertiesUpdated( @@ -238,13 +251,23 @@ void BluetoothHidDetectorImpl::DisplayPinCode( const std::string& pin_code, mojo::PendingReceiver<KeyEnteredHandler> handler) { - // TODO(crbug/1299099): Implement. + DCHECK(current_pairing_device_) + << "DisplayPinCode() called with no |current_pairing_device_|"; + HID_LOG(EVENT) << "DisplayPinCode auth required for " + << current_pairing_device_.value()->id + << ", pin code: " << pin_code; + RequirePairingCode(pin_code, std::move(handler)); } void BluetoothHidDetectorImpl::DisplayPasskey( const std::string& passkey, mojo::PendingReceiver<KeyEnteredHandler> handler) { - // TODO(crbug/1299099): Implement. + DCHECK(current_pairing_device_) + << "DisplayPasskey() called with no |current_pairing_device_|"; + HID_LOG(EVENT) << "DisplayPasskey auth required for " + << current_pairing_device_.value()->id + << ", passkey: " << passkey; + RequirePairingCode(passkey, std::move(handler)); } void BluetoothHidDetectorImpl::ConfirmPasskey(const std::string& passkey, @@ -269,6 +292,18 @@ std::move(callback).Run(/*confirmed=*/true); } +void BluetoothHidDetectorImpl::HandleKeyEntered(uint8_t num_keys_entered) { + DCHECK(current_pairing_device_) + << "HandleKeyEntered() called with no |current_pairing_device_|"; + DCHECK(current_pairing_state_) + << "HandleKeyEntered() called with no |current_pairing_state_|"; + + HID_LOG(EVENT) << "HandleKeyEntered called with " << num_keys_entered + << " keys entered"; + current_pairing_state_->num_keys_entered = num_keys_entered; + delegate_->OnBluetoothHidStatusChanged(); +} + bool BluetoothHidDetectorImpl::IsHidTypeMissing( BluetoothHidDetector::BluetoothHidType hid_type) { switch (hid_type) { @@ -359,7 +394,9 @@ queued_device_ids_.erase(current_pairing_device_.value()->id); current_pairing_device_.reset(); + current_pairing_state_.reset(); device_pairing_delegate_receiver_.reset(); + key_entered_handler_receiver_.reset(); delegate_->OnBluetoothHidStatusChanged(); ProcessQueue(); } @@ -369,9 +406,11 @@ bluetooth_discovery_delegate_receiver_.reset(); device_pairing_handler_remote_.reset(); device_pairing_delegate_receiver_.reset(); + key_entered_handler_receiver_.reset(); // Reset queue-related properties. current_pairing_device_.reset(); + current_pairing_state_.reset(); queue_ = std::make_unique<base::queue< chromeos::bluetooth_config::mojom::BluetoothDevicePropertiesPtr>>(); queued_device_ids_.clear(); @@ -380,5 +419,19 @@ delegate_->OnBluetoothHidStatusChanged(); } +void BluetoothHidDetectorImpl::RequirePairingCode( + const std::string& code, + mojo::PendingReceiver<chromeos::bluetooth_config::mojom::KeyEnteredHandler> + handler) { + DCHECK(!current_pairing_state_) << "RequirePairingCode() called " + << "with |current_pairing_state_| already " + << "initialized"; + DCHECK(!key_entered_handler_receiver_.is_bound()); + key_entered_handler_receiver_.Bind(std::move(handler)); + current_pairing_state_ = + BluetoothHidPairingState{code, /*num_keys_entered=*/0u}; + delegate_->OnBluetoothHidStatusChanged(); +} + } // namespace hid_detection } // namespace ash
diff --git a/ash/components/hid_detection/bluetooth_hid_detector_impl.h b/ash/components/hid_detection/bluetooth_hid_detector_impl.h index 8ac087f..23dfbae 100644 --- a/ash/components/hid_detection/bluetooth_hid_detector_impl.h +++ b/ash/components/hid_detection/bluetooth_hid_detector_impl.h
@@ -21,7 +21,8 @@ : public BluetoothHidDetector, public chromeos::bluetooth_config::mojom::SystemPropertiesObserver, public chromeos::bluetooth_config::mojom::BluetoothDiscoveryDelegate, - public chromeos::bluetooth_config::mojom::DevicePairingDelegate { + public chromeos::bluetooth_config::mojom::DevicePairingDelegate, + public chromeos::bluetooth_config::mojom::KeyEnteredHandler { public: BluetoothHidDetectorImpl(); ~BluetoothHidDetectorImpl() override; @@ -71,7 +72,7 @@ chromeos::bluetooth_config::mojom::BluetoothDevicePropertiesPtr> discovered_devices) override; - // mojom::DevicePairingDelegate: + // chromeos::bluetooth_config::mojom::DevicePairingDelegate void RequestPinCode(RequestPinCodeCallback callback) override; void RequestPasskey(RequestPasskeyCallback callback) override; void DisplayPinCode(const std::string& pin_code, @@ -86,6 +87,9 @@ ConfirmPasskeyCallback callback) override; void AuthorizePairing(AuthorizePairingCallback callback) override; + // chromeos::bluetooth_config::mojom::KeyEnteredHandler + void HandleKeyEntered(uint8_t num_keys_entered) override; + bool IsHidTypeMissing(BluetoothHidDetector::BluetoothHidType hid_type); bool ShouldAttemptToPairWithDevice( const chromeos::bluetooth_config::mojom::BluetoothDevicePropertiesPtr& @@ -102,6 +106,13 @@ // Resets properties related to discovery, pairing handlers and queueing. void ResetDiscoveryState(); + // Informs |delegate_| "DisplayPasskey" or "DisplayPinCode" pairing + // authorization is required. + void RequirePairingCode( + const std::string& code, + mojo::PendingReceiver< + chromeos::bluetooth_config::mojom::KeyEnteredHandler> handler); + // Map that contains the ids of the devices in |queue_|. base::flat_set<std::string> queued_device_ids_; @@ -116,6 +127,10 @@ chromeos::bluetooth_config::mojom::BluetoothDevicePropertiesPtr> current_pairing_device_; + // If defined, indicates that the current pairing requires an authorization + // code that should be displayed to the user for them to enter into the HID. + absl::optional<BluetoothHidPairingState> current_pairing_state_; + Delegate* delegate_ = nullptr; InputDevicesStatus input_devices_status_; State state_ = kNotStarted; @@ -130,6 +145,8 @@ device_pairing_handler_remote_; mojo::Receiver<chromeos::bluetooth_config::mojom::DevicePairingDelegate> device_pairing_delegate_receiver_{this}; + mojo::Receiver<chromeos::bluetooth_config::mojom::KeyEnteredHandler> + key_entered_handler_receiver_{this}; base::WeakPtrFactory<BluetoothHidDetectorImpl> weak_ptr_factory_{this}; };
diff --git a/ash/components/hid_detection/bluetooth_hid_detector_impl_unittest.cc b/ash/components/hid_detection/bluetooth_hid_detector_impl_unittest.cc index ea28c962..0235f9a 100644 --- a/ash/components/hid_detection/bluetooth_hid_detector_impl_unittest.cc +++ b/ash/components/hid_detection/bluetooth_hid_detector_impl_unittest.cc
@@ -18,6 +18,10 @@ #include "chromeos/services/bluetooth_config/scoped_bluetooth_config_test_helper.h" #include "testing/gtest/include/gtest/gtest.h" +namespace ash { +namespace hid_detection { +namespace { + using ash::hid_detection::BluetoothHidDetector; using chromeos::bluetooth_config::FakeDevicePairingHandler; using chromeos::bluetooth_config::mojom::BluetoothDeviceProperties; @@ -26,11 +30,11 @@ using chromeos::bluetooth_config::mojom::DeviceType; using chromeos::bluetooth_config::mojom::PairedBluetoothDeviceProperties; using chromeos::bluetooth_config::mojom::PairedBluetoothDevicePropertiesPtr; +using BluetoothHidMetadata = BluetoothHidDetector::BluetoothHidMetadata; +using BluetoothHidType = BluetoothHidDetector::BluetoothHidType; +using InputDevicesStatus = BluetoothHidDetector::InputDevicesStatus; -namespace ash { -namespace hid_detection { -namespace { - +const char kTestPinCode[] = "123456"; const uint32_t kTestPasskey = 123456; class FakeBluetoothHidDetectorDelegate : public BluetoothHidDetector::Delegate { @@ -91,17 +95,11 @@ base::RunLoop().RunUntilIdle(); } - void SetInputDevicesStatus( - BluetoothHidDetector::InputDevicesStatus input_devices_status) { + void SetInputDevicesStatus(InputDevicesStatus input_devices_status) { bluetooth_hid_detector()->SetInputDevicesStatus(input_devices_status); base::RunLoop().RunUntilIdle(); } - const BluetoothHidDetector::BluetoothHidDetectionStatus - GetBluetoothHidDetectionStatus() { - return bluetooth_hid_detector()->GetBluetoothHidDetectionStatus(); - } - // Simulates Bluetooth being toggled by a UI surface. This sets the state of // the Bluetooth adapter and persists that state which is restored when HID // detection finishes. @@ -155,7 +153,10 @@ base::RunLoop().RunUntilIdle(); } - void RemoveUnpairedDevice(const std::string& device_id) { + void MockPairDeviceFinished( + const std::string& device_id, + FakeDevicePairingHandler* device_pairing_handler, + absl::optional<device::ConnectionFailureReason> failure_reason) { unpaired_devices_.erase( std::remove_if(unpaired_devices_.begin(), unpaired_devices_.end(), [device_id](BluetoothDevicePropertiesPtr const& device) { @@ -165,6 +166,9 @@ UpdateDiscoveredDevicesProviderDevices(); base::RunLoop().RunUntilIdle(); + + device_pairing_handler->SimulatePairDeviceFinished(failure_reason); + EXPECT_TRUE(device_pairing_handler->current_pairing_device_id().empty()); } std::vector<FakeDevicePairingHandler*> GetDevicePairingHandlers() { @@ -173,6 +177,31 @@ ->device_pairing_handlers(); } + void AssertBluetoothHidDetectionStatus( + absl::optional<BluetoothHidDetector::BluetoothHidMetadata> + current_pairing_device, + absl::optional<BluetoothHidPairingState> pairing_state) { + EXPECT_EQ( + current_pairing_device.has_value(), + GetBluetoothHidDetectionStatus().current_pairing_device.has_value()); + if (current_pairing_device.has_value()) { + EXPECT_EQ(current_pairing_device->name, + GetBluetoothHidDetectionStatus().current_pairing_device->name); + EXPECT_EQ(current_pairing_device->type, + GetBluetoothHidDetectionStatus().current_pairing_device->type); + } + + EXPECT_EQ(pairing_state.has_value(), + GetBluetoothHidDetectionStatus().pairing_state.has_value()); + if (pairing_state.has_value()) { + EXPECT_EQ(pairing_state->code, + GetBluetoothHidDetectionStatus().pairing_state->code); + EXPECT_EQ( + pairing_state->num_keys_entered, + GetBluetoothHidDetectionStatus().pairing_state->num_keys_entered); + } + } + private: void UpdateDiscoveredDevicesProviderDevices() { std::vector<BluetoothDevicePropertiesPtr> unpaired_devices; @@ -183,6 +212,11 @@ ->SetDiscoveredDevices(std::move(unpaired_devices)); } + const BluetoothHidDetector::BluetoothHidDetectionStatus + GetBluetoothHidDetectionStatus() { + return bluetooth_hid_detector()->GetBluetoothHidDetectionStatus(); + } + BluetoothHidDetectorImpl* bluetooth_hid_detector() { return bluetooth_hid_detector_.get(); } @@ -343,10 +377,9 @@ EXPECT_EQ(device_id2, GetDevicePairingHandlers()[0]->current_pairing_device_id()); EXPECT_EQ(1u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id2, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kKeyboard, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id2, BluetoothHidType::kKeyboard), + /*pairing_state=*/absl::nullopt); } TEST_F(BluetoothHidDetectorImplTest, AddDevices_TypeNotMissing) { @@ -365,10 +398,9 @@ EXPECT_EQ(device_id2, GetDevicePairingHandlers()[0]->current_pairing_device_id()); EXPECT_EQ(1u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id2, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kKeyboard, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id2, BluetoothHidType::kKeyboard), + /*pairing_state=*/absl::nullopt); } TEST_F(BluetoothHidDetectorImplTest, @@ -379,50 +411,48 @@ EXPECT_TRUE( GetDevicePairingHandlers()[0]->current_pairing_device_id().empty()); EXPECT_EQ(0u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_FALSE(GetBluetoothHidDetectionStatus().current_pairing_device); + AssertBluetoothHidDetectionStatus( + /*current_pairing_device=*/absl::nullopt, + /*pairing_state=*/absl::nullopt); std::string device_id1; AddUnpairedDevice(&device_id1, DeviceType::kTablet); EXPECT_EQ(device_id1, GetDevicePairingHandlers()[0]->current_pairing_device_id()); EXPECT_EQ(1u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id1, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kPointer, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kPointer), + /*pairing_state=*/absl::nullopt); // Mock |device_id1| being paired. BluetoothHidDetectorImpl should not inform // the delegate or move to the next device in queue until the input devices // status has been updated. - RemoveUnpairedDevice(device_id1); - GetDevicePairingHandlers()[0]->SimulatePairDeviceFinished( - /*failure_reason=*/absl::nullopt); - EXPECT_TRUE( - GetDevicePairingHandlers()[0]->current_pairing_device_id().empty()); + MockPairDeviceFinished(device_id1, GetDevicePairingHandlers()[0], + /*failure_reason=*/absl::nullopt); EXPECT_EQ(1u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id1, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kPointer, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kPointer), + /*pairing_state=*/absl::nullopt); // Mock |device_id1| being registered as connected. The next device in the // queue should now be processed. - SetInputDevicesStatus(BluetoothHidDetector::InputDevicesStatus{ - .pointer_is_missing = false, .keyboard_is_missing = true}); + SetInputDevicesStatus(InputDevicesStatus{.pointer_is_missing = false, + .keyboard_is_missing = true}); EXPECT_TRUE( GetDevicePairingHandlers()[0]->current_pairing_device_id().empty()); EXPECT_EQ(2u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_FALSE(GetBluetoothHidDetectionStatus().current_pairing_device); + AssertBluetoothHidDetectionStatus( + /*current_pairing_device=*/absl::nullopt, + /*pairing_state=*/absl::nullopt); std::string device_id2; AddUnpairedDevice(&device_id2, DeviceType::kKeyboard); EXPECT_EQ(device_id2, GetDevicePairingHandlers()[0]->current_pairing_device_id()); EXPECT_EQ(3u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id2, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kKeyboard, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id2, BluetoothHidType::kKeyboard), + /*pairing_state=*/absl::nullopt); } TEST_F(BluetoothHidDetectorImplTest, AddDevices_BatchAfterStartingDetection) { @@ -432,17 +462,18 @@ EXPECT_TRUE( GetDevicePairingHandlers()[0]->current_pairing_device_id().empty()); EXPECT_EQ(0u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_FALSE(GetBluetoothHidDetectionStatus().current_pairing_device); + AssertBluetoothHidDetectionStatus( + /*current_pairing_device=*/absl::nullopt, + /*pairing_state=*/absl::nullopt); std::string device_id1; AddUnpairedDevice(&device_id1, DeviceType::kMouse); EXPECT_EQ(device_id1, GetDevicePairingHandlers()[0]->current_pairing_device_id()); EXPECT_EQ(1u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id1, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kPointer, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kPointer), + /*pairing_state=*/absl::nullopt); std::string device_id2; AddUnpairedDevice(&device_id2, DeviceType::kKeyboardMouseCombo); @@ -451,28 +482,23 @@ // Mock |device_id1| being paired. BluetoothHidDetectorImpl should not inform // the delegate or move to the next device in queue until the input devices // status has been updated. - RemoveUnpairedDevice(device_id1); - GetDevicePairingHandlers()[0]->SimulatePairDeviceFinished( - /*failure_reason=*/absl::nullopt); - EXPECT_TRUE( - GetDevicePairingHandlers()[0]->current_pairing_device_id().empty()); + MockPairDeviceFinished(device_id1, GetDevicePairingHandlers()[0], + /*failure_reason=*/absl::nullopt); EXPECT_EQ(1u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id1, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kPointer, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kPointer), + /*pairing_state=*/absl::nullopt); // Mock |device_id1| being registered as connected. |device_id2| should be // attempted to be paired with. - SetInputDevicesStatus(BluetoothHidDetector::InputDevicesStatus{ - .pointer_is_missing = false, .keyboard_is_missing = true}); + SetInputDevicesStatus(InputDevicesStatus{.pointer_is_missing = false, + .keyboard_is_missing = true}); EXPECT_EQ(device_id2, GetDevicePairingHandlers()[0]->current_pairing_device_id()); EXPECT_EQ(3u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id2, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kKeyboardPointerCombo, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id2, BluetoothHidType::kKeyboardPointerCombo), + /*pairing_state=*/absl::nullopt); } TEST_F(BluetoothHidDetectorImplTest, @@ -493,46 +519,39 @@ EXPECT_EQ(device_id1, GetDevicePairingHandlers()[0]->current_pairing_device_id()); EXPECT_EQ(1u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id1, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kPointer, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kPointer), + /*pairing_state=*/absl::nullopt); // Mock |device_id1| being paired. BluetoothHidDetectorImpl should not inform // the delegate or move to the next device in queue until the input devices // status has been updated. - RemoveUnpairedDevice(device_id1); - GetDevicePairingHandlers()[0]->SimulatePairDeviceFinished( - /*failure_reason=*/absl::nullopt); - EXPECT_TRUE( - GetDevicePairingHandlers()[0]->current_pairing_device_id().empty()); + MockPairDeviceFinished(device_id1, GetDevicePairingHandlers()[0], + /*failure_reason=*/absl::nullopt); EXPECT_EQ(1u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id1, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kPointer, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kPointer), + /*pairing_state=*/absl::nullopt); // Mock |device_id1| being registered as connected. |device_id3| should be // attempted to be paired with. - SetInputDevicesStatus(BluetoothHidDetector::InputDevicesStatus{ - .pointer_is_missing = false, .keyboard_is_missing = true}); + SetInputDevicesStatus(InputDevicesStatus{.pointer_is_missing = false, + .keyboard_is_missing = true}); EXPECT_EQ(device_id3, GetDevicePairingHandlers()[0]->current_pairing_device_id()); EXPECT_EQ(3u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id3, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kKeyboard, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id3, BluetoothHidType::kKeyboard), + /*pairing_state=*/absl::nullopt); // Mock |device_id3| pairing failing. BluetoothHidDetectorImpl should move to // the next device in the queue immediately. - RemoveUnpairedDevice(device_id3); - GetDevicePairingHandlers()[0]->SimulatePairDeviceFinished( - device::ConnectionFailureReason::kFailed); - EXPECT_TRUE( - GetDevicePairingHandlers()[0]->current_pairing_device_id().empty()); + MockPairDeviceFinished(device_id3, GetDevicePairingHandlers()[0], + device::ConnectionFailureReason::kFailed); EXPECT_EQ(4u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_FALSE(GetBluetoothHidDetectionStatus().current_pairing_device); + AssertBluetoothHidDetectionStatus( + /*current_pairing_device=*/absl::nullopt, + /*pairing_state=*/absl::nullopt); } TEST_F(BluetoothHidDetectorImplTest, DisconnectDevice) { @@ -542,13 +561,17 @@ EXPECT_TRUE( GetDevicePairingHandlers()[0]->current_pairing_device_id().empty()); EXPECT_EQ(0u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_FALSE(GetBluetoothHidDetectionStatus().current_pairing_device); + AssertBluetoothHidDetectionStatus( + /*current_pairing_device=*/absl::nullopt, + /*pairing_state=*/absl::nullopt); // Set both devices to connected. - SetInputDevicesStatus(BluetoothHidDetector::InputDevicesStatus{ - .pointer_is_missing = false, .keyboard_is_missing = false}); + SetInputDevicesStatus(InputDevicesStatus{.pointer_is_missing = false, + .keyboard_is_missing = false}); EXPECT_EQ(0u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_FALSE(GetBluetoothHidDetectionStatus().current_pairing_device); + AssertBluetoothHidDetectionStatus( + /*current_pairing_device=*/absl::nullopt, + /*pairing_state=*/absl::nullopt); // Add a discovered device. Nothing should happen. std::string device_id1; @@ -556,11 +579,13 @@ EXPECT_TRUE( GetDevicePairingHandlers()[0]->current_pairing_device_id().empty()); EXPECT_EQ(0u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_FALSE(GetBluetoothHidDetectionStatus().current_pairing_device); + AssertBluetoothHidDetectionStatus( + /*current_pairing_device=*/absl::nullopt, + /*pairing_state=*/absl::nullopt); // Mock the pointer no longer being connected. - SetInputDevicesStatus(BluetoothHidDetector::InputDevicesStatus{ - .pointer_is_missing = true, .keyboard_is_missing = false}); + SetInputDevicesStatus(InputDevicesStatus{.pointer_is_missing = true, + .keyboard_is_missing = false}); // Add another device to trigger OnDiscoveredDevicesListChanged(). std::string device_id2; @@ -568,10 +593,9 @@ EXPECT_EQ(device_id1, GetDevicePairingHandlers()[0]->current_pairing_device_id()); EXPECT_EQ(1u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id1, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kPointer, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kPointer), + /*pairing_state=*/absl::nullopt); } TEST_F(BluetoothHidDetectorImplTest, ConnectDeviceTypeDuringPairing) { @@ -588,44 +612,40 @@ EXPECT_EQ(device_id1, GetDevicePairingHandlers()[0]->current_pairing_device_id()); EXPECT_EQ(1u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id1, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kPointer, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kPointer), + /*pairing_state=*/absl::nullopt); // Mock a keyboard being connected. Nothing should happen. - SetInputDevicesStatus(BluetoothHidDetector::InputDevicesStatus{ - .pointer_is_missing = true, .keyboard_is_missing = false}); + SetInputDevicesStatus(InputDevicesStatus{.pointer_is_missing = true, + .keyboard_is_missing = false}); EXPECT_EQ(device_id1, GetDevicePairingHandlers()[0]->current_pairing_device_id()); EXPECT_EQ(1u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id1, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kPointer, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kPointer), + /*pairing_state=*/absl::nullopt); // Mock keyboard being disconnected. Nothing should happen. - SetInputDevicesStatus(BluetoothHidDetector::InputDevicesStatus{ - .pointer_is_missing = true, .keyboard_is_missing = true}); + SetInputDevicesStatus(InputDevicesStatus{.pointer_is_missing = true, + .keyboard_is_missing = true}); EXPECT_EQ(device_id1, GetDevicePairingHandlers()[0]->current_pairing_device_id()); EXPECT_EQ(1u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id1, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kPointer, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kPointer), + /*pairing_state=*/absl::nullopt); // Mock a pointer being connected. This should cancel pairing with // |device_id1|. - SetInputDevicesStatus(BluetoothHidDetector::InputDevicesStatus{ - .pointer_is_missing = false, .keyboard_is_missing = true}); + SetInputDevicesStatus(InputDevicesStatus{.pointer_is_missing = false, + .keyboard_is_missing = true}); EXPECT_EQ(device_id2, GetDevicePairingHandlers()[0]->current_pairing_device_id()); EXPECT_EQ(3u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id2, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kKeyboard, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id2, BluetoothHidType::kKeyboard), + /*pairing_state=*/absl::nullopt); } TEST_F(BluetoothHidDetectorImplTest, @@ -643,31 +663,31 @@ EXPECT_EQ(device_id1, GetDevicePairingHandlers()[0]->current_pairing_device_id()); EXPECT_EQ(1u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id1, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kKeyboardPointerCombo, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kKeyboardPointerCombo), + /*pairing_state=*/absl::nullopt); // Mock a keyboard being connected. This should not cancel pairing with // |device_id1|. - SetInputDevicesStatus(BluetoothHidDetector::InputDevicesStatus{ - .pointer_is_missing = true, .keyboard_is_missing = false}); + SetInputDevicesStatus(InputDevicesStatus{.pointer_is_missing = true, + .keyboard_is_missing = false}); EXPECT_EQ(device_id1, GetDevicePairingHandlers()[0]->current_pairing_device_id()); EXPECT_EQ(1u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id1, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kKeyboardPointerCombo, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kKeyboardPointerCombo), + /*pairing_state=*/absl::nullopt); // Mock a pointer also being connected. This should cancel pairing with // |device_id1|. - SetInputDevicesStatus(BluetoothHidDetector::InputDevicesStatus{ - .pointer_is_missing = false, .keyboard_is_missing = false}); + SetInputDevicesStatus(InputDevicesStatus{.pointer_is_missing = false, + .keyboard_is_missing = false}); EXPECT_TRUE( GetDevicePairingHandlers()[0]->current_pairing_device_id().empty()); EXPECT_EQ(2u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_FALSE(GetBluetoothHidDetectionStatus().current_pairing_device); + AssertBluetoothHidDetectionStatus( + /*current_pairing_device=*/absl::nullopt, + /*pairing_state=*/absl::nullopt); } TEST_F(BluetoothHidDetectorImplTest, AdapterDisablesDuringPairing) { @@ -684,16 +704,26 @@ EXPECT_EQ(device_id1, GetDevicePairingHandlers()[0]->current_pairing_device_id()); EXPECT_EQ(1u, delegate->num_bluetooth_hid_status_changed_calls()); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kPointer), + /*pairing_state=*/absl::nullopt); + + // Simulate "DisplayPasskey" authorization required. + GetDevicePairingHandlers()[0]->SimulateDisplayPasskey(kTestPasskey); EXPECT_EQ(device_id1, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kPointer, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + GetDevicePairingHandlers()[0]->current_pairing_device_id()); + EXPECT_EQ(2u, delegate->num_bluetooth_hid_status_changed_calls()); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kPointer), + BluetoothHidPairingState(kTestPinCode, /*num_keys_entered=*/0u)); // Mock the adapter disabling. SetAdapterState(BluetoothSystemState::kDisabled); EXPECT_FALSE(IsDiscoverySessionActive()); - EXPECT_EQ(2u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_FALSE(GetBluetoothHidDetectionStatus().current_pairing_device); + EXPECT_EQ(3u, delegate->num_bluetooth_hid_status_changed_calls()); + AssertBluetoothHidDetectionStatus( + /*current_pairing_device=*/absl::nullopt, + /*pairing_state=*/absl::nullopt); // Mock the adapter re-enabling Bluetooth. This should cause // BluetoothHidDetector to start discovery again. The first device should be @@ -703,6 +733,19 @@ EXPECT_EQ(2u, GetDevicePairingHandlers().size()); EXPECT_EQ(device_id1, GetDevicePairingHandlers()[1]->current_pairing_device_id()); + EXPECT_EQ(4u, delegate->num_bluetooth_hid_status_changed_calls()); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kPointer), + /*pairing_state=*/absl::nullopt); + + // Simulate "DisplayPincode" authorization required. + GetDevicePairingHandlers()[1]->SimulateDisplayPinCode(kTestPinCode); + EXPECT_EQ(device_id1, + GetDevicePairingHandlers()[1]->current_pairing_device_id()); + EXPECT_EQ(5u, delegate->num_bluetooth_hid_status_changed_calls()); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kPointer), + BluetoothHidPairingState(kTestPinCode, /*num_keys_entered=*/0u)); } TEST_F(BluetoothHidDetectorImplTest, DetectionStopsStartsDuringPairing) { @@ -719,16 +762,26 @@ EXPECT_EQ(device_id1, GetDevicePairingHandlers()[0]->current_pairing_device_id()); EXPECT_EQ(1u, delegate1->num_bluetooth_hid_status_changed_calls()); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kPointer), + /*pairing_state=*/absl::nullopt); + + // Simulate "DisplayPincode" authorization required. + GetDevicePairingHandlers()[0]->SimulateDisplayPinCode(kTestPinCode); EXPECT_EQ(device_id1, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kPointer, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + GetDevicePairingHandlers()[0]->current_pairing_device_id()); + EXPECT_EQ(2u, delegate1->num_bluetooth_hid_status_changed_calls()); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kPointer), + BluetoothHidPairingState(kTestPinCode, /*num_keys_entered=*/0u)); // Stop detection. StopBluetoothHidDetection(); EXPECT_FALSE(IsDiscoverySessionActive()); - EXPECT_EQ(2u, delegate1->num_bluetooth_hid_status_changed_calls()); - EXPECT_FALSE(GetBluetoothHidDetectionStatus().current_pairing_device); + EXPECT_EQ(3u, delegate1->num_bluetooth_hid_status_changed_calls()); + AssertBluetoothHidDetectionStatus( + /*current_pairing_device=*/absl::nullopt, + /*pairing_state=*/absl::nullopt); // Start detection again. The first device should be attempted to be paired // with again. @@ -738,10 +791,18 @@ EXPECT_EQ(device_id1, GetDevicePairingHandlers()[1]->current_pairing_device_id()); EXPECT_EQ(1u, delegate2->num_bluetooth_hid_status_changed_calls()); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kPointer), + /*pairing_state=*/absl::nullopt); + + // Simulate "DisplayPasskey" authorization required. + GetDevicePairingHandlers()[1]->SimulateDisplayPasskey(kTestPasskey); EXPECT_EQ(device_id1, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kPointer, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + GetDevicePairingHandlers()[1]->current_pairing_device_id()); + EXPECT_EQ(2u, delegate2->num_bluetooth_hid_status_changed_calls()); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kPointer), + BluetoothHidPairingState(kTestPinCode, /*num_keys_entered=*/0u)); } TEST_F(BluetoothHidDetectorImplTest, AddDevices_UnsupportedAuthorizations) { @@ -761,10 +822,9 @@ EXPECT_EQ(device_id1, GetDevicePairingHandlers()[0]->current_pairing_device_id()); EXPECT_EQ(1u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id1, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kPointer, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kPointer), + /*pairing_state=*/absl::nullopt); // Simulate "RequestPinCode" authorization required. This should cancel the // pairing. |device_id2| should be attempted to be paired with. @@ -772,10 +832,9 @@ EXPECT_EQ(device_id2, GetDevicePairingHandlers()[0]->current_pairing_device_id()); EXPECT_EQ(3u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id2, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kPointer, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id2, BluetoothHidType::kPointer), + /*pairing_state=*/absl::nullopt); // Simulate "RequestPasskey" authorization required. This should cancel the // pairing. |device_id3| should be attempted to be paired with. @@ -783,10 +842,9 @@ EXPECT_EQ(device_id3, GetDevicePairingHandlers()[0]->current_pairing_device_id()); EXPECT_EQ(5u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id3, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kKeyboardPointerCombo, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id3, BluetoothHidType::kKeyboardPointerCombo), + /*pairing_state=*/absl::nullopt); // Simulate "ConfirmPasskey" authorization required. This should cancel the // pairing. @@ -795,7 +853,9 @@ EXPECT_TRUE( GetDevicePairingHandlers()[0]->current_pairing_device_id().empty()); EXPECT_EQ(6u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_FALSE(GetBluetoothHidDetectionStatus().current_pairing_device); + AssertBluetoothHidDetectionStatus( + /*current_pairing_device=*/absl::nullopt, + /*pairing_state=*/absl::nullopt); } TEST_F(BluetoothHidDetectorImplTest, AddDevice_AuthorizePairingAuth) { @@ -809,10 +869,9 @@ EXPECT_EQ(device_id, GetDevicePairingHandlers()[0]->current_pairing_device_id()); EXPECT_EQ(1u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kKeyboard, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id, BluetoothHidType::kKeyboard), + /*pairing_state=*/absl::nullopt); EXPECT_FALSE(GetDevicePairingHandlers()[0]->last_confirm()); // Simulate "AuthorizePairing" authorization required. The pairing should be @@ -824,18 +883,114 @@ EXPECT_TRUE( GetDevicePairingHandlers()[0]->current_pairing_device_id().empty()); EXPECT_EQ(1u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_EQ(device_id, - GetBluetoothHidDetectionStatus().current_pairing_device->name); - EXPECT_EQ(BluetoothHidDetector::BluetoothHidType::kKeyboard, - GetBluetoothHidDetectionStatus().current_pairing_device->type); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id, BluetoothHidType::kKeyboard), + /*pairing_state=*/absl::nullopt); // Mock the device being registered as connected. - SetInputDevicesStatus(BluetoothHidDetector::InputDevicesStatus{ - .pointer_is_missing = true, .keyboard_is_missing = false}); + SetInputDevicesStatus(InputDevicesStatus{.pointer_is_missing = true, + .keyboard_is_missing = false}); EXPECT_TRUE( GetDevicePairingHandlers()[0]->current_pairing_device_id().empty()); EXPECT_EQ(2u, delegate->num_bluetooth_hid_status_changed_calls()); - EXPECT_FALSE(GetBluetoothHidDetectionStatus().current_pairing_device); + AssertBluetoothHidDetectionStatus( + /*current_pairing_device=*/absl::nullopt, + /*pairing_state=*/absl::nullopt); +} + +TEST_F(BluetoothHidDetectorImplTest, AddDevice_DisplayCodeAuths) { + std::string device_id1; + AddUnpairedDevice(&device_id1, DeviceType::kKeyboard); + + std::string device_id2; + AddUnpairedDevice(&device_id2, DeviceType::kMouse); + + // Begin HID detection. |device_id1| should be attempted to be paired with. + FakeBluetoothHidDetectorDelegate* delegate = StartBluetoothHidDetection(); + EXPECT_TRUE(IsDiscoverySessionActive()); + EXPECT_EQ(1u, GetDevicePairingHandlers().size()); + EXPECT_EQ(device_id1, + GetDevicePairingHandlers()[0]->current_pairing_device_id()); + EXPECT_EQ(1u, delegate->num_bluetooth_hid_status_changed_calls()); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kKeyboard), + /*pairing_state=*/absl::nullopt); + + // Simulate "DisplayPinCode" authorization required. + GetDevicePairingHandlers()[0]->SimulateDisplayPinCode(kTestPinCode); + EXPECT_EQ(device_id1, + GetDevicePairingHandlers()[0]->current_pairing_device_id()); + EXPECT_EQ(2u, delegate->num_bluetooth_hid_status_changed_calls()); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kKeyboard), + BluetoothHidPairingState(kTestPinCode, /*num_keys_entered=*/0u)); + + // Simulate keys being entered consecutively. The delegate should be informed + // each time. + for (uint32_t num_keys_entered = 1; + num_keys_entered <= std::strlen(kTestPinCode); num_keys_entered++) { + GetDevicePairingHandlers()[0]->SimulateKeysEntered(num_keys_entered); + EXPECT_EQ(device_id1, + GetDevicePairingHandlers()[0]->current_pairing_device_id()); + EXPECT_EQ(2u + num_keys_entered, + delegate->num_bluetooth_hid_status_changed_calls()); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kKeyboard), + BluetoothHidPairingState(kTestPinCode, num_keys_entered)); + } + EXPECT_EQ(8u, delegate->num_bluetooth_hid_status_changed_calls()); + + // Mock |device_id1| being paired. BluetoothHidDetectorImpl should not inform + // the delegate or move to the next device in queue until the input devices + // status has been updated. + MockPairDeviceFinished(device_id1, GetDevicePairingHandlers()[0], + /*failure_reason=*/absl::nullopt); + EXPECT_EQ(8u, delegate->num_bluetooth_hid_status_changed_calls()); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id1, BluetoothHidType::kKeyboard), + BluetoothHidPairingState(kTestPinCode, /*num_keys_entered=*/6u)); + + // Mock |device_id1| being registered as connected. |device_id2| should be + // attempted to be paired with. + SetInputDevicesStatus(InputDevicesStatus{.pointer_is_missing = true, + .keyboard_is_missing = false}); + EXPECT_EQ(device_id2, + GetDevicePairingHandlers()[0]->current_pairing_device_id()); + EXPECT_EQ(10u, delegate->num_bluetooth_hid_status_changed_calls()); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id2, BluetoothHidType::kPointer), + /*pairing_state=*/absl::nullopt); + + // Simulate "DisplayPasskey" authorization required. + GetDevicePairingHandlers()[0]->SimulateDisplayPasskey(kTestPasskey); + EXPECT_EQ(device_id2, + GetDevicePairingHandlers()[0]->current_pairing_device_id()); + EXPECT_EQ(11u, delegate->num_bluetooth_hid_status_changed_calls()); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id2, BluetoothHidType::kPointer), + BluetoothHidPairingState(kTestPinCode, /*num_keys_entered=*/0u)); + + // Simulate keys being entered consecutively. The delegate should be informed + // each time. + for (uint32_t num_keys_entered = 1; num_keys_entered <= 6u; + num_keys_entered++) { + GetDevicePairingHandlers()[0]->SimulateKeysEntered(num_keys_entered); + EXPECT_EQ(device_id2, + GetDevicePairingHandlers()[0]->current_pairing_device_id()); + EXPECT_EQ(11u + num_keys_entered, + delegate->num_bluetooth_hid_status_changed_calls()); + AssertBluetoothHidDetectionStatus( + BluetoothHidMetadata(device_id2, BluetoothHidType::kPointer), + BluetoothHidPairingState(kTestPinCode, num_keys_entered)); + } + EXPECT_EQ(17u, delegate->num_bluetooth_hid_status_changed_calls()); + + // Mock |device_id2| pairing failing. + MockPairDeviceFinished(device_id2, GetDevicePairingHandlers()[0], + device::ConnectionFailureReason::kAuthFailed); + EXPECT_EQ(18u, delegate->num_bluetooth_hid_status_changed_calls()); + AssertBluetoothHidDetectionStatus(/*current_pairing_device=*/absl::nullopt, + /*pairing_state=*/absl::nullopt); } } // namespace hid_detection
diff --git a/ash/constants/ash_features.cc b/ash/constants/ash_features.cc index cbc452f4..e587e845 100644 --- a/ash/constants/ash_features.cc +++ b/ash/constants/ash_features.cc
@@ -1131,7 +1131,7 @@ // from the apps grid. This feature was previously named "AppListBubble". // https://crbug.com/1204551 const base::Feature kProductivityLauncher{"ProductivityLauncher", - base::FEATURE_DISABLED_BY_DEFAULT}; + base::FEATURE_ENABLED_BY_DEFAULT}; // Controls whether to enable Projector. const base::Feature kProjector{"Projector", base::FEATURE_DISABLED_BY_DEFAULT};
diff --git a/ash/search_box/search_box_constants.h b/ash/search_box/search_box_constants.h index 7018e2e..395b9244 100644 --- a/ash/search_box/search_box_constants.h +++ b/ash/search_box/search_box_constants.h
@@ -37,10 +37,16 @@ constexpr int kSearchBoxPreferredHeight = 48; // The size of the icon in the search box. -constexpr int kSearchBoxIconSize = 24; +constexpr int kClassicSearchBoxIconSize = 24; // The size of the image button in the search box. -constexpr int kSearchBoxButtonSizeDip = 40; +constexpr int kClassicSearchBoxButtonSizeDip = 40; + +// The size of the icon in the search box. +constexpr int kBubbleLauncherSearchBoxIconSize = 20; + +// The size of the image button in the search box. +constexpr int kBubbleLauncherSearchBoxButtonSizeDip = 36; // Color of placeholder text in zero query state. constexpr SkColor kZeroQuerySearchboxColor =
diff --git a/ash/search_box/search_box_view_base.cc b/ash/search_box/search_box_view_base.cc index 451d7dd..45830f0 100644 --- a/ash/search_box/search_box_view_base.cc +++ b/ash/search_box/search_box_view_base.cc
@@ -117,8 +117,8 @@ SetPaintToLayer(); layer()->SetFillsBoundsOpaquely(false); - SetPreferredSize( - gfx::Size(kSearchBoxButtonSizeDip, kSearchBoxButtonSizeDip)); + SetPreferredSize(gfx::Size(kClassicSearchBoxButtonSizeDip, + kClassicSearchBoxButtonSizeDip)); SetImageHorizontalAlignment(ALIGN_CENTER); SetImageVerticalAlignment(ALIGN_MIDDLE);
diff --git a/ash/webui/shimless_rma/resources/onboarding_update_page.html b/ash/webui/shimless_rma/resources/onboarding_update_page.html index f7b66e5..d19a74a 100644 --- a/ash/webui/shimless_rma/resources/onboarding_update_page.html +++ b/ash/webui/shimless_rma/resources/onboarding_update_page.html
@@ -3,6 +3,10 @@ border-color: var(--google-blue-600); } + #restartIcon { + padding-inline-start: 8px; + } + #updateIcon { color: var(--cros-icon-color-secondary); } @@ -31,7 +35,7 @@ on-click="onUpdateButtonClicked_"> [[updateVersionButtonLabel_]] <iron-icon id="restartIcon" icon="shimless-icon:update" - class="small-icon"> + class="small-icon-base"> </iron-icon> </cr-button> </div>
diff --git a/ash/webui/shimless_rma/resources/shimless_rma_shared_css.html b/ash/webui/shimless_rma/resources/shimless_rma_shared_css.html index d439e2c..5273e11 100644 --- a/ash/webui/shimless_rma/resources/shimless_rma_shared_css.html +++ b/ash/webui/shimless_rma/resources/shimless_rma_shared_css.html
@@ -37,6 +37,11 @@ width: 20px; } + .small-icon-base { + height: 20px; + width: 20px; + } + .large-spinner { height: 286px; width: 286px; @@ -152,10 +157,6 @@ border-radius: 15px; } - cr-button .small-icon { - padding-inline-start: 8px; - } - .illustration-wrapper { align-items: center; display: flex;
diff --git a/ash/wm/desks/desk.cc b/ash/wm/desks/desk.cc index d647c5f..3c0e79e 100644 --- a/ash/wm/desks/desk.cc +++ b/ash/wm/desks/desk.cc
@@ -358,6 +358,14 @@ return base::AutoReset<bool>(&should_notify_content_changed_, false); } +bool Desk::ContainsAppWindows() const { + return std::find_if(windows_.begin(), windows_.end(), + [](aura::Window* window) { + return window->GetProperty(aura::client::kAppType) != + static_cast<int>(AppType::NON_APP); + }) != windows_.end(); +} + void Desk::SetName(std::u16string new_name, bool set_by_user) { // Even if the user focuses the DeskNameView for the first time and hits enter // without changing the desk's name (i.e. |new_name| is the same,
diff --git a/ash/wm/desks/desk.h b/ash/wm/desks/desk.h index 6fd4135..77d149a5 100644 --- a/ash/wm/desks/desk.h +++ b/ash/wm/desks/desk.h
@@ -109,6 +109,8 @@ base::AutoReset<bool> GetScopedNotifyContentChangedDisabler(); + bool ContainsAppWindows() const; + // Sets the desk's name to |new_name| and updates the observers. // |set_by_user| should be true if this name was given to the desk by the user // from its mini view in overview mode.
diff --git a/ash/wm/desks/desk_action_context_menu.cc b/ash/wm/desks/desk_action_context_menu.cc index 2e3c983..81fffa45 100644 --- a/ash/wm/desks/desk_action_context_menu.cc +++ b/ash/wm/desks/desk_action_context_menu.cc
@@ -46,6 +46,10 @@ new_combine_desks_target_name)); } +void DeskActionContextMenu::SetCombineDesksMenuItemVisibility(bool visible) { + context_menu_model_.SetVisibleAt(CommandId::kCombineDesks, visible); +} + void DeskActionContextMenu::ExecuteCommand(int command_id, int event_flags) { switch (command_id) { case CommandId::kCombineDesks:
diff --git a/ash/wm/desks/desk_action_context_menu.h b/ash/wm/desks/desk_action_context_menu.h index 5db089b..cd1703b 100644 --- a/ash/wm/desks/desk_action_context_menu.h +++ b/ash/wm/desks/desk_action_context_menu.h
@@ -44,11 +44,17 @@ void UpdateCombineDesksTargetName( const std::u16string& new_combine_desks_target_name); + // Changes the visibility of the combine desks context menu item so that it + // can reflect whether there are windows on the desk. + void SetCombineDesksMenuItemVisibility(bool visible); + // ui::SimpleMenuModel::Delegate: void ExecuteCommand(int command_id, int event_flags) override; void MenuClosed(ui::SimpleMenuModel* menu) override; private: + friend class DesksTestApi; + // views::ContextMenuController: void ShowContextMenuForViewImpl(views::View* source, const gfx::Point& point,
diff --git a/ash/wm/desks/desk_action_view.cc b/ash/wm/desks/desk_action_view.cc index f7fbe17..f67a45f2 100644 --- a/ash/wm/desks/desk_action_view.cc +++ b/ash/wm/desks/desk_action_view.cc
@@ -56,6 +56,10 @@ IDS_ASH_DESKS_COMBINE_DESKS_DESCRIPTION, new_combine_desks_target_name)); } +void DeskActionView::SetCombineDesksButtonVisibility(bool visible) { + combine_desks_button_->SetVisible(visible); +} + BEGIN_METADATA(DeskActionView, views::BoxLayoutView) END_METADATA
diff --git a/ash/wm/desks/desk_action_view.h b/ash/wm/desks/desk_action_view.h index 5522f23..07fad1d 100644 --- a/ash/wm/desks/desk_action_view.h +++ b/ash/wm/desks/desk_action_view.h
@@ -32,6 +32,10 @@ void UpdateCombineDesksTooltip( const std::u16string& new_combine_desks_target_name); + // Changes the visibility of the combine desks button so that it can reflect + // whether there are windows on the desk. + void SetCombineDesksButtonVisibility(bool visible); + private: CloseButton* combine_desks_button_; CloseButton* close_all_button_;
diff --git a/ash/wm/desks/desk_mini_view.cc b/ash/wm/desks/desk_mini_view.cc index d19af3a..4a72e5d3 100644 --- a/ash/wm/desks/desk_mini_view.cc +++ b/ash/wm/desks/desk_mini_view.cc
@@ -52,6 +52,15 @@ return gfx::Rect(origin, screen_rect.size()); } +// Tells whether `desk` contains an app window itself or if the desk is active +// and at least one visible on all desk window exists. +bool ContainsAppWindows(Desk* desk) { + if (desk->ContainsAppWindows()) + return true; + return desk->is_active() && + !DesksController::Get()->visible_on_all_desks_windows().empty(); +} + } // namespace // ----------------------------------------------------------------------------- @@ -159,20 +168,28 @@ } void DeskMiniView::UpdateDeskButtonVisibility() { + auto* controller = DesksController::Get(); + // Don't show desk buttons when hovered while the dragged window is on // the DesksBarView. // For switch access, setting desk buttons to visible allows users to // navigate to it. const bool visible = - DesksController::Get()->CanRemoveDesks() && - !owner_bar_->dragged_item_over_bar() && !owner_bar_->IsDraggingDesk() && + controller->CanRemoveDesks() && !owner_bar_->dragged_item_over_bar() && + !owner_bar_->IsDraggingDesk() && (IsMouseHovered() || force_show_desk_buttons_ || Shell::Get()->accessibility_controller()->IsSwitchAccessRunning()); - if (features::IsDesksCloseAllEnabled()) + if (features::IsDesksCloseAllEnabled()) { + // Only show the combine desks button if there are app windows in the desk, + // or if the desk is active and there are windows that should be visible on + // all desks. + desk_action_view_->SetCombineDesksButtonVisibility( + ContainsAppWindows(desk_)); desk_action_view_->SetVisible(visible && !is_context_menu_open_); - else + } else { close_desk_button_->SetVisible(visible); + } } void DeskMiniView::OnWidgetGestureTap(const gfx::Rect& screen_rect, @@ -236,6 +253,11 @@ // context menu item label for combining desks here to tell the user where the // windows will go. + // Only show the combine desks context menu option if there are app windows in + // the desk, or if the desk is active and there are windows that should be + // visible on all desks. + context_menu_->SetCombineDesksMenuItemVisibility(ContainsAppWindows(desk_)); + // TODO(crbug.com/1308780): Source will need to be different when opening with // long press and possibly keyboard. context_menu_->ShowContextMenuForView(
diff --git a/ash/wm/desks/desks_bar_view.cc b/ash/wm/desks/desks_bar_view.cc index a40d1cc..361e7d036 100644 --- a/ash/wm/desks/desks_bar_view.cc +++ b/ash/wm/desks/desks_bar_view.cc
@@ -211,8 +211,13 @@ const gfx::Size zero_state_new_desk_button_size = zero_state_new_desk_button->GetPreferredSize(); + // The presenter is shutdown early in the overview destruction process to + // prevent calls to the model. Some animations on the desks bar may still + // call this function past shutdown start. In this case we just continue + // as if the saved desks Ui should be hidden. const bool should_show_templates_ui = desks_templates_util::IsSavedDesksEnabled() && + !bar_view_->overview_grid()->overview_session()->is_shutting_down() && DesksTemplatesPresenter::Get()->should_show_templates_ui(); auto* zero_state_desks_templates_button = bar_view_->zero_state_desks_templates_button();
diff --git a/ash/wm/desks/desks_test_api.cc b/ash/wm/desks/desks_test_api.cc index 3916068c..b1a9e65 100644 --- a/ash/wm/desks/desks_test_api.cc +++ b/ash/wm/desks/desks_test_api.cc
@@ -8,6 +8,7 @@ #include "ash/shell.h" #include "ash/system/toast/toast_manager_impl.h" #include "ash/wm/desks/desk.h" +#include "ash/wm/desks/desk_action_context_menu.h" #include "ash/wm/desks/desk_mini_view.h" #include "ash/wm/desks/desks_bar_view.h" #include "ash/wm/desks/desks_restore_util.h" @@ -100,6 +101,11 @@ } // static +const ui::SimpleMenuModel& DesksTestApi::GetContextMenuModelForDesk(int index) { + return GetContextMenuForDesk(index)->context_menu_model_; +} + +// static bool DesksTestApi::HasVerticalDotsButton() { return GetDesksBarView()->vertical_dots_button_; }
diff --git a/ash/wm/desks/desks_test_api.h b/ash/wm/desks/desks_test_api.h index 75eb8ca..1c90b55b 100644 --- a/ash/wm/desks/desks_test_api.h +++ b/ash/wm/desks/desks_test_api.h
@@ -15,6 +15,10 @@ class ScrollView; } // namespace views +namespace ui { +class SimpleMenuModel; +} // namespace ui + namespace ash { class Desk; @@ -41,6 +45,7 @@ GetPersistentDesksBarDeskButtons(); static DeskActionContextMenu* GetContextMenuForDesk(int index); static views::LabelButton* GetCloseAllUndoToastDismissButton(); + static const ui::SimpleMenuModel& GetContextMenuModelForDesk(int index); static bool HasVerticalDotsButton(); static bool DesksControllerHasDesk(Desk* desk); static bool DesksControllerCanUndoDeskRemoval();
diff --git a/ash/wm/desks/desks_unittests.cc b/ash/wm/desks/desks_unittests.cc index 6410f05..afde41a 100644 --- a/ash/wm/desks/desks_unittests.cc +++ b/ash/wm/desks/desks_unittests.cc
@@ -7075,6 +7075,19 @@ /*event_flags=*/0); } + // Opens the context menu for the mini view at `index`. + void OpenContextMenuForMiniView(int index) { + ASSERT_TRUE(Shell::Get()->overview_controller()->InOverviewSession()); + const DeskPreviewView* desk_preview_view = + GetPrimaryRootDesksBarView()->mini_views()[index]->desk_preview(); + const gfx::Point desk_preview_view_center = + desk_preview_view->GetBoundsInScreen().CenterPoint(); + auto* event_generator = GetEventGenerator(); + event_generator->MoveMouseTo(desk_preview_view_center); + event_generator->ClickRightButton(); + ASSERT_TRUE(Shell::Get()->overview_controller()->InOverviewSession()); + } + // DesksTest: void SetUp() override { scoped_feature_list_.InitAndEnableFeature(features::kDesksCloseAll); @@ -7347,6 +7360,51 @@ } } +// Checks that the combine desks button and context menu option are not visible +// when there are no windows on a desk, and that they are visible on desks with +// windows. +TEST_F(DesksCloseAllTest, HideCombineDesksOptionWhenNoWindowsOnDesk) { + // Create a new desk with no windows to have an expanded desks bar view with + // mini views. + NewDesk(); + EnterOverview(); + ASSERT_TRUE(Shell::Get()->overview_controller()->InOverviewSession()); + + // We need to hover over the desk preview to properly check the combine desks + // button's visibility. + DeskMiniView* mini_view = GetPrimaryRootDesksBarView()->mini_views()[0]; + CloseButton* combine_desks_button = + mini_view->desk_action_view()->combine_desks_button(); + gfx::Point desk_preview_view_center = + mini_view->desk_preview()->GetBoundsInScreen().CenterPoint(); + auto* event_generator = GetEventGenerator(); + event_generator->MoveMouseTo(desk_preview_view_center); + EXPECT_FALSE(combine_desks_button->GetVisible()); + + // We need to open the context menu to trigger state change for the combine + // desks option in the context menu. + OpenContextMenuForMiniView(0); + EXPECT_FALSE(DesksTestApi::GetContextMenuModelForDesk(0).IsVisibleAt( + DeskActionContextMenu::CommandId::kCombineDesks)); + event_generator->ClickLeftButton(); + + // Add a window and check to see if that makes the context option visible for + // the desk's action view. + auto window = CreateAppWindow(); + DesksController::Get()->SendToDeskAtIndex(window.get(), 0); + EnterOverview(); + ASSERT_TRUE(Shell::Get()->overview_controller()->InOverviewSession()); + mini_view = GetPrimaryRootDesksBarView()->mini_views()[0]; + combine_desks_button = mini_view->desk_action_view()->combine_desks_button(); + desk_preview_view_center = + mini_view->desk_preview()->GetBoundsInScreen().CenterPoint(); + event_generator->MoveMouseTo(desk_preview_view_center); + EXPECT_TRUE(combine_desks_button->GetVisible()); + OpenContextMenuForMiniView(0); + EXPECT_TRUE(DesksTestApi::GetContextMenuModelForDesk(0).IsVisibleAt( + DeskActionContextMenu::CommandId::kCombineDesks)); +} + // TODO(crbug.com/1308429): Should have tests for opening and closing the // DeskActionContextMenu (which should also add and remove the highlight // overview on the desk preview).
diff --git a/ash/wm/desks/templates/desks_templates_dialog_controller.cc b/ash/wm/desks/templates/desks_templates_dialog_controller.cc index c65e1ed1..fea0428 100644 --- a/ash/wm/desks/templates/desks_templates_dialog_controller.cc +++ b/ash/wm/desks/templates/desks_templates_dialog_controller.cc
@@ -11,8 +11,8 @@ #include "ash/style/ash_color_provider.h" #include "ash/wm/desks/templates/desks_templates_grid_view.h" #include "ash/wm/desks/templates/desks_templates_icon_container.h" -#include "ash/wm/desks/templates/desks_templates_item_view.h" #include "ash/wm/desks/templates/desks_templates_metrics_util.h" +#include "ash/wm/desks/templates/saved_desk_item_view.h" #include "ash/wm/overview/overview_controller.h" #include "ash/wm/overview/overview_grid.h" #include "base/bind.h" @@ -274,7 +274,7 @@ if (templates_grid_widget) { auto* templates_grid_view = static_cast<DesksTemplatesGridView*>( templates_grid_widget->GetContentsView()); - for (DesksTemplatesItemView* template_item : + for (SavedDeskItemView* template_item : templates_grid_view->grid_items()) { // Update the button visibility when a dialog is closed. template_item->UpdateHoverButtonsVisibility(
diff --git a/ash/wm/desks/templates/desks_templates_grid_view.cc b/ash/wm/desks/templates/desks_templates_grid_view.cc index 08a8dabc..2f44840 100644 --- a/ash/wm/desks/templates/desks_templates_grid_view.cc +++ b/ash/wm/desks/templates/desks_templates_grid_view.cc
@@ -16,8 +16,8 @@ #include "ash/style/ash_color_provider.h" #include "ash/style/pill_button.h" #include "ash/wm/desks/templates/desks_templates_animations.h" -#include "ash/wm/desks/templates/desks_templates_item_view.h" #include "ash/wm/desks/templates/desks_templates_presenter.h" +#include "ash/wm/desks/templates/saved_desk_item_view.h" #include "ash/wm/desks/templates/saved_desk_name_view.h" #include "ash/wm/overview/overview_controller.h" #include "ash/wm/overview/overview_highlight_controller.h" @@ -246,8 +246,8 @@ // grid, and sort the rest of the templates after it. std::sort( grid_items_.begin(), grid_items_.end(), - [&collator, last_saved_template_uuid](const DesksTemplatesItemView* a, - const DesksTemplatesItemView* b) { + [&collator, last_saved_template_uuid](const SavedDeskItemView* a, + const SavedDeskItemView* b) { if (last_saved_template_uuid.is_valid() && a->uuid() == last_saved_template_uuid) { return true; @@ -279,19 +279,19 @@ const std::vector<const DeskTemplate*>& entries, bool initializing_grid_view, const base::GUID& last_saved_template_uuid) { - std::vector<DesksTemplatesItemView*> new_grid_items; + std::vector<SavedDeskItemView*> new_grid_items; for (const DeskTemplate* entry : entries) { auto iter = std::find_if(grid_items_.begin(), grid_items_.end(), - [entry](DesksTemplatesItemView* grid_item) { + [entry](SavedDeskItemView* grid_item) { return entry->uuid() == grid_item->uuid(); }); if (iter != grid_items_.end()) { (*iter)->UpdateTemplate(*entry); } else if (grid_items_.size() < kMaxTemplateCount) { - DesksTemplatesItemView* grid_item = - AddChildView(std::make_unique<DesksTemplatesItemView>(entry)); + SavedDeskItemView* grid_item = + AddChildView(std::make_unique<SavedDeskItemView>(entry)); grid_items_.push_back(grid_item); if (!initializing_grid_view) new_grid_items.push_back(grid_item); @@ -319,14 +319,14 @@ for (const std::string& uuid : uuids) { auto iter = std::find_if(grid_items_.begin(), grid_items_.end(), - [uuid](DesksTemplatesItemView* grid_item) { + [uuid](SavedDeskItemView* grid_item) { return uuid == grid_item->uuid().AsLowercaseString(); }); if (iter == grid_items_.end()) continue; - DesksTemplatesItemView* grid_item = *iter; + SavedDeskItemView* grid_item = *iter; highlight_controller->OnViewDestroyingOrDisabling(grid_item); highlight_controller->OnViewDestroyingOrDisabling(grid_item->name_view()); @@ -360,7 +360,7 @@ return false; for (auto* grid_item : grid_items_) { - if (grid_item->IsTemplateNameBeingModified()) + if (grid_item->IsNameBeingModified()) return true; } return false; @@ -422,13 +422,13 @@ widget_window_ = nullptr; } -DesksTemplatesItemView* DesksTemplatesGridView::GetItemForUUID( +SavedDeskItemView* DesksTemplatesGridView::GetItemForUUID( const base::GUID& uuid) { if (!uuid.is_valid()) return nullptr; auto it = std::find_if(grid_items_.begin(), grid_items_.end(), - [&uuid](DesksTemplatesItemView* item_view) { + [&uuid](SavedDeskItemView* item_view) { return uuid == item_view->desk_template()->uuid(); }); return it == grid_items_.end() ? nullptr : *it; @@ -461,7 +461,7 @@ const gfx::Point screen_location = event->target() ? event->target()->GetScreenLocation(*event) : event->root_location(); - for (DesksTemplatesItemView* grid_item : grid_items_) + for (SavedDeskItemView* grid_item : grid_items_) grid_item->UpdateHoverButtonsVisibility(screen_location, is_touch); break; } @@ -530,10 +530,10 @@ } void DesksTemplatesGridView::AnimateGridItems( - const std::vector<DesksTemplatesItemView*>& new_grid_items) { + const std::vector<SavedDeskItemView*>& new_grid_items) { const std::vector<gfx::Rect> positions = CalculateGridItemPositions(); for (size_t i = 0; i < grid_items_.size(); i++) { - DesksTemplatesItemView* grid_item = grid_items_[i]; + SavedDeskItemView* grid_item = grid_items_[i]; const gfx::Rect target_bounds = positions[i]; if (bounds_animator_.GetTargetBounds(grid_item) == target_bounds) continue; @@ -572,7 +572,7 @@ void DesksTemplatesGridView::OnFeedbackButtonPressed() { std::string extra_diagnostics; - for (DesksTemplatesItemView* grid_item : grid_items_) + for (SavedDeskItemView* grid_item : grid_items_) extra_diagnostics += (grid_item->desk_template()->ToString() + "\n"); // Note that this will activate the dialog which will exit overview and delete
diff --git a/ash/wm/desks/templates/desks_templates_grid_view.h b/ash/wm/desks/templates/desks_templates_grid_view.h index 946fa372..10b29916 100644 --- a/ash/wm/desks/templates/desks_templates_grid_view.h +++ b/ash/wm/desks/templates/desks_templates_grid_view.h
@@ -16,12 +16,12 @@ namespace ash { class DesksTemplatesEventHandler; -class DesksTemplatesItemView; class DeskTemplate; class PillButton; +class SavedDeskItemView; // A view that acts as the content view of the desks templates widget. Displays -// each desk template as a DesksTemplatesItemView. +// each saved desk as a SavedDeskItemView. class DesksTemplatesGridView : public views::View, public aura::WindowObserver { public: METADATA_HEADER(DesksTemplatesGridView); @@ -36,7 +36,7 @@ static std::unique_ptr<views::Widget> CreateDesksTemplatesGridWidget( aura::Window* root); - const std::vector<DesksTemplatesItemView*>& grid_items() const { + const std::vector<SavedDeskItemView*>& grid_items() const { return grid_items_; } @@ -66,7 +66,7 @@ bool IsTemplateNameBeingModified() const; // Returns the item view associated with `uuid`. - DesksTemplatesItemView* GetItemForUUID(const base::GUID& uuid); + SavedDeskItemView* GetItemForUUID(const base::GUID& uuid); // views::View: void Layout() override; @@ -88,7 +88,7 @@ // Calculates the bounds for each grid item within the templates grid. The // indices of the returned vector directly correlate to those of `grid_items_` // (i.e. the Rect at index 1 of the returned vector should be applied to the - // `DesksTemplatesItemView` found at index 1 of `grid_items_`). + // `SavedDeskItemView` found at index 1 of `grid_items_`). std::vector<gfx::Rect> CalculateGridItemPositions() const; // Calculates the bounds to be applied to the feedback button based off of the @@ -99,15 +99,14 @@ // their calculated position. `new_grid_items` contains a list of the // newly-created desk template items and will be animated differently than // the existing views that are being shifted around. - void AnimateGridItems( - const std::vector<DesksTemplatesItemView*>& new_grid_items); + void AnimateGridItems(const std::vector<SavedDeskItemView*>& new_grid_items); // Called when the feedback button is pressed. Shows the feedback dialog with // desks templates information. void OnFeedbackButtonPressed(); // The views representing templates. They're owned by views hierarchy. - std::vector<DesksTemplatesItemView*> grid_items_; + std::vector<SavedDeskItemView*> grid_items_; // Owned by views hierarchy. Temporary button to help users give feedback. // TODO(crbug.com/1289880): Remove this button when it is no longer needed.
diff --git a/ash/wm/desks/templates/desks_templates_icon_container.h b/ash/wm/desks/templates/desks_templates_icon_container.h index fa792fa..cc7c736 100644 --- a/ash/wm/desks/templates/desks_templates_icon_container.h +++ b/ash/wm/desks/templates/desks_templates_icon_container.h
@@ -77,8 +77,6 @@ void Layout() override; private: - friend class DesksTemplatesItemViewTestApi; - // Given a sorted vector of pairs of icon identifier and icon info, create // views for them. void CreateIconViewsFromIconIdentifiers(
diff --git a/ash/wm/desks/templates/desks_templates_icon_view.h b/ash/wm/desks/templates/desks_templates_icon_view.h index d6c6daa9..0318c49 100644 --- a/ash/wm/desks/templates/desks_templates_icon_view.h +++ b/ash/wm/desks/templates/desks_templates_icon_view.h
@@ -25,7 +25,7 @@ class RoundedImageView; // A class for loading and displaying the icon of apps/urls used in a -// DesksTemplatesItemView. Depending on the `count_` and `icon_identifier_`, +// SavedDeskItemView. Depending on the `count_` and `icon_identifier_`, // this View may have only an icon, only a count label, or both. class DesksTemplatesIconView : public views::View { public:
diff --git a/ash/wm/desks/templates/desks_templates_presenter.cc b/ash/wm/desks/templates/desks_templates_presenter.cc index 8eabd3e..490635d1 100644 --- a/ash/wm/desks/templates/desks_templates_presenter.cc +++ b/ash/wm/desks/templates/desks_templates_presenter.cc
@@ -17,8 +17,8 @@ #include "ash/wm/desks/desks_util.h" #include "ash/wm/desks/expanded_desks_bar_button.h" #include "ash/wm/desks/templates/desks_templates_grid_view.h" -#include "ash/wm/desks/templates/desks_templates_item_view.h" #include "ash/wm/desks/templates/desks_templates_metrics_util.h" +#include "ash/wm/desks/templates/saved_desk_item_view.h" #include "ash/wm/desks/templates/saved_desk_name_view.h" #include "ash/wm/desks/zero_state_button.h" #include "ash/wm/overview/overview_controller.h" @@ -222,8 +222,7 @@ grid_view->PopulateGridUI(entries, overview_grid->GetGridEffectiveBounds(), /*last_saved_template_uuid=*/item_to_focus); - DesksTemplatesItemView* item_view = - grid_view->GetItemForUUID(item_to_focus); + SavedDeskItemView* item_view = grid_view->GetItemForUUID(item_to_focus); if (!item_view) continue; @@ -346,7 +345,7 @@ root_window); auto* grid_view = static_cast<DesksTemplatesGridView*>(grid_widget->GetContentsView()); - DesksTemplatesItemView* item_view = + SavedDeskItemView* item_view = grid_view->GetItemForUUID(desk_template->uuid()); if (item_view) { item_view->MaybeRemoveNameNumber();
diff --git a/ash/wm/desks/templates/desks_templates_presenter.h b/ash/wm/desks/templates/desks_templates_presenter.h index 057b5b9..cfab8c1 100644 --- a/ash/wm/desks/templates/desks_templates_presenter.h +++ b/ash/wm/desks/templates/desks_templates_presenter.h
@@ -36,6 +36,9 @@ // Convenience function to get the presenter instance, which is created and // owned by `OverviewSession`. + // TODO(crbug.com/1322553): Remove this function as `Get()` is normally used + // for singletons, or for objects whose lifetimes are deterministic and live + // as long as ash lives. static DesksTemplatesPresenter* Get(); bool should_show_templates_ui() { return should_show_templates_ui_; }
diff --git a/ash/wm/desks/templates/desks_templates_test_util.cc b/ash/wm/desks/templates/desks_templates_test_util.cc index 1b18f988..8051612 100644 --- a/ash/wm/desks/templates/desks_templates_test_util.cc +++ b/ash/wm/desks/templates/desks_templates_test_util.cc
@@ -9,8 +9,8 @@ #include "ash/wm/desks/desks_bar_view.h" #include "ash/wm/desks/expanded_desks_bar_button.h" #include "ash/wm/desks/templates/desks_templates_dialog_controller.h" -#include "ash/wm/desks/templates/desks_templates_item_view.h" #include "ash/wm/desks/templates/desks_templates_presenter.h" +#include "ash/wm/desks/templates/saved_desk_item_view.h" #include "ash/wm/desks/zero_state_button.h" #include "ash/wm/overview/overview_grid.h" #include "ash/wm/overview/overview_test_util.h" @@ -94,16 +94,16 @@ BoundsAnimatorWaiter(grid_view_->bounds_animator_).Wait(); } -DesksTemplatesItemViewTestApi::DesksTemplatesItemViewTestApi( - const DesksTemplatesItemView* item_view) +SavedDeskItemViewTestApi::SavedDeskItemViewTestApi( + const SavedDeskItemView* item_view) : item_view_(item_view) { DCHECK(item_view_); } -DesksTemplatesItemViewTestApi::~DesksTemplatesItemViewTestApi() = default; +SavedDeskItemViewTestApi::~SavedDeskItemViewTestApi() = default; -std::vector<DesksTemplatesIconView*> -DesksTemplatesItemViewTestApi::GetIconViews() const { +std::vector<DesksTemplatesIconView*> SavedDeskItemViewTestApi::GetIconViews() + const { std::vector<DesksTemplatesIconView*> casted_icon_views; for (auto* icon_view : item_view_->icon_container_view_->children()) { casted_icon_views.push_back( @@ -120,7 +120,7 @@ DesksTemplatesIconViewTestApi::~DesksTemplatesIconViewTestApi() = default; -DesksTemplatesItemView* GetItemViewFromTemplatesGrid(int grid_item_index) { +SavedDeskItemView* GetItemViewFromTemplatesGrid(int grid_item_index) { const auto* overview_grid = GetPrimaryOverviewGrid(); if (!overview_grid) return nullptr; @@ -132,9 +132,9 @@ static_cast<DesksTemplatesGridView*>(grid_widget->GetContentsView()); DCHECK(templates_grid_view); - std::vector<DesksTemplatesItemView*> grid_items = + std::vector<SavedDeskItemView*> grid_items = templates_grid_view->grid_items(); - DesksTemplatesItemView* item_view = grid_items.at(grid_item_index); + SavedDeskItemView* item_view = grid_items.at(grid_item_index); DCHECK(item_view); return item_view; } @@ -178,7 +178,7 @@ views::Button* GetTemplateItemDeleteButton(int index) { auto* item = GetItemViewFromTemplatesGrid(index); return item ? static_cast<views::Button*>(const_cast<CloseButton*>( - DesksTemplatesItemViewTestApi(item).delete_button())) + SavedDeskItemViewTestApi(item).delete_button())) : nullptr; }
diff --git a/ash/wm/desks/templates/desks_templates_test_util.h b/ash/wm/desks/templates/desks_templates_test_util.h index 4084767..4c7bf3f 100644 --- a/ash/wm/desks/templates/desks_templates_test_util.h +++ b/ash/wm/desks/templates/desks_templates_test_util.h
@@ -11,7 +11,7 @@ #include "ash/wm/desks/templates/desks_templates_grid_view.h" #include "ash/wm/desks/templates/desks_templates_icon_container.h" #include "ash/wm/desks/templates/desks_templates_icon_view.h" -#include "ash/wm/desks/templates/desks_templates_item_view.h" +#include "ash/wm/desks/templates/saved_desk_item_view.h" #include "ash/wm/desks/templates/saved_desk_name_view.h" #include "base/callback_helpers.h" #include "base/guid.h" @@ -61,16 +61,14 @@ DesksTemplatesGridView* grid_view_; }; -// Wrapper for `DesksTemplatesItemView` that exposes internal state to test +// Wrapper for `SavedDeskItemView` that exposes internal state to test // functions. -class DesksTemplatesItemViewTestApi { +class SavedDeskItemViewTestApi { public: - explicit DesksTemplatesItemViewTestApi( - const DesksTemplatesItemView* item_view); - DesksTemplatesItemViewTestApi(const DesksTemplatesItemViewTestApi&) = delete; - DesksTemplatesItemViewTestApi& operator=( - const DesksTemplatesItemViewTestApi&) = delete; - ~DesksTemplatesItemViewTestApi(); + explicit SavedDeskItemViewTestApi(const SavedDeskItemView* item_view); + SavedDeskItemViewTestApi(const SavedDeskItemViewTestApi&) = delete; + SavedDeskItemViewTestApi& operator=(const SavedDeskItemViewTestApi&) = delete; + ~SavedDeskItemViewTestApi(); const views::Label* time_view() const { return item_view_->time_view_; } @@ -91,7 +89,7 @@ std::vector<DesksTemplatesIconView*> GetIconViews() const; private: - const DesksTemplatesItemView* item_view_; + const SavedDeskItemView* item_view_; }; // Wrapper for `DesksTemplatesIconView` that exposes internal state to test @@ -121,9 +119,9 @@ const DesksTemplatesIconView* desks_templates_icon_view_; }; -// Return the `grid_item_index`th `DesksTemplatesItemView` from the first +// Return the `grid_item_index`th `SavedDeskItemView` from the first // `OverviewGrid`'s `DesksTemplatesGridView` in `GetOverviewGridList()`. -DesksTemplatesItemView* GetItemViewFromTemplatesGrid(int grid_item_index); +SavedDeskItemView* GetItemViewFromTemplatesGrid(int grid_item_index); // These buttons are the ones on the primary root window. views::Button* GetZeroStateDesksTemplatesButton();
diff --git a/ash/wm/desks/templates/desks_templates_unittest.cc b/ash/wm/desks/templates/desks_templates_unittest.cc index 54d0cc1..80074621 100644 --- a/ash/wm/desks/templates/desks_templates_unittest.cc +++ b/ash/wm/desks/templates/desks_templates_unittest.cc
@@ -28,12 +28,12 @@ #include "ash/wm/desks/templates/desks_templates_grid_view.h" #include "ash/wm/desks/templates/desks_templates_icon_container.h" #include "ash/wm/desks/templates/desks_templates_icon_view.h" -#include "ash/wm/desks/templates/desks_templates_item_view.h" #include "ash/wm/desks/templates/desks_templates_metrics_util.h" #include "ash/wm/desks/templates/desks_templates_presenter.h" #include "ash/wm/desks/templates/desks_templates_test_util.h" #include "ash/wm/desks/templates/save_desk_template_button.h" #include "ash/wm/desks/templates/save_desk_template_button_container.h" +#include "ash/wm/desks/templates/saved_desk_item_view.h" #include "ash/wm/desks/templates/saved_desk_name_view.h" #include "ash/wm/desks/zero_state_button.h" #include "ash/wm/mru_window_tracker.h" @@ -258,7 +258,7 @@ static_cast<DesksTemplatesGridView*>(grid_widget->GetContentsView()); ASSERT_TRUE(templates_grid_view); - std::vector<DesksTemplatesItemView*> grid_items = + std::vector<SavedDeskItemView*> grid_items = templates_grid_view->grid_items(); // Check the current grid item count. @@ -266,8 +266,8 @@ auto iter = std::find_if(grid_items.cbegin(), grid_items.cend(), - [&](const DesksTemplatesItemView* v) { - return DesksTemplatesItemViewTestApi(v).uuid() == uuid; + [&](const SavedDeskItemView* v) { + return SavedDeskItemViewTestApi(v).uuid() == uuid; }); if (!expect_template_exists) { @@ -277,7 +277,7 @@ ASSERT_NE(grid_items.end(), iter); - ClickOnView(DesksTemplatesItemViewTestApi(*iter).delete_button()); + ClickOnView(SavedDeskItemViewTestApi(*iter).delete_button()); // Clicking on the delete button should bring up the delete dialog. ASSERT_TRUE(Shell::IsSystemModalWindowOpen()); @@ -772,7 +772,7 @@ const DesksTemplatesGridView* templates_grid_view = static_cast<DesksTemplatesGridView*>(grid_widget->GetContentsView()); ASSERT_TRUE(templates_grid_view); - std::vector<DesksTemplatesItemView*> grid_items = + std::vector<SavedDeskItemView*> grid_items = templates_grid_view->grid_items(); ASSERT_EQ(2ul, grid_items.size()); @@ -784,17 +784,15 @@ const std::string& name) { auto iter = std::find_if(grid_items.cbegin(), grid_items.cend(), - [uuid](const DesksTemplatesItemView* v) { - return DesksTemplatesItemViewTestApi(v).uuid() == uuid; + [uuid](const SavedDeskItemView* v) { + return SavedDeskItemViewTestApi(v).uuid() == uuid; }); ASSERT_NE(grid_items.end(), iter); - DesksTemplatesItemView* item_view = *iter; + SavedDeskItemView* item_view = *iter; EXPECT_EQ(base::UTF8ToUTF16(name), item_view->name_view()->GetText()); - EXPECT_FALSE(DesksTemplatesItemViewTestApi(item_view) - .time_view() - ->GetText() - .empty()); + EXPECT_FALSE( + SavedDeskItemViewTestApi(item_view).time_view()->GetText().empty()); }; verify_template_grid_item(uuid_1, name_1); @@ -1042,9 +1040,9 @@ // template. ToggleOverview(); OpenOverviewAndShowTemplatesGrid(); - DesksTemplatesItemView* item_view = GetItemViewFromTemplatesGrid( + SavedDeskItemView* item_view = GetItemViewFromTemplatesGrid( /*grid_item_index=*/0); - ClickOnView(DesksTemplatesItemViewTestApi(item_view).launch_button()); + ClickOnView(SavedDeskItemViewTestApi(item_view).launch_button()); WaitForDesksTemplatesUI(); EXPECT_EQ(3ul, desks_controller->desks().size()); @@ -1064,9 +1062,9 @@ // Click on the "Use template" button to launch the template. OpenOverviewAndShowTemplatesGrid(); - DesksTemplatesItemView* item_view = GetItemViewFromTemplatesGrid( + SavedDeskItemView* item_view = GetItemViewFromTemplatesGrid( /*grid_item_index=*/0); - ClickOnView(DesksTemplatesItemViewTestApi(item_view).launch_button()); + ClickOnView(SavedDeskItemViewTestApi(item_view).launch_button()); WaitForDesksTemplatesUI(); // Verify that we have created and activated a new desk. @@ -1088,7 +1086,7 @@ EXPECT_EQ(u"template", desk_name_view->GetText()); } -// Tests that the order of DesksTemplatesItemView is in order. +// Tests that the order of SavedDeskItemView is in order. TEST_F(DesksTemplatesTest, IconsOrder) { // Create a `DeskTemplate` using which has 5 apps and each app has 1 window. AddEntry(base::GUID::GenerateRandomV4(), "template_1", base::Time::Now(), @@ -1098,10 +1096,10 @@ OpenOverviewAndShowTemplatesGrid(); // Get the icon views. - DesksTemplatesItemView* item_view = GetItemViewFromTemplatesGrid( + SavedDeskItemView* item_view = GetItemViewFromTemplatesGrid( /*grid_item_index=*/0); const std::vector<DesksTemplatesIconView*>& icon_views = - DesksTemplatesItemViewTestApi(item_view).GetIconViews(); + SavedDeskItemViewTestApi(item_view).GetIconViews(); // The items previews should be ordered by activation index. Exclude the // final DesksTemplatesIconView since it will be the overflow counter. @@ -1161,10 +1159,10 @@ // Test that there is a total of 4 icons, one for each tab on each browser. // There is also the overflow icon, which is created but hidden. - DesksTemplatesItemView* item_view = GetItemViewFromTemplatesGrid( + SavedDeskItemView* item_view = GetItemViewFromTemplatesGrid( /*grid_item_index=*/0); const std::vector<DesksTemplatesIconView*>& icon_views = - DesksTemplatesItemViewTestApi(item_view).GetIconViews(); + SavedDeskItemViewTestApi(item_view).GetIconViews(); EXPECT_EQ(5u, icon_views.size()); } @@ -1213,10 +1211,10 @@ OpenOverviewAndShowTemplatesGrid(); // Get the icon views. - DesksTemplatesItemView* item_view = GetItemViewFromTemplatesGrid( + SavedDeskItemView* item_view = GetItemViewFromTemplatesGrid( /*grid_item_index=*/0); const std::vector<DesksTemplatesIconView*>& icon_views = - DesksTemplatesItemViewTestApi(item_view).GetIconViews(); + SavedDeskItemViewTestApi(item_view).GetIconViews(); // Check the icon views. The first two items should be the active tabs, // ordered by activation index. The next two items should be the inactive tabs @@ -1259,10 +1257,10 @@ OpenOverviewAndShowTemplatesGrid(); // Get the icon views. - DesksTemplatesItemView* item_view = GetItemViewFromTemplatesGrid( + SavedDeskItemView* item_view = GetItemViewFromTemplatesGrid( /*grid_item_index=*/0); const std::vector<DesksTemplatesIconView*>& icon_views = - DesksTemplatesItemViewTestApi(item_view).GetIconViews(); + SavedDeskItemViewTestApi(item_view).GetIconViews(); // There should be one icon view for both the urls, and another icon view for // the overflow icon. @@ -1292,10 +1290,10 @@ OpenOverviewAndShowTemplatesGrid(); // Get the icon views. - DesksTemplatesItemView* item_view = GetItemViewFromTemplatesGrid( + SavedDeskItemView* item_view = GetItemViewFromTemplatesGrid( /*grid_item_index=*/0); const std::vector<DesksTemplatesIconView*>& icon_views = - DesksTemplatesItemViewTestApi(item_view).GetIconViews(); + SavedDeskItemViewTestApi(item_view).GetIconViews(); // There should only be the max number of icons plus the overflow icon. EXPECT_EQ(DesksTemplatesIconContainer::kMaxIcons + 1, @@ -1303,7 +1301,7 @@ // The overflow counter should have no identifier and its count should be // non-zero. It should also be visible and within the bounds of the host - // DesksTemplatesItemView. + // SavedDeskItemView. DesksTemplatesIconViewTestApi overflow_icon_view{icon_views.back()}; EXPECT_FALSE(overflow_icon_view.icon_view()); EXPECT_TRUE(overflow_icon_view.count_label()); @@ -1332,10 +1330,10 @@ OpenOverviewAndShowTemplatesGrid(); // Get the icon views. - DesksTemplatesItemView* item_view = GetItemViewFromTemplatesGrid( + SavedDeskItemView* item_view = GetItemViewFromTemplatesGrid( /*grid_item_index=*/0); const std::vector<DesksTemplatesIconView*>& icon_views = - DesksTemplatesItemViewTestApi(item_view).GetIconViews(); + SavedDeskItemViewTestApi(item_view).GetIconViews(); // Even though there are more than `DesksTemplatesIconContainer::kMaxIcons`, // there should still be `DesksTemplatesIconContainer::kMaxIcons`+ 1 @@ -1366,7 +1364,7 @@ // The overflow counter should have no identifier and its count should be // non-zero, accounting for the number of windows that are not represented by // app icons. It should also be visible and within the bounds of the host - // DesksTemplatesItemView. + // SavedDeskItemView. DesksTemplatesIconViewTestApi overflow_icon_view{icon_views.back()}; EXPECT_FALSE(overflow_icon_view.icon_view()); EXPECT_TRUE(overflow_icon_view.count_label()); @@ -1401,10 +1399,10 @@ OpenOverviewAndShowTemplatesGrid(); // Get the icon views. - DesksTemplatesItemView* item_view = GetItemViewFromTemplatesGrid( + SavedDeskItemView* item_view = GetItemViewFromTemplatesGrid( /*grid_item_index=*/0); const std::vector<DesksTemplatesIconView*>& icon_views = - DesksTemplatesItemViewTestApi(item_view).GetIconViews(); + SavedDeskItemViewTestApi(item_view).GetIconViews(); // There should be 1 * 2 icon views for the 2 apps with 1 window, 2 * 2 icon // views for the 2 apps with multiple windows, and 1 overflow icon view. @@ -1448,10 +1446,10 @@ OpenOverviewAndShowTemplatesGrid(); // Get the icon views. - DesksTemplatesItemView* item_view = GetItemViewFromTemplatesGrid( + SavedDeskItemView* item_view = GetItemViewFromTemplatesGrid( /*grid_item_index=*/0); const std::vector<DesksTemplatesIconView*>& icon_views = - DesksTemplatesItemViewTestApi(item_view).GetIconViews(); + SavedDeskItemViewTestApi(item_view).GetIconViews(); // There should only be 1 icon view for the app and 1 icon view for the // overflow. @@ -1480,10 +1478,10 @@ OpenOverviewAndShowTemplatesGrid(); // Get the icon views. - DesksTemplatesItemView* item_view = GetItemViewFromTemplatesGrid( + SavedDeskItemView* item_view = GetItemViewFromTemplatesGrid( /*grid_item_index=*/0); const std::vector<DesksTemplatesIconView*>& icon_views = - DesksTemplatesItemViewTestApi(item_view).GetIconViews(); + SavedDeskItemViewTestApi(item_view).GetIconViews(); // All the icon views should be visible and the overflow icon view should be // invisible. @@ -1511,10 +1509,10 @@ OpenOverviewAndShowTemplatesGrid(); // Get the icon views. - DesksTemplatesItemView* item_view = GetItemViewFromTemplatesGrid( + SavedDeskItemView* item_view = GetItemViewFromTemplatesGrid( /*grid_item_index=*/0); const std::vector<DesksTemplatesIconView*>& icon_views = - DesksTemplatesItemViewTestApi(item_view).GetIconViews(); + SavedDeskItemViewTestApi(item_view).GetIconViews(); // The 2 available app icons should be visible, and the overflow icon should // contain the hidden (0) + unavailable (2) app counts. @@ -1545,10 +1543,10 @@ OpenOverviewAndShowTemplatesGrid(); // Get the icon views. - DesksTemplatesItemView* item_view = GetItemViewFromTemplatesGrid( + SavedDeskItemView* item_view = GetItemViewFromTemplatesGrid( /*grid_item_index=*/0); const std::vector<DesksTemplatesIconView*>& icon_views = - DesksTemplatesItemViewTestApi(item_view).GetIconViews(); + SavedDeskItemViewTestApi(item_view).GetIconViews(); // The 4 available app icons should be visible, and the overflow icon should // contain the hidden (2) + unavailable (2) app counts. @@ -1578,10 +1576,10 @@ OpenOverviewAndShowTemplatesGrid(); // Get the icon views. - DesksTemplatesItemView* item_view = GetItemViewFromTemplatesGrid( + SavedDeskItemView* item_view = GetItemViewFromTemplatesGrid( /*grid_item_index=*/0); const std::vector<DesksTemplatesIconView*>& icon_views = - DesksTemplatesItemViewTestApi(item_view).GetIconViews(); + SavedDeskItemViewTestApi(item_view).GetIconViews(); // The only added icon view is the overflow icon, and it should have a "10" // label without the plus sign. @@ -1723,8 +1721,8 @@ DeskTemplateType::kTemplate); OpenOverviewAndShowTemplatesGrid(); - DesksTemplatesItemView* first_item = GetItemViewFromTemplatesGrid(0); - DesksTemplatesItemView* second_item = GetItemViewFromTemplatesGrid(1); + SavedDeskItemView* first_item = GetItemViewFromTemplatesGrid(0); + SavedDeskItemView* second_item = GetItemViewFromTemplatesGrid(1); // Testing that we first traverse the views of the first item. SendKey(ui::VKEY_TAB); @@ -1945,12 +1943,12 @@ DeskTemplateType::kTemplate); OpenOverviewAndShowTemplatesGrid(); - DesksTemplatesItemView* first_item = GetItemViewFromTemplatesGrid(0); - DesksTemplatesItemView* second_item = GetItemViewFromTemplatesGrid(1); + SavedDeskItemView* first_item = GetItemViewFromTemplatesGrid(0); + SavedDeskItemView* second_item = GetItemViewFromTemplatesGrid(1); auto* hover_container_view1 = - DesksTemplatesItemViewTestApi(first_item).hover_container(); + SavedDeskItemViewTestApi(first_item).hover_container(); auto* hover_container_view2 = - DesksTemplatesItemViewTestApi(second_item).hover_container(); + SavedDeskItemViewTestApi(second_item).hover_container(); EXPECT_FALSE(hover_container_view1->GetVisible()); EXPECT_FALSE(hover_container_view2->GetVisible()); @@ -2121,7 +2119,7 @@ static_cast<DesksTemplatesGridView*>(grid_widget->GetContentsView()); ASSERT_TRUE(templates_grid_view); - std::vector<DesksTemplatesItemView*> grid_items = + std::vector<SavedDeskItemView*> grid_items = templates_grid_view->grid_items(); ASSERT_EQ(1ul, grid_items.size()); @@ -2154,7 +2152,7 @@ static_cast<DesksTemplatesGridView*>(grid_widget->GetContentsView()); ASSERT_TRUE(templates_grid_view); - const std::vector<DesksTemplatesItemView*> grid_items = + const std::vector<SavedDeskItemView*> grid_items = templates_grid_view->grid_items(); ASSERT_EQ(5ul, grid_items.size()); @@ -2248,10 +2246,10 @@ DeskTemplateType::kTemplate); OpenOverviewAndShowTemplatesGrid(); - DesksTemplatesItemView* item_view = GetItemViewFromTemplatesGrid(0); + SavedDeskItemView* item_view = GetItemViewFromTemplatesGrid(0); SavedDeskNameView* name_view = item_view->name_view(); const views::Label* time_view = - DesksTemplatesItemViewTestApi(item_view).time_view(); + SavedDeskItemViewTestApi(item_view).time_view(); // Tests that the contents of the two views are the aligned. We use contents // bounds here since the name view has a background which is larger than the @@ -2613,7 +2611,7 @@ static_cast<DesksTemplatesGridView*>(grid_widget->GetContentsView()); // The grid items are sorted and displayed alphabetically. - std::vector<DesksTemplatesItemView*> grid_items = + std::vector<SavedDeskItemView*> grid_items = templates_grid_view->grid_items(); views::View::Views grid_child_views = templates_grid_view->children(); @@ -2643,7 +2641,7 @@ const auto* templates_grid_view = static_cast<DesksTemplatesGridView*>(grid_widget->GetContentsView()); - const std::vector<DesksTemplatesItemView*> grid_items = + const std::vector<SavedDeskItemView*> grid_items = templates_grid_view->grid_items(); ASSERT_EQ(4ul, grid_items.size()); @@ -2675,7 +2673,7 @@ const auto* templates_grid_view = static_cast<DesksTemplatesGridView*>(grid_widget->GetContentsView()); - const std::vector<DesksTemplatesItemView*> grid_items = + const std::vector<SavedDeskItemView*> grid_items = templates_grid_view->grid_items(); ASSERT_EQ(4ul, grid_items.size()); @@ -2991,7 +2989,7 @@ OpenOverviewAndShowTemplatesGrid(); - DesksTemplatesItemView* item_view = GetItemViewFromTemplatesGrid( + SavedDeskItemView* item_view = GetItemViewFromTemplatesGrid( /*grid_item_index=*/1); // Show replace dialogs. auto* dialog_controller = DesksTemplatesDialogController::Get(); @@ -3226,23 +3224,23 @@ OpenOverviewAndShowTemplatesGrid(); // Tests that each template comes with an expected time string format. - std::vector<DesksTemplatesItemView*> grid_items = + std::vector<SavedDeskItemView*> grid_items = static_cast<DesksTemplatesGridView*>(GetOverviewGridList() .front() ->desks_templates_grid_widget() ->GetContentsView()) ->grid_items(); for (size_t i = 0; i < 3; i++) { - auto iter = std::find_if(grid_items.cbegin(), grid_items.cend(), - [uuid, i](const DesksTemplatesItemView* v) { - return DesksTemplatesItemViewTestApi(v).uuid() == - uuid[i]; - }); + auto iter = + std::find_if(grid_items.cbegin(), grid_items.cend(), + [uuid, i](const SavedDeskItemView* v) { + return SavedDeskItemViewTestApi(v).uuid() == uuid[i]; + }); ASSERT_NE(grid_items.end(), iter); - DesksTemplatesItemView* item_view = *iter; + SavedDeskItemView* item_view = *iter; EXPECT_EQ(expected_timestr[i], - DesksTemplatesItemViewTestApi(item_view).time_view()->GetText()); + SavedDeskItemViewTestApi(item_view).time_view()->GetText()); } } @@ -3291,7 +3289,7 @@ static_cast<DesksTemplatesGridView*>(grid_widget->GetContentsView()); ASSERT_TRUE(templates_grid_view); - const std::vector<DesksTemplatesItemView*> grid_items = + const std::vector<SavedDeskItemView*> grid_items = templates_grid_view->grid_items(); EXPECT_EQ(kMaxTemplateCount, grid_items.size()); } @@ -3319,7 +3317,7 @@ // The name view should release focus after getting a mouse click outside // the grid item. - std::vector<DesksTemplatesItemView*> grid_items = + std::vector<SavedDeskItemView*> grid_items = static_cast<DesksTemplatesGridView*>(GetOverviewGridList()[0] ->desks_templates_grid_widget() ->GetContentsView()) @@ -3349,7 +3347,7 @@ // The name view should release focus after getting a gesture tap outside // the grid item. - std::vector<DesksTemplatesItemView*> grid_items = + std::vector<SavedDeskItemView*> grid_items = static_cast<DesksTemplatesGridView*>(GetOverviewGridList()[0] ->desks_templates_grid_widget() ->GetContentsView()) @@ -3377,7 +3375,7 @@ // Find a point that doesn't touch the item view, but is still in the grid // widget's window bounds. Right clicking this point should not close // overview, as it should open the wallpaper context menu. - DesksTemplatesItemView* item_view = + SavedDeskItemView* item_view = GetItemViewFromTemplatesGrid(/*grid_item_index=*/0); DCHECK(item_view); gfx::Rect item_view_expanded_bounds = item_view->GetBoundsInScreen(); @@ -3418,7 +3416,7 @@ OpenOverviewAndShowTemplatesGrid(); // Click on the template item to launch the new template. - DesksTemplatesItemView* template_item = + SavedDeskItemView* template_item = GetItemViewFromTemplatesGrid(/*grid_item_index=*/0); DCHECK(template_item); ClickOnView(template_item); @@ -3491,7 +3489,7 @@ // Set the second template to have a new unique name by updating the model // directly. This mimics updating the name on a different device and is the // only way to change the name without prompting the replace dialog. - DesksTemplatesItemView* second_item = GetItemViewFromTemplatesGrid(1); + SavedDeskItemView* second_item = GetItemViewFromTemplatesGrid(1); auto new_desk_template = second_item->desk_template()->Clone(); new_desk_template->set_template_name(u"Desk 2"); DeskTemplate* new_desk_template_ptr = new_desk_template.get(); @@ -3668,7 +3666,7 @@ OpenOverviewAndShowTemplatesGrid(); // Tests that the name is read only and not focusable. - DesksTemplatesItemView* item_view = + SavedDeskItemView* item_view = GetItemViewFromTemplatesGrid(/*grid_item_index=*/0); SavedDeskNameView* name_view = item_view->name_view(); EXPECT_TRUE(name_view->GetReadOnly()); @@ -3676,7 +3674,7 @@ // Tests that there is an admin message in the time view and that the delete // button is not created. - DesksTemplatesItemViewTestApi test_api(item_view); + SavedDeskItemViewTestApi test_api(item_view); EXPECT_EQ(u"Shared by your administrator", test_api.time_view()->GetText()); EXPECT_FALSE(test_api.delete_button()); @@ -3774,7 +3772,7 @@ OpenOverviewAndSaveDeskForLater(Shell::Get()->GetPrimaryRootWindow()); // Recall the desk. - DesksTemplatesItemView* template_item = + SavedDeskItemView* template_item = GetItemViewFromTemplatesGrid(/*grid_item_index=*/0); ASSERT_TRUE(template_item); ClickOnView(template_item);
diff --git a/ash/wm/desks/templates/desks_templates_item_view.cc b/ash/wm/desks/templates/saved_desk_item_view.cc similarity index 88% rename from ash/wm/desks/templates/desks_templates_item_view.cc rename to ash/wm/desks/templates/saved_desk_item_view.cc index c8d77f1f..38ed8781 100644 --- a/ash/wm/desks/templates/desks_templates_item_view.cc +++ b/ash/wm/desks/templates/saved_desk_item_view.cc
@@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#include "ash/wm/desks/templates/desks_templates_item_view.h" +#include "ash/wm/desks/templates/saved_desk_item_view.h" #include <string> @@ -55,14 +55,14 @@ namespace ash { namespace { -// The padding values of the DesksTemplatesItemView. +// The padding values of the SavedDeskItemView. constexpr int kHorizontalPaddingDp = 24; constexpr int kVerticalPaddingDp = 16; -// The preferred size of the whole DesksTemplatesItemView. +// The preferred size of the whole SavedDeskItemView. constexpr gfx::Size kPreferredSize(220, 120); -// The corner radius for the DesksTemplatesItemView. +// The corner radius for the SavedDeskItemView. constexpr int kCornerRadius = 16; // The margin for the delete button. @@ -115,12 +115,10 @@ } // namespace -DesksTemplatesItemView::DesksTemplatesItemView( - const DeskTemplate* desk_template) +SavedDeskItemView::SavedDeskItemView(const DeskTemplate* desk_template) : desk_template_(desk_template->Clone()) { - auto launch_template_callback = - base::BindRepeating(&DesksTemplatesItemView::OnGridItemPressed, - weak_ptr_factory_.GetWeakPtr()); + auto launch_template_callback = base::BindRepeating( + &SavedDeskItemView::OnGridItemPressed, weak_ptr_factory_.GetWeakPtr()); const std::u16string template_name = desk_template_->template_name(); DCHECK(!template_name.empty()); @@ -128,7 +126,7 @@ const bool is_admin_managed = desk_template_->source() == DeskTemplateSource::kPolicy; - views::Builder<DesksTemplatesItemView>(this) + views::Builder<SavedDeskItemView>(this) .SetPreferredSize(kPreferredSize) .SetUseDefaultFillLayout(true) .SetAccessibleName(template_name) @@ -208,7 +206,7 @@ layer()->SetFillsBoundsOpaquely(false); launch_button_ = hover_container_->AddChildView(std::make_unique<PillButton>( - base::BindRepeating(&DesksTemplatesItemView::OnGridItemPressed, + base::BindRepeating(&SavedDeskItemView::OnGridItemPressed, weak_ptr_factory_.GetWeakPtr()), l10n_util::GetStringUTF16(IDS_ASH_DESKS_TEMPLATES_USE_TEMPLATE_BUTTON), PillButton::Type::kIconless, /*icon=*/nullptr)); @@ -217,7 +215,7 @@ if (!is_admin_managed) { delete_button_ = hover_container_->AddChildView(std::make_unique<CloseButton>( - base::BindRepeating(&DesksTemplatesItemView::OnDeleteButtonPressed, + base::BindRepeating(&SavedDeskItemView::OnDeleteButtonPressed, weak_ptr_factory_.GetWeakPtr()), CloseButton::Type::kMedium)); delete_button_->SetVectorIcon(kDeleteIcon); @@ -252,17 +250,17 @@ views::FocusRing* focus_ring = StyleUtil::SetUpFocusRingForView(this, kFocusRingHaloInset); focus_ring->SetHasFocusPredicate([](views::View* view) { - return static_cast<DesksTemplatesItemView*>(view)->IsViewHighlighted(); + return static_cast<SavedDeskItemView*>(view)->IsViewHighlighted(); }); SetEventTargeter(std::make_unique<views::ViewTargeter>(this)); } -DesksTemplatesItemView::~DesksTemplatesItemView() { +SavedDeskItemView::~SavedDeskItemView() { name_view_observation_.Reset(); } -void DesksTemplatesItemView::UpdateHoverButtonsVisibility( +void SavedDeskItemView::UpdateHoverButtonsVisibility( const gfx::Point& screen_location, bool is_touch) { gfx::Point location_in_view = screen_location; @@ -279,11 +277,11 @@ icon_container_view_->SetVisible(!visible); } -bool DesksTemplatesItemView::IsTemplateNameBeingModified() const { +bool SavedDeskItemView::IsNameBeingModified() const { return name_view_->HasFocus(); } -void DesksTemplatesItemView::MaybeRemoveNameNumber() { +void SavedDeskItemView::MaybeRemoveNameNumber() { // When there are existing matched Desk name and Template name (ie. // "Desk 1"), creating a new template from "Desk 1" will get auto generated // template name from backend as "Desk 1 (1)", to prevent template @@ -298,7 +296,7 @@ } } -void DesksTemplatesItemView::ReplaceTemplate(const std::string& uuid) { +void SavedDeskItemView::ReplaceTemplate(const std::string& uuid) { // Make sure we delete the template we are replacing first, so that we don't // get template name collisions. DesksTemplatesPresenter::Get()->DeleteEntry(uuid); @@ -306,7 +304,7 @@ RecordReplaceTemplateHistogram(); } -void DesksTemplatesItemView::RevertTemplateName() { +void SavedDeskItemView::RevertTemplateName() { views::FocusManager* focus_manager = GetFocusManager(); focus_manager->SetFocusedView(name_view_); const auto temporary_name = name_view_->temporary_name(); @@ -317,8 +315,7 @@ name_view_->OnContentsChanged(); } -void DesksTemplatesItemView::UpdateTemplate( - const DeskTemplate& updated_template) { +void SavedDeskItemView::UpdateTemplate(const DeskTemplate& updated_template) { desk_template_ = updated_template.Clone(); hover_container_->SetVisible(false); @@ -335,7 +332,7 @@ name_view_->OnContentsChanged(); } -void DesksTemplatesItemView::Layout() { +void SavedDeskItemView::Layout() { const int previous_name_view_width = name_view_->width(); views::View::Layout(); @@ -363,7 +360,7 @@ launch_button_preferred_size)); } -void DesksTemplatesItemView::OnThemeChanged() { +void SavedDeskItemView::OnThemeChanged() { views::View::OnThemeChanged(); auto* color_provider = AshColorProvider::Get(); GetBackground()->SetNativeControlColor(color_provider->GetBaseLayerColor( @@ -377,7 +374,7 @@ AshColorProvider::ControlsLayerType::kFocusRingColor)); } -void DesksTemplatesItemView::OnViewFocused(views::View* observed_view) { +void SavedDeskItemView::OnViewFocused(views::View* observed_view) { // `this` is a button which observes itself. Here we only care about focus on // `name_view_`. if (observed_view == this) @@ -407,7 +404,7 @@ name_view_->SelectAll(false); } -void DesksTemplatesItemView::OnViewBlurred(views::View* observed_view) { +void SavedDeskItemView::OnViewBlurred(views::View* observed_view) { // `this` is a button which observes itself. Here we only care about blur on // `name_view_`. if (observed_view == this) @@ -470,7 +467,7 @@ if (template_to_replace) { base::ThreadTaskRunnerHandle::Get()->PostTask( FROM_HERE, - base::BindOnce(&DesksTemplatesItemView::MaybeShowReplaceDialog, + base::BindOnce(&SavedDeskItemView::MaybeShowReplaceDialog, weak_ptr_factory_.GetWeakPtr(), template_to_replace)); return; } @@ -478,22 +475,21 @@ UpdateTemplateName(); } -void DesksTemplatesItemView::MaybeShowReplaceDialog( - DesksTemplatesItemView* template_to_replace) { +void SavedDeskItemView::MaybeShowReplaceDialog( + SavedDeskItemView* template_to_replace) { // Show replace template dialog. If accepted, replace old template and commit // name change. aura::Window* root_window = GetWidget()->GetNativeWindow()->GetRootWindow(); DesksTemplatesDialogController::Get()->ShowReplaceDialog( root_window, name_view_->GetText(), base::BindOnce( - &DesksTemplatesItemView::ReplaceTemplate, - weak_ptr_factory_.GetWeakPtr(), + &SavedDeskItemView::ReplaceTemplate, weak_ptr_factory_.GetWeakPtr(), template_to_replace->desk_template_->uuid().AsLowercaseString()), - base::BindOnce(&DesksTemplatesItemView::RevertTemplateName, + base::BindOnce(&SavedDeskItemView::RevertTemplateName, weak_ptr_factory_.GetWeakPtr())); } -views::Button::KeyClickAction DesksTemplatesItemView::GetKeyClickActionForEvent( +views::Button::KeyClickAction SavedDeskItemView::GetKeyClickActionForEvent( const ui::KeyEvent& event) { // Prevents any key events from activating a button click while the template // name is being modified. @@ -503,7 +499,7 @@ return Button::GetKeyClickActionForEvent(event); } -void DesksTemplatesItemView::UpdateTemplateName() { +void SavedDeskItemView::UpdateTemplateName() { desk_template_->set_template_name(name_view_->GetText()); OnTemplateNameChanged(desk_template_->template_name()); @@ -512,9 +508,8 @@ desk_template_->Clone()); } -void DesksTemplatesItemView::ContentsChanged( - views::Textfield* sender, - const std::u16string& new_contents) { +void SavedDeskItemView::ContentsChanged(views::Textfield* sender, + const std::u16string& new_contents) { DCHECK_EQ(sender, name_view_); // To avoid potential security and memory issues, we don't allow template @@ -537,8 +532,8 @@ } } -bool DesksTemplatesItemView::HandleKeyEvent(views::Textfield* sender, - const ui::KeyEvent& key_event) { +bool SavedDeskItemView::HandleKeyEvent(views::Textfield* sender, + const ui::KeyEvent& key_event) { DCHECK_EQ(sender, name_view_); DCHECK(is_template_name_being_modified_); @@ -564,9 +559,8 @@ return true; } -bool DesksTemplatesItemView::HandleMouseEvent( - views::Textfield* sender, - const ui::MouseEvent& mouse_event) { +bool SavedDeskItemView::HandleMouseEvent(views::Textfield* sender, + const ui::MouseEvent& mouse_event) { DCHECK_EQ(sender, name_view_); switch (mouse_event.type()) { @@ -599,8 +593,8 @@ return false; } -views::View* DesksTemplatesItemView::TargetForRect(views::View* root, - const gfx::Rect& rect) { +views::View* SavedDeskItemView::TargetForRect(views::View* root, + const gfx::Rect& rect) { gfx::RectF name_view_bounds(name_view_->GetMirroredBounds()); views::View::ConvertRectToTarget(name_view_->parent(), this, &name_view_bounds); @@ -618,14 +612,14 @@ return views::ViewTargeterDelegate::TargetForRect(root, rect); } -DesksTemplatesItemView* DesksTemplatesItemView::FindOtherTemplateWithName( +SavedDeskItemView* SavedDeskItemView::FindOtherTemplateWithName( const std::u16string& name) const { const auto templates_grid_view_items = static_cast<const DesksTemplatesGridView*>(parent())->grid_items(); auto iter = std::find_if( templates_grid_view_items.begin(), templates_grid_view_items.end(), - [this, name](const DesksTemplatesItemView* d) { + [this, name](const SavedDeskItemView* d) { // Name duplication is allowed if one of the templates is an admin // template. return (d != this && d->desk_template()->template_name() == name && @@ -634,26 +628,26 @@ return iter == templates_grid_view_items.end() ? nullptr : *iter; } -void DesksTemplatesItemView::OnDeleteTemplate() { +void SavedDeskItemView::OnDeleteTemplate() { DesksTemplatesPresenter::Get()->DeleteEntry( desk_template_->uuid().AsLowercaseString()); } -void DesksTemplatesItemView::OnDeleteButtonPressed() { +void SavedDeskItemView::OnDeleteButtonPressed() { // Show the dialog to confirm the deletion. auto* dialog_controller = DesksTemplatesDialogController::Get(); dialog_controller->ShowDeleteDialog( GetWidget()->GetNativeWindow()->GetRootWindow(), name_view_->GetAccessibleName(), - base::BindOnce(&DesksTemplatesItemView::OnDeleteTemplate, + base::BindOnce(&SavedDeskItemView::OnDeleteTemplate, weak_ptr_factory_.GetWeakPtr())); } -void DesksTemplatesItemView::OnGridItemPressed(const ui::Event& event) { +void SavedDeskItemView::OnGridItemPressed(const ui::Event& event) { MaybeLaunchTemplate(event.IsShiftDown()); } -void DesksTemplatesItemView::MaybeLaunchTemplate(bool should_delay) { +void SavedDeskItemView::MaybeLaunchTemplate(bool should_delay) { if (is_template_name_being_modified_) { SavedDeskNameView::CommitChanges(GetWidget()); return; @@ -673,8 +667,7 @@ GetWidget()->GetNativeWindow()->GetRootWindow()); } -void DesksTemplatesItemView::OnTemplateNameChanged( - const std::u16string& new_name) { +void SavedDeskItemView::OnTemplateNameChanged(const std::u16string& new_name) { if (is_template_name_being_modified_) return; @@ -689,29 +682,29 @@ name_view_->OnContentsChanged(); } -views::View* DesksTemplatesItemView::GetView() { +views::View* SavedDeskItemView::GetView() { return this; } -void DesksTemplatesItemView::MaybeActivateHighlightedView() { +void SavedDeskItemView::MaybeActivateHighlightedView() { MaybeLaunchTemplate(/*should_delay=*/false); } -void DesksTemplatesItemView::MaybeCloseHighlightedView() { +void SavedDeskItemView::MaybeCloseHighlightedView() { OnDeleteButtonPressed(); } -void DesksTemplatesItemView::MaybeSwapHighlightedView(bool right) {} +void SavedDeskItemView::MaybeSwapHighlightedView(bool right) {} -void DesksTemplatesItemView::OnViewHighlighted() { +void SavedDeskItemView::OnViewHighlighted() { views::FocusRing::Get(this)->SchedulePaint(); } -void DesksTemplatesItemView::OnViewUnhighlighted() { +void SavedDeskItemView::OnViewUnhighlighted() { views::FocusRing::Get(this)->SchedulePaint(); } -BEGIN_METADATA(DesksTemplatesItemView, views::Button) +BEGIN_METADATA(SavedDeskItemView, views::Button) END_METADATA } // namespace ash
diff --git a/ash/wm/desks/templates/desks_templates_item_view.h b/ash/wm/desks/templates/saved_desk_item_view.h similarity index 80% rename from ash/wm/desks/templates/desks_templates_item_view.h rename to ash/wm/desks/templates/saved_desk_item_view.h index b810e991..3c132b49 100644 --- a/ash/wm/desks/templates/desks_templates_item_view.h +++ b/ash/wm/desks/templates/saved_desk_item_view.h
@@ -2,8 +2,8 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#ifndef ASH_WM_DESKS_TEMPLATES_DESKS_TEMPLATES_ITEM_VIEW_H_ -#define ASH_WM_DESKS_TEMPLATES_DESKS_TEMPLATES_ITEM_VIEW_H_ +#ifndef ASH_WM_DESKS_TEMPLATES_SAVED_DESK_ITEM_VIEW_H_ +#define ASH_WM_DESKS_TEMPLATES_SAVED_DESK_ITEM_VIEW_H_ #include "ash/ash_export.h" #include "ash/public/cpp/desk_template.h" @@ -61,17 +61,17 @@ // // The whole view is also a button which does the same thing as `launch_button_` // when clicked. -class ASH_EXPORT DesksTemplatesItemView : public views::Button, - public OverviewHighlightableView, - public views::ViewTargeterDelegate, - public views::TextfieldController { +class ASH_EXPORT SavedDeskItemView : public views::Button, + public OverviewHighlightableView, + public views::ViewTargeterDelegate, + public views::TextfieldController { public: - METADATA_HEADER(DesksTemplatesItemView); + METADATA_HEADER(SavedDeskItemView); - explicit DesksTemplatesItemView(const DeskTemplate* desk_template); - DesksTemplatesItemView(const DesksTemplatesItemView&) = delete; - DesksTemplatesItemView& operator=(const DesksTemplatesItemView&) = delete; - ~DesksTemplatesItemView() override; + explicit SavedDeskItemView(const DeskTemplate* desk_template); + SavedDeskItemView(const SavedDeskItemView&) = delete; + SavedDeskItemView& operator=(const SavedDeskItemView&) = delete; + ~SavedDeskItemView() override; DeskTemplate* desk_template() const { return desk_template_.get(); } SavedDeskNameView* name_view() const { return name_view_; } @@ -82,18 +82,18 @@ void UpdateHoverButtonsVisibility(const gfx::Point& screen_location, bool is_touch); - // Returns true if the template's name is being modified (i.e. the + // Returns true if the saved desk's name is being modified (i.e. the // `SavedDeskNameView` has the focus). - bool IsTemplateNameBeingModified() const; + bool IsNameBeingModified() const; - // To prevent duplications when creating template from the same desk, check if - // there's a existing template shares the same name as current active desk, if + // To prevent duplications when saving a desk multiple times, check if there's + // an existing saved desk that shares the same name as current active desk, if // so, remove auto added number. void MaybeRemoveNameNumber(); // Show replace dialog when found a name duplication. - void MaybeShowReplaceDialog(DesksTemplatesItemView* template_to_replace); - // Rename current template with new name, delete old template with same name - // by uuid. Used for callback functions for Replace Dialog. + void MaybeShowReplaceDialog(SavedDeskItemView* saved_desk_to_replace); + // Rename current saved desk with new name, delete old saved desk with same + // name by uuid. Used for callback functions for Replace Dialog. void ReplaceTemplate(const std::string& uuid); void RevertTemplateName(); @@ -123,11 +123,11 @@ views::View* TargetForRect(views::View* root, const gfx::Rect& rect) override; private: - friend class DesksTemplatesItemViewTestApi; + friend class SavedDeskItemViewTestApi; - // Return the duplicated template item if there is a name duplication in saved - // templates. - DesksTemplatesItemView* FindOtherTemplateWithName( + // Return the duplicated saved desk item if there is a name duplication in + // saved desks. + SavedDeskItemView* FindOtherTemplateWithName( const std::u16string& name) const; void OnDeleteTemplate(); @@ -155,7 +155,7 @@ void OnViewHighlighted() override; void OnViewUnhighlighted() override; - // A copy of the associated desk template. + // A copy of the associated saved desk. std::unique_ptr<DeskTemplate> desk_template_; // Owned by the views hierarchy. @@ -191,14 +191,14 @@ base::ScopedObservation<views::View, views::ViewObserver> name_view_observation_{this}; - base::WeakPtrFactory<DesksTemplatesItemView> weak_ptr_factory_{this}; + base::WeakPtrFactory<SavedDeskItemView> weak_ptr_factory_{this}; }; -BEGIN_VIEW_BUILDER(/* no export */, DesksTemplatesItemView, views::Button) +BEGIN_VIEW_BUILDER(/* no export */, SavedDeskItemView, views::Button) END_VIEW_BUILDER } // namespace ash -DEFINE_VIEW_BUILDER(/* no export */, ash::DesksTemplatesItemView) +DEFINE_VIEW_BUILDER(/* no export */, ash::SavedDeskItemView) -#endif // ASH_WM_DESKS_TEMPLATES_DESKS_TEMPLATES_ITEM_VIEW_H_ +#endif // ASH_WM_DESKS_TEMPLATES_SAVED_DESK_ITEM_VIEW_H_
diff --git a/ash/wm/overview/overview_highlight_controller.cc b/ash/wm/overview/overview_highlight_controller.cc index 34ef996..a90e46e9 100644 --- a/ash/wm/overview/overview_highlight_controller.cc +++ b/ash/wm/overview/overview_highlight_controller.cc
@@ -16,8 +16,8 @@ #include "ash/wm/desks/desks_util.h" #include "ash/wm/desks/expanded_desks_bar_button.h" #include "ash/wm/desks/templates/desks_templates_grid_view.h" -#include "ash/wm/desks/templates/desks_templates_item_view.h" #include "ash/wm/desks/templates/save_desk_template_button.h" +#include "ash/wm/desks/templates/saved_desk_item_view.h" #include "ash/wm/desks/templates/saved_desk_name_view.h" #include "ash/wm/desks/zero_state_button.h" #include "ash/wm/overview/overview_grid.h" @@ -208,14 +208,14 @@ DCHECK(templates_grid_widget); auto* templates_grid_view = static_cast<DesksTemplatesGridView*>( templates_grid_widget->GetContentsView()); - for (DesksTemplatesItemView* template_item : + for (SavedDeskItemView* saved_desk_item : templates_grid_view->grid_items()) { - traversable_views.push_back(template_item); + traversable_views.push_back(saved_desk_item); // Admin templates names cannot be edited or focused. - SavedDeskNameView* name_view = template_item->name_view(); + SavedDeskNameView* name_view = saved_desk_item->name_view(); if (name_view->IsFocusable()) - traversable_views.push_back(template_item->name_view()); + traversable_views.push_back(name_view); } } else { for (auto& item : grid->window_list())
diff --git a/ash/wm/workspace/phantom_window_controller.cc b/ash/wm/workspace/phantom_window_controller.cc index 9bf3842..adc569e 100644 --- a/ash/wm/workspace/phantom_window_controller.cc +++ b/ash/wm/workspace/phantom_window_controller.cc
@@ -30,6 +30,7 @@ #include "ui/views/layout/box_layout.h" #include "ui/views/view.h" #include "ui/views/widget/widget.h" +#include "ui/wm/core/coordinate_conversion.h" #include "ui/wm/core/shadow_controller.h" #include "ui/wm/core/shadow_types.h" @@ -308,13 +309,17 @@ phantom_widget_->SetOpacity(0); ui::Layer* widget_layer = phantom_widget_->GetLayer(); + // Layer uses bounds in parent so convert from screen bounds. + gfx::Rect bounds = target_bounds_in_screen_; + wm::ConvertRectFromScreen(phantom_widget_->GetNativeWindow()->parent(), + &bounds); + views::AnimationBuilder() .SetPreemptionStrategy( ui::LayerAnimator::IMMEDIATELY_ANIMATE_TO_NEW_TARGET) .Once() .SetDuration(kScrimEntranceSizeAnimationDurationMs) - .SetBounds(widget_layer, target_bounds_in_screen_, - gfx::Tween::ACCEL_20_DECEL_100) + .SetBounds(widget_layer, bounds, gfx::Tween::ACCEL_20_DECEL_100) .At(base::Seconds(0)) .SetDuration(kScrimEntranceOpacityAnimationDurationMs) .SetOpacity(widget_layer, 1, gfx::Tween::LINEAR);
diff --git a/base/BUILD.gn b/base/BUILD.gn index 194828a..8339521 100644 --- a/base/BUILD.gn +++ b/base/BUILD.gn
@@ -308,6 +308,8 @@ "export_template.h", "feature_list.cc", "feature_list.h", + "features.cc", + "features.h", "file_descriptor_store.cc", "file_descriptor_store.h", "file_version_info.h", @@ -3972,7 +3974,10 @@ java_cpp_features("java_features_srcjar") { # External code should depend on ":base_java" instead. visibility = [ ":*" ] - sources = [ "android/base_features.cc" ] + sources = [ + "android/base_features.cc", + "features.cc", + ] template = "android/java/src/org/chromium/base/BaseFeatures.java.tmpl" }
diff --git a/base/features.cc b/base/features.cc new file mode 100644 index 0000000..a25ed3a --- /dev/null +++ b/base/features.cc
@@ -0,0 +1,16 @@ +// Copyright 2022 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#include "base/features.h" +#include "base/feature_list.h" + +namespace base::features { + +// Alphabetical: + +// Optimizes parsing and loading of data: URLs. +const base::Feature kOptimizeDataUrls{"OptimizeDataUrls", + FEATURE_DISABLED_BY_DEFAULT}; + +} // namespace base::features
diff --git a/base/features.h b/base/features.h new file mode 100644 index 0000000..4bdc1cf --- /dev/null +++ b/base/features.h
@@ -0,0 +1,21 @@ +// Copyright 2022 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#ifndef BASE_FEATURES_H_ +#define BASE_FEATURES_H_ + +#include "base/base_export.h" +#include "base/feature_list.h" + +namespace base::features { + +// All features in alphabetical order. The features should be documented +// alongside the definition of their values in the .cc file. + +// Alphabetical: +BASE_EXPORT extern const base::Feature kOptimizeDataUrls; + +} // namespace base::features + +#endif // BASE_FEATURES_H_
diff --git a/base/strings/escape.cc b/base/strings/escape.cc index 8b17a59..8b98c04 100644 --- a/base/strings/escape.cc +++ b/base/strings/escape.cc
@@ -7,6 +7,8 @@ #include <ostream> #include "base/check_op.h" +#include "base/feature_list.h" +#include "base/features.h" #include "base/strings/string_piece.h" #include "base/strings/string_util.h" #include "base/strings/utf_string_conversion_utils.h" @@ -540,6 +542,16 @@ DCHECK(!(rules & ~(UnescapeRule::NORMAL | UnescapeRule::REPLACE_PLUS_WITH_SPACE))); + // If there are no '%' characters in the string, there will be nothing to + // unescape, so we can take the fast path. + if (base::FeatureList::IsEnabled(features::kOptimizeDataUrls) && + escaped_text.find('%') == StringPiece::npos) { + std::string unescaped_text(escaped_text); + if (rules & UnescapeRule::REPLACE_PLUS_WITH_SPACE) + std::replace(unescaped_text.begin(), unescaped_text.end(), '+', ' '); + return unescaped_text; + } + std::string unescaped_text; // The output of the unescaping is always smaller than the input, so we can
diff --git a/build/android/gyp/bundletool.py b/build/android/gyp/bundletool.py index 269b85d..6fb25e5 100755 --- a/build/android/gyp/bundletool.py +++ b/build/android/gyp/bundletool.py
@@ -8,9 +8,10 @@ Bundletool is distributed as a versioned jar file. This script abstracts the location and version of this jar file, as well as the JVM invokation.""" +# Warning: Check if still being run as python2: https://crbug.com/1322618 + import logging import os -import shlex import sys from util import build_utils @@ -31,7 +32,7 @@ cmd = build_utils.JavaCmd(verify, xmx='4G') cmd += ['-jar', BUNDLETOOL_JAR_PATH] cmd += args - logging.debug('%s', shlex.join(cmd)) + logging.debug(' '.join(cmd)) return build_utils.CheckOutput( cmd, print_stdout=print_stdout,
diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn index f378b956..e3484c7 100644 --- a/build/config/compiler/BUILD.gn +++ b/build/config/compiler/BUILD.gn
@@ -1534,15 +1534,6 @@ cflags += [ "-Wno-unqualified-std-cast-call" ] } - if (!is_nacl && !(is_chromeos || - default_toolchain == "//build/toolchain/cros:target")) { - # TODO(https://crbug.com/1316298): Re-enable once test failure is figured out - cflags += [ - "-Xclang", - "-no-opaque-pointers", - ] - } - if (is_fuchsia) { # TODO(https://bugs.chromium.org/p/fuchsia/issues/detail?id=77383) cflags += [ "-Wno-deprecated-copy" ]
diff --git a/build/print_python_deps.py b/build/print_python_deps.py index 67d69980..57dd304 100755 --- a/build/print_python_deps.py +++ b/build/print_python_deps.py
@@ -48,6 +48,13 @@ return src_paths +def quote(string): + if string.count(' ') > 0: + return '"%s"' % string + else: + return string + + def _NormalizeCommandLine(options): """Returns a string that when run from SRC_ROOT replicates the command.""" args = ['build/print_python_deps.py'] @@ -61,7 +68,10 @@ for allowlist in sorted(options.allowlists): args.extend(('--allowlist', os.path.relpath(allowlist, _SRC_ROOT))) args.append(os.path.relpath(options.module, _SRC_ROOT)) - return ' '.join(pipes.quote(x) for x in args) + if os.name == 'nt': + return ' '.join(quote(x) for x in args).replace('\\', '/') + else: + return ' '.join(pipes.quote(x) for x in args) def _FindPythonInDirectory(directory, allow_test): @@ -203,14 +213,14 @@ paths = [os.path.relpath(p, options.root) for p in paths_set] normalized_cmdline = _NormalizeCommandLine(options) - out = open(options.output, 'w') if options.output else sys.stdout + out = open(options.output, 'w', newline='') if options.output else sys.stdout with out: if not options.no_header: out.write('# Generated by running:\n') out.write('# %s\n' % normalized_cmdline) prefix = '//' if options.gn_paths else '' for path in sorted(paths): - out.write(prefix + path + '\n') + out.write(prefix + path.replace('\\', '/') + '\n') if __name__ == '__main__':
diff --git a/cc/paint/paint_op_reader.cc b/cc/paint/paint_op_reader.cc index 223d78e0..b1e233a7 100644 --- a/cc/paint/paint_op_reader.cc +++ b/cc/paint/paint_op_reader.cc
@@ -160,6 +160,8 @@ void PaintOpReader::ReadSize(size_t* size) { AlignMemory(8); + if (!valid_) + return; uint64_t size64 = 0; ReadSimple(&size64); *size = size64;
diff --git a/chrome/android/BUILD.gn b/chrome/android/BUILD.gn index 1fa38826..12d89e83 100644 --- a/chrome/android/BUILD.gn +++ b/chrome/android/BUILD.gn
@@ -341,6 +341,7 @@ "//cc:cc_java", "//chrome/android/features/keyboard_accessory:public_java", "//chrome/android/features/start_surface:public_java", + "//chrome/android/features/start_surface/internal:java_resources", "//chrome/android/modules/cablev2_authenticator/public:java", "//chrome/android/modules/image_editor/provider:java", "//chrome/android/modules/stack_unwinder/provider:java", @@ -632,6 +633,7 @@ "//third_party/androidx:androidx_localbroadcastmanager_localbroadcastmanager_java", "//third_party/androidx:androidx_mediarouter_mediarouter_java", "//third_party/androidx:androidx_preference_preference_java", + "//third_party/androidx:androidx_vectordrawable_vectordrawable_animated_java", "//third_party/androidx:androidx_viewpager2_viewpager2_java", "//third_party/androidx:androidx_viewpager_viewpager_java", "//third_party/blink/public:blink_headers_java", @@ -714,6 +716,15 @@ processor_args_javac = [ "dagger.fastInit=enabled" ] + if (!is_java_debug) { + if (!defined(proguard_configs)) { + proguard_configs = [] + } + proguard_enabled = true + proguard_configs += + [ "//chrome/android/features/start_surface/internal/proguard.flags" ] + } + resources_package = "org.chromium.chrome" # TODO(crbug/1022172): Instead of adding source files, add it as a separate @@ -946,7 +957,6 @@ "//chrome/android/features/android_library_factory:junit_tests", "//chrome/android/features/keyboard_accessory:internal_java", "//chrome/android/features/start_surface:public_java", - "//chrome/android/features/start_surface/internal:java", "//chrome/android/features/tab_ui:java", "//chrome/android/modules/image_editor/provider:java", "//chrome/android/webapk/libs/client:client_java", @@ -1353,7 +1363,6 @@ "//cc:cc_java", "//chrome/android:chrome_java", "//chrome/android/features/start_surface:public_java", - "//chrome/android/features/start_surface/internal:java", "//chrome/android/features/start_surface/internal:java_resources", "//chrome/android/features/tab_ui:java", "//chrome/android/features/tab_ui:java_resources",
diff --git a/chrome/android/features/start_surface/BUILD.gn b/chrome/android/features/start_surface/BUILD.gn index d61ec7a..c067176 100644 --- a/chrome/android/features/start_surface/BUILD.gn +++ b/chrome/android/features/start_surface/BUILD.gn
@@ -38,5 +38,5 @@ android_library("test_support_java") { sources = [ "internal/javatests/src/org/chromium/chrome/features/start_surface/ViewIds.java" ] - deps = [ "//chrome/android/features/start_surface/internal:java" ] + deps = [ "//chrome/android:chrome_java" ] }
diff --git a/chrome/android/features/start_surface/internal/BUILD.gn b/chrome/android/features/start_surface/internal/BUILD.gn index 1b58016..f33295a 100644 --- a/chrome/android/features/start_surface/internal/BUILD.gn +++ b/chrome/android/features/start_surface/internal/BUILD.gn
@@ -45,90 +45,3 @@ "//chrome/android/features/tab_ui:java_resources", ] } - -android_library("java") { - sources = [ - "java/src/org/chromium/chrome/features/start_surface/BackgroundTabAnimation.java", - "java/src/org/chromium/chrome/features/start_surface/BottomBarCoordinator.java", - "java/src/org/chromium/chrome/features/start_surface/BottomBarView.java", - "java/src/org/chromium/chrome/features/start_surface/BottomBarViewBinder.java", - "java/src/org/chromium/chrome/features/start_surface/ExploreSurfaceCoordinator.java", - "java/src/org/chromium/chrome/features/start_surface/ExploreSurfaceCoordinatorFactory.java", - "java/src/org/chromium/chrome/features/start_surface/ExploreSurfaceFeedLifecycleManager.java", - "java/src/org/chromium/chrome/features/start_surface/ExploreSurfaceNavigationDelegate.java", - "java/src/org/chromium/chrome/features/start_surface/ExploreSurfaceViewBinder.java", - "java/src/org/chromium/chrome/features/start_surface/FeedPlaceholderCoordinator.java", - "java/src/org/chromium/chrome/features/start_surface/ReturnToStartSurfaceUtil.java", - "java/src/org/chromium/chrome/features/start_surface/SecondaryTasksSurfaceViewBinder.java", - "java/src/org/chromium/chrome/features/start_surface/StartSurfaceCoordinator.java", - "java/src/org/chromium/chrome/features/start_surface/StartSurfaceDelegate.java", - "java/src/org/chromium/chrome/features/start_surface/StartSurfaceLayout.java", - "java/src/org/chromium/chrome/features/start_surface/StartSurfaceMediator.java", - "java/src/org/chromium/chrome/features/start_surface/StartSurfaceProperties.java", - "java/src/org/chromium/chrome/features/start_surface/TasksSurfaceViewBinder.java", - "java/src/org/chromium/chrome/features/tasks/SingleTabSwitcherCoordinator.java", - "java/src/org/chromium/chrome/features/tasks/SingleTabSwitcherMediator.java", - "java/src/org/chromium/chrome/features/tasks/SingleTabView.java", - "java/src/org/chromium/chrome/features/tasks/SingleTabViewBinder.java", - "java/src/org/chromium/chrome/features/tasks/SingleTabViewProperties.java", - "java/src/org/chromium/chrome/features/tasks/TasksSurfaceCoordinator.java", - "java/src/org/chromium/chrome/features/tasks/TasksSurfaceMediator.java", - "java/src/org/chromium/chrome/features/tasks/TasksSurfaceProperties.java", - "java/src/org/chromium/chrome/features/tasks/TasksView.java", - "java/src/org/chromium/chrome/features/tasks/TasksViewBinder.java", - ] - - deps = [ - ":java_resources", - "//base:base_java", - "//chrome/android:chrome_java", - "//chrome/android/features/start_surface:public_java", - "//chrome/android/feed:chrome_feed_java_resources", - "//chrome/browser/android/lifecycle:java", - "//chrome/browser/browser_controls/android:java", - "//chrome/browser/feed/android:java", - "//chrome/browser/feedback/android:java", - "//chrome/browser/flags:java", - "//chrome/browser/lens:java", - "//chrome/browser/preferences:java", - "//chrome/browser/profiles/android:java", - "//chrome/browser/tab:java", - "//chrome/browser/tabmodel:java", - "//chrome/browser/ui/android/layouts:java", - "//chrome/browser/ui/android/layouts/third_party/float_property:java", - "//chrome/browser/ui/android/omnibox:java", - "//chrome/browser/ui/android/toolbar:java", - "//chrome/browser/ui/messages/android:java", - "//chrome/browser/util:java", - "//chrome/browser/xsurface:java", - "//components/browser_ui/bottomsheet/android:java", - "//components/browser_ui/styles/android:java", - "//components/browser_ui/widget/android:java", - "//components/content_settings/android:content_settings_enums_java", - "//components/embedder_support/android:util_java", - "//components/prefs/android:java", - "//components/user_prefs/android:java", - "//components/version_info/android:version_constants_java", - "//content/public/android:content_java", - "//third_party/android_deps:material_design_java", - "//third_party/androidx:androidx_annotation_annotation_java", - "//third_party/androidx:androidx_appcompat_appcompat_java", - "//third_party/androidx:androidx_appcompat_appcompat_resources_java", - "//third_party/androidx:androidx_browser_browser_java", - "//third_party/androidx:androidx_coordinatorlayout_coordinatorlayout_java", - "//third_party/androidx:androidx_core_core_java", - "//third_party/androidx:androidx_recyclerview_recyclerview_java", - "//third_party/androidx:androidx_vectordrawable_vectordrawable_animated_java", - "//ui/android:ui_full_java", - "//ui/android:ui_utils_java", - "//ui/base/mojom:mojom_java", - ] - - if (!is_java_debug) { - if (!defined(proguard_configs)) { - proguard_configs = [] - } - proguard_configs += [ "proguard.flags" ] - } - resources_package = "org.chromium.chrome.start_surface" -}
diff --git a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/BottomBarCoordinator.java b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/BottomBarCoordinator.java index ed058b3..adcae7b 100644 --- a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/BottomBarCoordinator.java +++ b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/BottomBarCoordinator.java
@@ -8,7 +8,7 @@ import android.view.LayoutInflater; import android.view.ViewGroup; -import org.chromium.chrome.start_surface.R; +import org.chromium.chrome.R; import org.chromium.ui.modelutil.PropertyModel; import org.chromium.ui.modelutil.PropertyModelChangeProcessor;
diff --git a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/BottomBarView.java b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/BottomBarView.java index 9e43f4fa..2ccead9 100644 --- a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/BottomBarView.java +++ b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/BottomBarView.java
@@ -12,7 +12,7 @@ import com.google.android.material.tabs.TabLayout; -import org.chromium.chrome.start_surface.R; +import org.chromium.chrome.R; import org.chromium.ui.widget.ChromeImageView; /** The bottom bar view. */
diff --git a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/ExploreSurfaceCoordinator.java b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/ExploreSurfaceCoordinator.java index afe791b..660baf4e 100644 --- a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/ExploreSurfaceCoordinator.java +++ b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/ExploreSurfaceCoordinator.java
@@ -14,6 +14,7 @@ import androidx.recyclerview.widget.RecyclerView; import org.chromium.base.supplier.Supplier; +import org.chromium.chrome.R; import org.chromium.chrome.browser.app.feed.FeedActionDelegateImpl; import org.chromium.chrome.browser.bookmarks.BookmarkBridge; import org.chromium.chrome.browser.feed.FeedSurfaceCoordinator; @@ -31,7 +32,6 @@ import org.chromium.chrome.browser.toolbar.top.Toolbar; import org.chromium.chrome.browser.ui.messages.snackbar.SnackbarManager; import org.chromium.chrome.browser.xsurface.FeedLaunchReliabilityLogger.SurfaceType; -import org.chromium.chrome.start_surface.R; import org.chromium.components.browser_ui.bottomsheet.BottomSheetController; import org.chromium.ui.base.WindowAndroid;
diff --git a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/FeedPlaceholderCoordinator.java b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/FeedPlaceholderCoordinator.java index a22f1bd..b3a78394 100644 --- a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/FeedPlaceholderCoordinator.java +++ b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/FeedPlaceholderCoordinator.java
@@ -13,8 +13,8 @@ import androidx.annotation.VisibleForTesting; +import org.chromium.chrome.R; import org.chromium.chrome.browser.feed.FeedPlaceholderLayout; -import org.chromium.chrome.start_surface.R; /** The coordinator to control the feed placeholder view. */ public class FeedPlaceholderCoordinator {
diff --git a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/StartSurfaceCoordinator.java b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/StartSurfaceCoordinator.java index b76850f..62f2dea 100644 --- a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/StartSurfaceCoordinator.java +++ b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/StartSurfaceCoordinator.java
@@ -26,6 +26,7 @@ import org.chromium.base.metrics.RecordHistogram; import org.chromium.base.supplier.OneshotSupplierImpl; import org.chromium.base.supplier.Supplier; +import org.chromium.chrome.R; import org.chromium.chrome.browser.browser_controls.BrowserControlsStateProvider; import org.chromium.chrome.browser.compositor.layouts.content.TabContentManager; import org.chromium.chrome.browser.feed.FeedSwipeRefreshLayout; @@ -51,7 +52,6 @@ import org.chromium.chrome.features.tasks.TasksSurface; import org.chromium.chrome.features.tasks.TasksSurfaceCoordinator; import org.chromium.chrome.features.tasks.TasksSurfaceProperties; -import org.chromium.chrome.start_surface.R; import org.chromium.components.browser_ui.bottomsheet.BottomSheetController; import org.chromium.components.browser_ui.widget.MenuOrKeyboardActionController; import org.chromium.components.browser_ui.widget.scrim.ScrimCoordinator;
diff --git a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/StartSurfaceDelegate.java b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/StartSurfaceDelegate.java index d0626af..4af1d8c 100644 --- a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/StartSurfaceDelegate.java +++ b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/StartSurfaceDelegate.java
@@ -37,6 +37,17 @@ /** StartSurfaceDelegate. */ public class StartSurfaceDelegate { + /** + * Create the {@link StartSurfaceLayout}. + * @param context The current Android's context. + * @param updateHost The parent {@link LayoutUpdateHost}. + * @param renderHost The parent {@link LayoutRenderHost}. + * @param startSurface The {@link StartSurface} the layout should own. + * @param startSurfaceScrimAnchor {@link ViewGroup} used by start surface layout to show scrim + * when overview is visible. + * @param scrimCoordinator {@link ScrimCoordinator} to show/hide scrim. + * @return The {@link StartSurfaceLayout}. + */ public static Layout createStartSurfaceLayout(Context context, LayoutUpdateHost updateHost, LayoutRenderHost renderHost, StartSurface startSurface, JankTracker jankTracker, ViewGroup startSurfaceScrimAnchor, ScrimCoordinator scrimCoordinator) { @@ -44,7 +55,37 @@ startSurfaceScrimAnchor, scrimCoordinator); } - /** {@see StartSurfaceCoordinator} */ + /** + * Create the {@link StartSurfaceCoordinator} + * @param activity The {@link Activity} creates this {@link StartSurface}. + * @param scrimCoordinator The {@link ScrimCoordinator} to control the scrim view. + * @param sheetController A {@link BottomSheetController} to show content in the bottom sheet. + * @param startSurfaceOneshotSupplier Supplies the {@link StartSurface}, passing the owned + * supplier to StartSurface itself. + * @param parentTabSupplier A {@link Supplier} to provide parent tab for + * StartSurface. + * @param hadWarmStart Whether the activity had a warm start because the native library was + * already fully loaded and initialized + * @param windowAndroid An instance of a {@link WindowAndroid} + * @param containerView The container {@link ViewGroup} for this ui, also the root view for + * StartSurface. + * @param dynamicResourceLoaderSupplier Supplies the current {@link DynamicResourceLoader}. + * @param tabModelSelector Gives access to the current set of {@TabModel}. + * @param browserControlsManager Manages the browser controls. + * @param snackbarManager Manages the display of snackbars. + * @param shareDelegateSupplier Supplies the current {@link ShareDelegate}. + * @param omniboxStubSupplier Supplies the {@link OmniboxStub}. + * @param tabContentManager Gives access to the tab content. + * @param modalDialogManager Manages the display of modal dialogs. + * @param chromeActivityNativeDelegate Delegate for native initialization. + * @param activityLifecycleDispatcher Allows observation of the activity lifecycle. + * @param tabCreatorManager Manages creation of tabs. + * @param menuOrKeyboardActionController allows access to menu or keyboard actions. + * @param multiWindowModeStateDispatcher Gives access to the multi window mode state. + * @param jankTracker Measures jank while tab switcher is visible. + * @param toolbarSupplier Supplies the {@link Toolbar}. + * @return the {@link StartSurface} + */ public static StartSurface createStartSurface(@NonNull Activity activity, @NonNull ScrimCoordinator scrimCoordinator, @NonNull BottomSheetController sheetController,
diff --git a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/StartSurfaceMediator.java b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/StartSurfaceMediator.java index 7997ee7..394a36b3 100644 --- a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/StartSurfaceMediator.java +++ b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/StartSurfaceMediator.java
@@ -44,6 +44,7 @@ import org.chromium.base.metrics.RecordHistogram; import org.chromium.base.metrics.RecordUserAction; import org.chromium.base.supplier.OneshotSupplier; +import org.chromium.chrome.R; import org.chromium.chrome.browser.browser_controls.BrowserControlsStateProvider; import org.chromium.chrome.browser.flags.CachedFeatureFlags; import org.chromium.chrome.browser.flags.ChromeFeatureList; @@ -66,7 +67,6 @@ import org.chromium.chrome.browser.tasks.tab_management.TabManagementDelegate.TabSwitcherType; import org.chromium.chrome.browser.tasks.tab_management.TabSwitcher; import org.chromium.chrome.browser.ui.messages.snackbar.SnackbarManager; -import org.chromium.chrome.start_surface.R; import org.chromium.components.embedder_support.util.UrlUtilities; import org.chromium.components.prefs.PrefService; import org.chromium.content_public.browser.BrowserStartupController;
diff --git a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/SingleTabSwitcherCoordinator.java b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/SingleTabSwitcherCoordinator.java index 29d483b..a58beb8 100644 --- a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/SingleTabSwitcherCoordinator.java +++ b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/SingleTabSwitcherCoordinator.java
@@ -16,6 +16,7 @@ import org.chromium.base.Callback; import org.chromium.base.supplier.Supplier; +import org.chromium.chrome.R; import org.chromium.chrome.browser.compositor.layouts.content.TabContentManager; import org.chromium.chrome.browser.flags.CachedFeatureFlags; import org.chromium.chrome.browser.flags.ChromeFeatureList; @@ -25,7 +26,6 @@ import org.chromium.chrome.browser.tasks.tab_management.TabListFaviconProvider; import org.chromium.chrome.browser.tasks.tab_management.TabSwitcher; import org.chromium.chrome.browser.ui.messages.snackbar.SnackbarManager; -import org.chromium.chrome.start_surface.R; import org.chromium.ui.modaldialog.ModalDialogManager; import org.chromium.ui.modelutil.PropertyModel; import org.chromium.ui.modelutil.PropertyModelChangeProcessor;
diff --git a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/SingleTabView.java b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/SingleTabView.java index 0c794405..0c7d93d 100644 --- a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/SingleTabView.java +++ b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/SingleTabView.java
@@ -11,7 +11,7 @@ import android.widget.LinearLayout; import android.widget.TextView; -import org.chromium.chrome.start_surface.R; +import org.chromium.chrome.R; /** View of the tab on the single tab tab switcher. */ class SingleTabView extends LinearLayout {
diff --git a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/TasksSurfaceCoordinator.java b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/TasksSurfaceCoordinator.java index 9d13fa4..58696a7 100644 --- a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/TasksSurfaceCoordinator.java +++ b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/TasksSurfaceCoordinator.java
@@ -18,6 +18,7 @@ import org.chromium.base.library_loader.LibraryLoader; import org.chromium.base.supplier.Supplier; +import org.chromium.chrome.R; import org.chromium.chrome.browser.browser_controls.BrowserControlsStateProvider; import org.chromium.chrome.browser.compositor.layouts.content.TabContentManager; import org.chromium.chrome.browser.feedback.HelpAndFeedbackLauncherImpl; @@ -42,7 +43,6 @@ import org.chromium.chrome.browser.tasks.tab_management.TabSwitcher; import org.chromium.chrome.browser.tasks.tab_management.TabUiFeatureUtilities; import org.chromium.chrome.browser.ui.messages.snackbar.SnackbarManager; -import org.chromium.chrome.start_surface.R; import org.chromium.components.browser_ui.widget.MenuOrKeyboardActionController; import org.chromium.components.browser_ui.widget.scrim.ScrimCoordinator; import org.chromium.ui.base.DeviceFormFactor;
diff --git a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/TasksView.java b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/TasksView.java index a4ef52a1..579b0a1 100644 --- a/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/TasksView.java +++ b/chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/TasksView.java
@@ -29,13 +29,13 @@ import org.chromium.base.ApiCompatibilityUtils; import org.chromium.base.FeatureList; +import org.chromium.chrome.R; import org.chromium.chrome.browser.feed.FeedStreamViewResizer; import org.chromium.chrome.browser.feed.FeedSurfaceCoordinator; import org.chromium.chrome.browser.flags.ChromeFeatureList; import org.chromium.chrome.browser.lifecycle.ActivityLifecycleDispatcher; import org.chromium.chrome.browser.ntp.IncognitoDescriptionView; import org.chromium.chrome.browser.ntp.search.SearchBoxCoordinator; -import org.chromium.chrome.start_surface.R; import org.chromium.components.browser_ui.styles.ChromeColors; import org.chromium.components.browser_ui.widget.CoordinatorLayoutForPointer; import org.chromium.components.browser_ui.widget.displaystyle.UiConfig;
diff --git a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/BottomBarViewBinderTest.java b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/BottomBarViewBinderTest.java index 3a2d671..792cd89c 100644 --- a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/BottomBarViewBinderTest.java +++ b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/BottomBarViewBinderTest.java
@@ -26,7 +26,7 @@ import org.junit.runner.RunWith; import org.chromium.base.test.UiThreadTest; -import org.chromium.chrome.start_surface.R; +import org.chromium.chrome.R; import org.chromium.chrome.test.ChromeJUnit4ClassRunner; import org.chromium.content_public.browser.test.util.TestThreadUtils; import org.chromium.ui.modelutil.PropertyModel;
diff --git a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/InstantStartNewTabFromLauncherTest.java b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/InstantStartNewTabFromLauncherTest.java index 210e6858..d2403ed 100644 --- a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/InstantStartNewTabFromLauncherTest.java +++ b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/InstantStartNewTabFromLauncherTest.java
@@ -30,6 +30,7 @@ import org.chromium.base.test.util.CriteriaHelper; import org.chromium.base.test.util.DisabledTest; import org.chromium.base.test.util.Restriction; +import org.chromium.chrome.R; import org.chromium.chrome.browser.ChromeTabbedActivity; import org.chromium.chrome.browser.IntentHandler; import org.chromium.chrome.browser.flags.CachedFeatureFlags; @@ -156,18 +157,16 @@ StartSurfaceTestUtils.waitForTabModel(cta); TabUiTestHelper.verifyTabModelTabCount(cta, 2, 0); - waitForView(withId(org.chromium.chrome.start_surface.R.id.search_box_text)); - TextView urlBar = cta.findViewById(org.chromium.chrome.start_surface.R.id.url_bar); + waitForView(withId(R.id.search_box_text)); + TextView urlBar = cta.findViewById(R.id.url_bar); CriteriaHelper.pollUiThread( () -> StartSurfaceTestUtils.isKeyboardShown(mActivityTestRule) && urlBar.isFocused(), MAX_TIMEOUT_MS, CriteriaHelper.DEFAULT_POLLING_INTERVAL); - waitForView(withId(org.chromium.chrome.start_surface.R.id.voice_search_button)); + waitForView(withId(R.id.voice_search_button)); Assert.assertTrue(TextUtils.isEmpty(urlBar.getText())); - assertEquals(cta.findViewById(org.chromium.chrome.start_surface.R.id.toolbar_buttons) - .getVisibility(), - View.INVISIBLE); + assertEquals(cta.findViewById(R.id.toolbar_buttons).getVisibility(), View.INVISIBLE); ToolbarDataProvider toolbarDataProvider = cta.getToolbarManager().getLocationBarModelForTesting(); TestThreadUtils.runOnUiThreadBlocking(() -> {
diff --git a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/InstantStartTabSwitcherTest.java b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/InstantStartTabSwitcherTest.java index 316e9ae2..6b66a6640f 100644 --- a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/InstantStartTabSwitcherTest.java +++ b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/InstantStartTabSwitcherTest.java
@@ -59,6 +59,7 @@ import org.chromium.base.test.util.DisabledTest; import org.chromium.base.test.util.Feature; import org.chromium.base.test.util.Restriction; +import org.chromium.chrome.R; import org.chromium.chrome.browser.ChromeTabbedActivity; import org.chromium.chrome.browser.feed.FeedPlaceholderLayout; import org.chromium.chrome.browser.flags.CachedFeatureFlags; @@ -415,9 +416,7 @@ // Initializes native. StartSurfaceTestUtils.startAndWaitNativeInitialization(mActivityTestRule); - onViewWaiting( - allOf(withId(org.chromium.chrome.start_surface.R.id.feed_stream_recycler_view), - isDisplayed())); + onViewWaiting(allOf(withId(R.id.feed_stream_recycler_view), isDisplayed())); // Rotate to landscape mode. ActivityTestUtils.rotateActivityToOrientation(cta, ORIENTATION_LANDSCAPE); @@ -526,11 +525,10 @@ StartSurfaceTestUtils.waitForDeferredStartup(mActivityTestRule); // Create a new search result tab by perform a query search in fake box. - onViewWaiting(withId(org.chromium.chrome.start_surface.R.id.search_box_text)) + onViewWaiting(withId(R.id.search_box_text)) .check(matches(isCompletelyDisplayed())) .perform(replaceText("test")); - onView(withId(org.chromium.chrome.start_surface.R.id.url_bar)) - .perform(pressKey(KeyEvent.KEYCODE_ENTER)); + onView(withId(R.id.url_bar)).perform(pressKey(KeyEvent.KEYCODE_ENTER)); TabUiTestHelper.verifyTabModelTabCount(cta, 1, 0); StartSurfaceTestUtils.pressHome();
diff --git a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/InstantStartTest.java b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/InstantStartTest.java index da8aedca..3cdcfc0 100644 --- a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/InstantStartTest.java +++ b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/InstantStartTest.java
@@ -428,9 +428,7 @@ // Initializes native. StartSurfaceTestUtils.startAndWaitNativeInitialization(mActivityTestRule); - onViewWaiting( - allOf(withId(org.chromium.chrome.start_surface.R.id.feed_stream_recycler_view), - isDisplayed())); + onViewWaiting(allOf(withId(R.id.feed_stream_recycler_view), isDisplayed())); cta.setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_LANDSCAPE); CriteriaHelper.pollUiThread(() -> {
diff --git a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceBackButtonTest.java b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceBackButtonTest.java index 43c5c1c1..4a6ee290 100644 --- a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceBackButtonTest.java +++ b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceBackButtonTest.java
@@ -51,6 +51,7 @@ import org.chromium.base.test.util.DisabledTest; import org.chromium.base.test.util.Feature; import org.chromium.base.test.util.Restriction; +import org.chromium.chrome.R; import org.chromium.chrome.browser.ChromeTabbedActivity; import org.chromium.chrome.browser.flags.CachedFeatureFlags; import org.chromium.chrome.browser.flags.ChromeFeatureList; @@ -65,7 +66,6 @@ import org.chromium.chrome.browser.tabmodel.TabModel; import org.chromium.chrome.browser.tasks.tab_management.TabSelectionEditorTestingRobot; import org.chromium.chrome.browser.tasks.tab_management.TabUiTestHelper; -import org.chromium.chrome.start_surface.R; import org.chromium.chrome.test.ChromeJUnit4RunnerDelegate; import org.chromium.chrome.test.ChromeTabbedActivityTestRule; import org.chromium.chrome.test.util.ChromeApplicationTestUtils;
diff --git a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceFinaleTest.java b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceFinaleTest.java index d17edb2..c25ed11 100644 --- a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceFinaleTest.java +++ b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceFinaleTest.java
@@ -48,6 +48,7 @@ import org.chromium.base.test.util.CriteriaHelper; import org.chromium.base.test.util.Feature; import org.chromium.base.test.util.Restriction; +import org.chromium.chrome.R; import org.chromium.chrome.browser.ChromeTabbedActivity; import org.chromium.chrome.browser.flags.CachedFeatureFlags; import org.chromium.chrome.browser.flags.ChromeFeatureList; @@ -59,7 +60,6 @@ import org.chromium.chrome.browser.tab.TabLaunchType; import org.chromium.chrome.browser.tasks.tab_management.TabUiTestHelper; import org.chromium.chrome.browser.toolbar.ToolbarDataProvider; -import org.chromium.chrome.start_surface.R; import org.chromium.chrome.test.ChromeJUnit4RunnerDelegate; import org.chromium.chrome.test.ChromeTabbedActivityTestRule; import org.chromium.chrome.test.util.browser.Features.EnableFeatures;
diff --git a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceMVTilesTest.java b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceMVTilesTest.java index af4aaf4..41a898b1 100644 --- a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceMVTilesTest.java +++ b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceMVTilesTest.java
@@ -40,6 +40,7 @@ import org.chromium.base.test.util.CriteriaHelper; import org.chromium.base.test.util.Feature; import org.chromium.base.test.util.Restriction; +import org.chromium.chrome.R; import org.chromium.chrome.browser.ChromeTabbedActivity; import org.chromium.chrome.browser.feed.FeedPlaceholderLayout; import org.chromium.chrome.browser.flags.CachedFeatureFlags; @@ -219,7 +220,7 @@ }); TestThreadUtils.runOnUiThreadBlocking(() -> cta.getTabCreator(false).launchNTP()); - onViewWaiting(withId(org.chromium.chrome.start_surface.R.id.primary_tasks_surface_view)); + onViewWaiting(withId(R.id.primary_tasks_surface_view)); TestThreadUtils.runOnUiThreadBlocking(() -> { Assert.assertTrue(startSurfaceCoordinator.isMVTilesInitializedForTesting()); }); @@ -376,18 +377,17 @@ /** Wait for the snackbar associated to a tile dismissal to be shown and returns its button. */ private View waitForSnackbar() { ChromeTabbedActivity cta = mActivityTestRule.getActivity(); - final String expectedSnackbarMessage = cta.getResources().getString( - org.chromium.chrome.start_surface.R.string.most_visited_item_removed); + final String expectedSnackbarMessage = + cta.getResources().getString(R.string.most_visited_item_removed); CriteriaHelper.pollUiThread(() -> { SnackbarManager snackbarManager = cta.getSnackbarManager(); Criteria.checkThat(snackbarManager.isShowing(), Matchers.is(true)); - TextView snackbarMessage = - cta.findViewById(org.chromium.chrome.start_surface.R.id.snackbar_message); + TextView snackbarMessage = cta.findViewById(R.id.snackbar_message); Criteria.checkThat(snackbarMessage, Matchers.notNullValue()); Criteria.checkThat( snackbarMessage.getText().toString(), Matchers.is(expectedSnackbarMessage)); }); - return cta.findViewById(org.chromium.chrome.start_surface.R.id.snackbar_button); + return cta.findViewById(R.id.snackbar_button); } }
diff --git a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceNoTabsTest.java b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceNoTabsTest.java index 77cf9a1..179c3747e 100644 --- a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceNoTabsTest.java +++ b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceNoTabsTest.java
@@ -42,12 +42,12 @@ import org.chromium.base.test.util.DisabledTest; import org.chromium.base.test.util.Feature; import org.chromium.base.test.util.Restriction; +import org.chromium.chrome.R; import org.chromium.chrome.browser.flags.CachedFeatureFlags; import org.chromium.chrome.browser.flags.ChromeFeatureList; import org.chromium.chrome.browser.flags.ChromeSwitches; import org.chromium.chrome.browser.layouts.LayoutType; import org.chromium.chrome.browser.tasks.ReturnToChromeUtil; -import org.chromium.chrome.start_surface.R; import org.chromium.chrome.test.ChromeActivityTestRule; import org.chromium.chrome.test.ChromeJUnit4RunnerDelegate; import org.chromium.chrome.test.ChromeTabbedActivityTestRule;
diff --git a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceTabSwitcherTest.java b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceTabSwitcherTest.java index 5d0e2164..ffca39e6 100644 --- a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceTabSwitcherTest.java +++ b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceTabSwitcherTest.java
@@ -51,6 +51,7 @@ import org.chromium.base.test.util.Feature; import org.chromium.base.test.util.FlakyTest; import org.chromium.base.test.util.Restriction; +import org.chromium.chrome.R; import org.chromium.chrome.browser.ChromeTabbedActivity; import org.chromium.chrome.browser.flags.CachedFeatureFlags; import org.chromium.chrome.browser.flags.ChromeFeatureList; @@ -63,7 +64,6 @@ import org.chromium.chrome.browser.tasks.tab_groups.TabGroupModelFilter; import org.chromium.chrome.browser.tasks.tab_management.TabUiTestHelper; import org.chromium.chrome.browser.toolbar.HomeButton; -import org.chromium.chrome.start_surface.R; import org.chromium.chrome.test.ChromeJUnit4RunnerDelegate; import org.chromium.chrome.test.ChromeTabbedActivityTestRule; import org.chromium.chrome.test.util.browser.Features.EnableFeatures;
diff --git a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceTest.java b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceTest.java index 3a456c3..2864029 100644 --- a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceTest.java +++ b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceTest.java
@@ -73,6 +73,7 @@ import org.chromium.base.test.util.Feature; import org.chromium.base.test.util.FlakyTest; import org.chromium.base.test.util.Restriction; +import org.chromium.chrome.R; import org.chromium.chrome.browser.ChromeTabbedActivity; import org.chromium.chrome.browser.feed.FeedPlaceholderLayout; import org.chromium.chrome.browser.flags.CachedFeatureFlags; @@ -91,7 +92,6 @@ import org.chromium.chrome.browser.tasks.tab_management.TabUiTestHelper; import org.chromium.chrome.browser.ui.appmenu.AppMenuTestSupport; import org.chromium.chrome.features.tasks.SingleTabSwitcherMediator; -import org.chromium.chrome.start_surface.R; import org.chromium.chrome.test.ChromeJUnit4RunnerDelegate; import org.chromium.chrome.test.ChromeTabbedActivityTestRule; import org.chromium.chrome.test.util.ChromeTabUtils;
diff --git a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceTestUtils.java b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceTestUtils.java index 7e9c075..f93665a 100644 --- a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceTestUtils.java +++ b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/StartSurfaceTestUtils.java
@@ -48,6 +48,7 @@ import org.chromium.base.test.params.ParameterSet; import org.chromium.base.test.util.CallbackHelper; import org.chromium.base.test.util.CriteriaHelper; +import org.chromium.chrome.R; import org.chromium.chrome.browser.ChromeTabbedActivity; import org.chromium.chrome.browser.compositor.layouts.content.TabContentManager; import org.chromium.chrome.browser.flags.ChromeFeatureList; @@ -70,7 +71,6 @@ import org.chromium.chrome.browser.tasks.pseudotab.TabAttributeCache; import org.chromium.chrome.browser.tasks.tab_management.TabUiTestHelper; import org.chromium.chrome.browser.toolbar.top.ToolbarPhone; -import org.chromium.chrome.start_surface.R; import org.chromium.chrome.test.ChromeActivityTestRule; import org.chromium.chrome.test.ChromeTabbedActivityTestRule; import org.chromium.chrome.test.util.ChromeApplicationTestUtils;
diff --git a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/ViewIds.java b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/ViewIds.java index fa3d679..3cf13c9b 100644 --- a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/ViewIds.java +++ b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/start_surface/ViewIds.java
@@ -4,7 +4,7 @@ package org.chromium.chrome.features.start_surface; -import org.chromium.chrome.start_surface.R; +import org.chromium.chrome.R; /** * This class allows external tests to use these view IDs without depending directly on the internal
diff --git a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/tasks/SingleTabViewBinderTest.java b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/tasks/SingleTabViewBinderTest.java index 2657991..aae8cb7 100644 --- a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/tasks/SingleTabViewBinderTest.java +++ b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/tasks/SingleTabViewBinderTest.java
@@ -30,7 +30,7 @@ import org.mockito.MockitoAnnotations; import org.chromium.base.test.UiThreadTest; -import org.chromium.chrome.start_surface.R; +import org.chromium.chrome.R; import org.chromium.chrome.test.ChromeJUnit4ClassRunner; import org.chromium.content_public.browser.test.util.TestThreadUtils; import org.chromium.ui.modelutil.PropertyModel;
diff --git a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/tasks/TasksViewBinderTest.java b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/tasks/TasksViewBinderTest.java index 98b91fc..119a0fc1 100644 --- a/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/tasks/TasksViewBinderTest.java +++ b/chrome/android/features/start_surface/internal/javatests/src/org/chromium/chrome/features/tasks/TasksViewBinderTest.java
@@ -50,8 +50,8 @@ import org.chromium.base.test.UiThreadTest; import org.chromium.base.test.util.DisabledTest; +import org.chromium.chrome.R; import org.chromium.chrome.browser.ntp.IncognitoCookieControlsManager; -import org.chromium.chrome.start_surface.R; import org.chromium.chrome.test.ChromeJUnit4ClassRunner; import org.chromium.components.browser_ui.styles.ChromeColors; import org.chromium.content_public.browser.test.util.TestThreadUtils;
diff --git a/chrome/android/features/start_surface/internal/junit/src/org/chromium/chrome/features/start_surface/StartSurfaceMediatorUnitTest.java b/chrome/android/features/start_surface/internal/junit/src/org/chromium/chrome/features/start_surface/StartSurfaceMediatorUnitTest.java index db3d67e..cce8029 100644 --- a/chrome/android/features/start_surface/internal/junit/src/org/chromium/chrome/features/start_surface/StartSurfaceMediatorUnitTest.java +++ b/chrome/android/features/start_surface/internal/junit/src/org/chromium/chrome/features/start_surface/StartSurfaceMediatorUnitTest.java
@@ -63,6 +63,7 @@ import org.chromium.base.jank_tracker.DummyJankTracker; import org.chromium.base.supplier.OneshotSupplier; import org.chromium.base.test.BaseRobolectricTestRunner; +import org.chromium.chrome.R; import org.chromium.chrome.browser.browser_controls.BrowserControlsStateProvider; import org.chromium.chrome.browser.night_mode.NightModeStateProvider; import org.chromium.chrome.browser.ntp.NewTabPageLaunchOrigin; @@ -83,7 +84,6 @@ import org.chromium.chrome.browser.tasks.tab_management.TabSwitcher.OverviewModeObserver; import org.chromium.chrome.features.start_surface.StartSurfaceMediator.SecondaryTasksSurfaceInitializer; import org.chromium.chrome.features.tasks.TasksSurfaceProperties; -import org.chromium.chrome.start_surface.R; import org.chromium.chrome.test.util.browser.Features; import org.chromium.components.prefs.PrefService; import org.chromium.ui.modelutil.PropertyKey;
diff --git a/chrome/android/features/start_surface/public/start_surface_public_java_sources.gni b/chrome/android/features/start_surface/public/start_surface_public_java_sources.gni index 905c8113..c84126f88 100644 --- a/chrome/android/features/start_surface/public/start_surface_public_java_sources.gni +++ b/chrome/android/features/start_surface/public/start_surface_public_java_sources.gni
@@ -4,6 +4,34 @@ # TODO: Move this to the target public_java too. start_surface_public_java_sources = [ + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/BackgroundTabAnimation.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/BottomBarCoordinator.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/BottomBarView.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/BottomBarViewBinder.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/ExploreSurfaceCoordinator.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/ExploreSurfaceCoordinatorFactory.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/ExploreSurfaceFeedLifecycleManager.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/ExploreSurfaceNavigationDelegate.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/ExploreSurfaceViewBinder.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/FeedPlaceholderCoordinator.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/ReturnToStartSurfaceUtil.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/SecondaryTasksSurfaceViewBinder.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/StartSurfaceCoordinator.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/StartSurfaceDelegate.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/StartSurfaceLayout.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/StartSurfaceMediator.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/StartSurfaceProperties.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/start_surface/TasksSurfaceViewBinder.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/SingleTabSwitcherCoordinator.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/SingleTabSwitcherMediator.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/SingleTabView.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/SingleTabViewBinder.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/SingleTabViewProperties.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/TasksSurfaceCoordinator.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/TasksSurfaceMediator.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/TasksSurfaceProperties.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/TasksView.java", + "//chrome/android/features/start_surface/internal/java/src/org/chromium/chrome/features/tasks/TasksViewBinder.java", "//chrome/android/features/start_surface/public/java/src/org/chromium/chrome/features/start_surface/StartSurface.java", "//chrome/android/features/start_surface/public/java/src/org/chromium/chrome/features/tasks/TasksSurface.java", ]
diff --git a/chrome/android/features/tab_ui/BUILD.gn b/chrome/android/features/tab_ui/BUILD.gn index bf49c0b..8026615 100644 --- a/chrome/android/features/tab_ui/BUILD.gn +++ b/chrome/android/features/tab_ui/BUILD.gn
@@ -176,7 +176,6 @@ "//chrome/android:chrome_java", "//chrome/android:ui_locale_string_resources", "//chrome/android/features/start_surface:public_java", - "//chrome/android/features/start_surface/internal:java", "//chrome/app:java_strings_grd", "//chrome/browser/android/lifecycle:java", "//chrome/browser/browser_controls/android:java",
diff --git a/chrome/android/features/tab_ui/java/src/org/chromium/chrome/browser/tasks/tab_management/TabManagementDelegate.java b/chrome/android/features/tab_ui/java/src/org/chromium/chrome/browser/tasks/tab_management/TabManagementDelegate.java index 8bb419bf..d9dd2f0 100644 --- a/chrome/android/features/tab_ui/java/src/org/chromium/chrome/browser/tasks/tab_management/TabManagementDelegate.java +++ b/chrome/android/features/tab_ui/java/src/org/chromium/chrome/browser/tasks/tab_management/TabManagementDelegate.java
@@ -11,39 +11,26 @@ import androidx.annotation.IntDef; import androidx.annotation.NonNull; -import org.chromium.base.jank_tracker.JankTracker; import org.chromium.base.supplier.ObservableSupplier; import org.chromium.base.supplier.OneshotSupplier; -import org.chromium.base.supplier.OneshotSupplierImpl; import org.chromium.base.supplier.Supplier; import org.chromium.chrome.browser.browser_controls.BrowserControlsStateProvider; -import org.chromium.chrome.browser.compositor.layouts.Layout; -import org.chromium.chrome.browser.compositor.layouts.LayoutRenderHost; -import org.chromium.chrome.browser.compositor.layouts.LayoutUpdateHost; import org.chromium.chrome.browser.compositor.layouts.content.TabContentManager; -import org.chromium.chrome.browser.fullscreen.BrowserControlsManager; -import org.chromium.chrome.browser.init.ChromeActivityNativeDelegate; import org.chromium.chrome.browser.layouts.LayoutStateProvider; import org.chromium.chrome.browser.lifecycle.ActivityLifecycleDispatcher; import org.chromium.chrome.browser.multiwindow.MultiWindowModeStateDispatcher; -import org.chromium.chrome.browser.omnibox.OmniboxStub; import org.chromium.chrome.browser.share.ShareDelegate; -import org.chromium.chrome.browser.tab.Tab; import org.chromium.chrome.browser.tabmodel.IncognitoStateProvider; import org.chromium.chrome.browser.tabmodel.TabCreatorManager; import org.chromium.chrome.browser.tabmodel.TabModel; import org.chromium.chrome.browser.tabmodel.TabModelSelector; import org.chromium.chrome.browser.tasks.tab_groups.TabGroupModelFilter; import org.chromium.chrome.browser.tasks.tab_management.suggestions.TabSuggestions; -import org.chromium.chrome.browser.toolbar.top.Toolbar; import org.chromium.chrome.browser.ui.messages.snackbar.SnackbarManager; -import org.chromium.chrome.features.start_surface.StartSurface; import org.chromium.components.browser_ui.bottomsheet.BottomSheetController; import org.chromium.components.browser_ui.widget.MenuOrKeyboardActionController; import org.chromium.components.browser_ui.widget.scrim.ScrimCoordinator; import org.chromium.components.module_installer.builder.ModuleInterface; -import org.chromium.ui.base.WindowAndroid; -import org.chromium.ui.modaldialog.ModalDialogManager; import org.chromium.ui.resources.dynamics.DynamicResourceLoader; import java.lang.annotation.Retention; @@ -158,73 +145,6 @@ @NonNull SnackbarManager snackbarManager); /** - * Create the {@link StartSurfaceLayout}. - * @param context The current Android's context. - * @param updateHost The parent {@link LayoutUpdateHost}. - * @param renderHost The parent {@link LayoutRenderHost}. - * @param startSurface The {@link StartSurface} the layout should own. - * @param startSurfaceScrimAnchor {@link ViewGroup} used by start surface layout to show scrim - * when overview is visible. - * @param scrimCoordinator {@link ScrimCoordinator} to show/hide scrim. - * @return The {@link StartSurfaceLayout}. - */ - Layout createStartSurfaceLayout(Context context, LayoutUpdateHost updateHost, - LayoutRenderHost renderHost, StartSurface startSurface, JankTracker jankTracker, - ViewGroup startSurfaceScrimAnchor, ScrimCoordinator scrimCoordinator); - - /** - * Create the {@link StartSurface} - * @param activity The {@link Activity} creates this {@link StartSurface}. - * @param scrimCoordinator The {@link ScrimCoordinator} to control the scrim view. - * @param sheetController A {@link BottomSheetController} to show content in the bottom sheet. - * @param startSurfaceOneshotSupplier Supplies the {@link StartSurface}, passing the owned - * supplier to StartSurface itself. - * @param parentTabSupplier A {@link Supplier} to provide parent tab for - * StartSurface. - * @param hadWarmStart Whether the activity had a warm start because the native library was - * already fully loaded and initialized - * @param windowAndroid An instance of a {@link WindowAndroid} - * @param containerView The container {@link ViewGroup} for this ui, also the root view for - * StartSurface. - * @param dynamicResourceLoaderSupplier Supplies the current {@link DynamicResourceLoader}. - * @param tabModelSelector Gives access to the current set of {@TabModel}. - * @param browserControlsManager Manages the browser controls. - * @param snackbarManager Manages the display of snackbars. - * @param shareDelegateSupplier Supplies the current {@link ShareDelegate}. - * @param omniboxStubSupplier Supplies the {@link OmniboxStub}. - * @param tabContentManager Gives access to the tab content. - * @param modalDialogManager Manages the display of modal dialogs. - * @param chromeActivityNativeDelegate Delegate for native initialization. - * @param activityLifecycleDispatcher Allows observation of the activity lifecycle. - * @param tabCreatorManager Manages creation of tabs. - * @param menuOrKeyboardActionController allows access to menu or keyboard actions. - * @param multiWindowModeStateDispatcher Gives access to the multi window mode state. - * @param jankTracker Measures jank while tab switcher is visible. - * @param toolbarSupplier Supplies the {@link Toolbar}. - * @return the {@link StartSurface} - */ - StartSurface createStartSurface(@NonNull Activity activity, - @NonNull ScrimCoordinator scrimCoordinator, - @NonNull BottomSheetController sheetController, - @NonNull OneshotSupplierImpl<StartSurface> startSurfaceOneshotSupplier, - @NonNull Supplier<Tab> parentTabSupplier, boolean hadWarmStart, - @NonNull WindowAndroid windowAndroid, @NonNull ViewGroup containerView, - @NonNull Supplier<DynamicResourceLoader> dynamicResourceLoaderSupplier, - @NonNull TabModelSelector tabModelSelector, - @NonNull BrowserControlsManager browserControlsManager, - @NonNull SnackbarManager snackbarManager, - @NonNull Supplier<ShareDelegate> shareDelegateSupplier, - @NonNull Supplier<OmniboxStub> omniboxStubSupplier, - @NonNull TabContentManager tabContentManager, - @NonNull ModalDialogManager modalDialogManager, - @NonNull ChromeActivityNativeDelegate chromeActivityNativeDelegate, - @NonNull ActivityLifecycleDispatcher activityLifecycleDispatcher, - @NonNull TabCreatorManager tabCreatorManager, - @NonNull MenuOrKeyboardActionController menuOrKeyboardActionController, - @NonNull MultiWindowModeStateDispatcher multiWindowModeStateDispatcher, - @NonNull JankTracker jankTracker, @NonNull Supplier<Toolbar> toolbarSupplier); - - /** * Create a {@link TabGroupModelFilter} for the given {@link TabModel}. * @return The {@link TabGroupModelFilter}. */
diff --git a/chrome/android/features/tab_ui/java/src/org/chromium/chrome/browser/tasks/tab_management/TabManagementDelegateImpl.java b/chrome/android/features/tab_ui/java/src/org/chromium/chrome/browser/tasks/tab_management/TabManagementDelegateImpl.java index 4cc15c32..17cdfe28 100644 --- a/chrome/android/features/tab_ui/java/src/org/chromium/chrome/browser/tasks/tab_management/TabManagementDelegateImpl.java +++ b/chrome/android/features/tab_ui/java/src/org/chromium/chrome/browser/tasks/tab_management/TabManagementDelegateImpl.java
@@ -13,26 +13,17 @@ import androidx.annotation.NonNull; import org.chromium.base.SysUtils; -import org.chromium.base.jank_tracker.JankTracker; import org.chromium.base.supplier.ObservableSupplier; import org.chromium.base.supplier.OneshotSupplier; -import org.chromium.base.supplier.OneshotSupplierImpl; import org.chromium.base.supplier.Supplier; import org.chromium.chrome.browser.browser_controls.BrowserControlsStateProvider; -import org.chromium.chrome.browser.compositor.layouts.Layout; -import org.chromium.chrome.browser.compositor.layouts.LayoutRenderHost; -import org.chromium.chrome.browser.compositor.layouts.LayoutUpdateHost; import org.chromium.chrome.browser.compositor.layouts.content.TabContentManager; import org.chromium.chrome.browser.flags.ChromeFeatureList; -import org.chromium.chrome.browser.fullscreen.BrowserControlsManager; -import org.chromium.chrome.browser.init.ChromeActivityNativeDelegate; import org.chromium.chrome.browser.layouts.LayoutStateProvider; import org.chromium.chrome.browser.lifecycle.ActivityLifecycleDispatcher; import org.chromium.chrome.browser.metrics.UmaSessionStats; import org.chromium.chrome.browser.multiwindow.MultiWindowModeStateDispatcher; -import org.chromium.chrome.browser.omnibox.OmniboxStub; import org.chromium.chrome.browser.share.ShareDelegate; -import org.chromium.chrome.browser.tab.Tab; import org.chromium.chrome.browser.tabmodel.IncognitoStateProvider; import org.chromium.chrome.browser.tabmodel.TabCreatorManager; import org.chromium.chrome.browser.tabmodel.TabModel; @@ -40,15 +31,10 @@ import org.chromium.chrome.browser.tasks.tab_groups.TabGroupModelFilter; import org.chromium.chrome.browser.tasks.tab_management.suggestions.TabSuggestions; import org.chromium.chrome.browser.tasks.tab_management.suggestions.TabSuggestionsOrchestrator; -import org.chromium.chrome.browser.toolbar.top.Toolbar; import org.chromium.chrome.browser.ui.messages.snackbar.SnackbarManager; -import org.chromium.chrome.features.start_surface.StartSurface; -import org.chromium.chrome.features.start_surface.StartSurfaceDelegate; import org.chromium.components.browser_ui.bottomsheet.BottomSheetController; import org.chromium.components.browser_ui.widget.MenuOrKeyboardActionController; import org.chromium.components.browser_ui.widget.scrim.ScrimCoordinator; -import org.chromium.ui.base.WindowAndroid; -import org.chromium.ui.modaldialog.ModalDialogManager; import org.chromium.ui.resources.dynamics.DynamicResourceLoader; /** @@ -125,44 +111,6 @@ } @Override - public Layout createStartSurfaceLayout(Context context, LayoutUpdateHost updateHost, - LayoutRenderHost renderHost, StartSurface startSurface, JankTracker jankTracker, - ViewGroup startSurfaceScrimAnchor, ScrimCoordinator scrimCoordinator) { - return StartSurfaceDelegate.createStartSurfaceLayout(context, updateHost, renderHost, - startSurface, jankTracker, startSurfaceScrimAnchor, scrimCoordinator); - } - - @Override - public StartSurface createStartSurface(@NonNull Activity activity, - @NonNull ScrimCoordinator scrimCoordinator, - @NonNull BottomSheetController sheetController, - @NonNull OneshotSupplierImpl<StartSurface> startSurfaceOneshotSupplier, - @NonNull Supplier<Tab> parentTabSupplier, boolean hadWarmStart, - @NonNull WindowAndroid windowAndroid, @NonNull ViewGroup containerView, - @NonNull Supplier<DynamicResourceLoader> dynamicResourceLoaderSupplier, - @NonNull TabModelSelector tabModelSelector, - @NonNull BrowserControlsManager browserControlsManager, - @NonNull SnackbarManager snackbarManager, - @NonNull Supplier<ShareDelegate> shareDelegateSupplier, - @NonNull Supplier<OmniboxStub> omniboxStubSupplier, - @NonNull TabContentManager tabContentManager, - @NonNull ModalDialogManager modalDialogManager, - @NonNull ChromeActivityNativeDelegate chromeActivityNativeDelegate, - @NonNull ActivityLifecycleDispatcher activityLifecycleDispatcher, - @NonNull TabCreatorManager tabCreatorManager, - @NonNull MenuOrKeyboardActionController menuOrKeyboardActionController, - @NonNull MultiWindowModeStateDispatcher multiWindowModeStateDispatcher, - @NonNull JankTracker jankTracker, @NonNull Supplier<Toolbar> toolbarSupplier) { - return StartSurfaceDelegate.createStartSurface(activity, scrimCoordinator, sheetController, - startSurfaceOneshotSupplier, parentTabSupplier, hadWarmStart, windowAndroid, - containerView, dynamicResourceLoaderSupplier, tabModelSelector, - browserControlsManager, snackbarManager, shareDelegateSupplier, omniboxStubSupplier, - tabContentManager, modalDialogManager, chromeActivityNativeDelegate, - activityLifecycleDispatcher, tabCreatorManager, menuOrKeyboardActionController, - multiWindowModeStateDispatcher, jankTracker, toolbarSupplier); - } - - @Override public TabGroupModelFilter createTabGroupModelFilter(TabModel tabModel) { return new TabGroupModelFilter( tabModel, TabUiFeatureUtilities.ENABLE_TAB_GROUP_AUTO_CREATION.getValue());
diff --git a/chrome/android/features/tab_ui/javatests/src/org/chromium/chrome/browser/tasks/tab_management/TabGridDialogTest.java b/chrome/android/features/tab_ui/javatests/src/org/chromium/chrome/browser/tasks/tab_management/TabGridDialogTest.java index 40939b8..263a757 100644 --- a/chrome/android/features/tab_ui/javatests/src/org/chromium/chrome/browser/tasks/tab_management/TabGridDialogTest.java +++ b/chrome/android/features/tab_ui/javatests/src/org/chromium/chrome/browser/tasks/tab_management/TabGridDialogTest.java
@@ -928,7 +928,7 @@ // Tab switcher is created, and the dummy signal to hide dialog is sent. This line would // crash if the dummy signal is not properly handled. See crbug.com/1096358. enterTabSwitcher(cta); - onView(allOf(withParent(withId(org.chromium.chrome.start_surface.R.id.tasks_surface_body)), + onView(allOf(withParent(withId(org.chromium.chrome.R.id.tasks_surface_body)), withId(R.id.tab_list_view))) .perform(RecyclerViewActions.actionOnItemAtPosition(0, click())); CriteriaHelper.pollUiThread(() -> isDialogShowing(mActivityTestRule.getActivity())); @@ -968,7 +968,7 @@ // Test undo closure in dialog from StartSurface tab switcher. enterTabSwitcher(cta); - onView(allOf(withParent(withId(org.chromium.chrome.start_surface.R.id.tasks_surface_body)), + onView(allOf(withParent(withId(org.chromium.chrome.R.id.tasks_surface_body)), withId(R.id.tab_list_view))) .perform(RecyclerViewActions.actionOnItemAtPosition(0, click())); CriteriaHelper.pollUiThread(() -> isDialogShowing(cta)); @@ -980,9 +980,8 @@ // Test undo closure in dialog from StartSurface home page. clickScrimToExitDialog(cta); - onView(withId(org.chromium.chrome.start_surface.R.id.new_tab_button)).perform(click()); - onView(allOf(withParent(withId(org.chromium.chrome.start_surface.R.id - .carousel_tab_switcher_container)), + onView(withId(R.id.new_tab_button)).perform(click()); + onView(allOf(withParent(withId(org.chromium.chrome.R.id.carousel_tab_switcher_container)), withId(R.id.tab_list_view))) .perform(RecyclerViewActions.actionOnItemAtPosition(0, click())); CriteriaHelper.pollUiThread(() -> isDialogShowing(cta));
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java b/chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java index 57aceb629..6124962 100644 --- a/chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java +++ b/chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java
@@ -168,7 +168,6 @@ import org.chromium.chrome.browser.tasks.TasksUma; import org.chromium.chrome.browser.tasks.tab_management.CloseAllTabsDialog; import org.chromium.chrome.browser.tasks.tab_management.TabGroupUi; -import org.chromium.chrome.browser.tasks.tab_management.TabManagementDelegate; import org.chromium.chrome.browser.tasks.tab_management.TabManagementModuleProvider; import org.chromium.chrome.browser.tasks.tab_management.TabUiFeatureUtilities; import org.chromium.chrome.browser.toolbar.ToolbarButtonInProductHelpController; @@ -186,6 +185,7 @@ import org.chromium.chrome.browser.vr.VrModuleProvider; import org.chromium.chrome.features.start_surface.StartSurface; import org.chromium.chrome.features.start_surface.StartSurfaceConfiguration; +import org.chromium.chrome.features.start_surface.StartSurfaceDelegate; import org.chromium.chrome.features.start_surface.StartSurfaceState; import org.chromium.chrome.features.start_surface.StartSurfaceUserData; import org.chromium.components.browser_ui.settings.SettingsLauncher; @@ -731,23 +731,19 @@ } private void createStartSurface(CompositorViewHolder compositorViewHolder) { - TabManagementDelegate tabManagementDelegate = TabManagementModuleProvider.getDelegate(); ViewGroup containerView = TabUiFeatureUtilities.isTabletGridTabSwitcherPolishEnabled(this) ? findViewById(R.id.grid_tab_switcher_view_holder) : compositorViewHolder; - if (tabManagementDelegate != null) { - tabManagementDelegate.createStartSurface(this, mRootUiCoordinator.getScrimCoordinator(), - mRootUiCoordinator.getBottomSheetController(), mStartSurfaceSupplier, - mStartSurfaceParentTabSupplier, hadWarmStart(), getWindowAndroid(), - containerView, compositorViewHolder::getDynamicResourceLoader, - getTabModelSelector(), getBrowserControlsManager(), getSnackbarManager(), - getShareDelegateSupplier(), getToolbarManager()::getOmniboxStub, - getTabContentManager(), getModalDialogManager(), - /* chromeActivityNativeDelegate= */ this, getLifecycleDispatcher(), - getTabCreatorManagerSupplier().get(), getMenuOrKeyboardActionController(), - getMultiWindowModeStateDispatcher(), mJankTracker, - getToolbarManager()::getToolbar); - } + StartSurfaceDelegate.createStartSurface(this, mRootUiCoordinator.getScrimCoordinator(), + mRootUiCoordinator.getBottomSheetController(), mStartSurfaceSupplier, + mStartSurfaceParentTabSupplier, hadWarmStart(), getWindowAndroid(), containerView, + compositorViewHolder::getDynamicResourceLoader, getTabModelSelector(), + getBrowserControlsManager(), getSnackbarManager(), getShareDelegateSupplier(), + getToolbarManager()::getOmniboxStub, getTabContentManager(), + getModalDialogManager(), + /* chromeActivityNativeDelegate= */ this, getLifecycleDispatcher(), + getTabCreatorManagerSupplier().get(), getMenuOrKeyboardActionController(), + getMultiWindowModeStateDispatcher(), mJankTracker, getToolbarManager()::getToolbar); } private void setupCompositorContentPostNative() {
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/contextualsearch/ContextualSearchPanelMetrics.java b/chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/contextualsearch/ContextualSearchPanelMetrics.java index afa37b8..d6041157 100644 --- a/chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/contextualsearch/ContextualSearchPanelMetrics.java +++ b/chrome/android/java/src/org/chromium/chrome/browser/compositor/bottombar/contextualsearch/ContextualSearchPanelMetrics.java
@@ -130,7 +130,6 @@ } if (mWasContextualCardsDataShown) { - ContextualSearchUma.logContextualCardsResultsSeen(mWasSearchContentViewSeen); EngagementSuppression.registerContextualCardsImpression(mWasSearchContentViewSeen); } ContextualSearchUma.logCardTagSeen(mWasSearchContentViewSeen, mCardTag);
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/compositor/layouts/LayoutManagerChrome.java b/chrome/android/java/src/org/chromium/chrome/browser/compositor/layouts/LayoutManagerChrome.java index 379f702..3acfa06 100644 --- a/chrome/android/java/src/org/chromium/chrome/browser/compositor/layouts/LayoutManagerChrome.java +++ b/chrome/android/java/src/org/chromium/chrome/browser/compositor/layouts/LayoutManagerChrome.java
@@ -30,13 +30,12 @@ import org.chromium.chrome.browser.tabmodel.TabCreatorManager; import org.chromium.chrome.browser.tabmodel.TabModelSelector; import org.chromium.chrome.browser.tabmodel.TabModelUtils; -import org.chromium.chrome.browser.tasks.tab_management.TabManagementDelegate; -import org.chromium.chrome.browser.tasks.tab_management.TabManagementModuleProvider; import org.chromium.chrome.browser.tasks.tab_management.TabUiFeatureUtilities; import org.chromium.chrome.browser.theme.TopUiThemeColorProvider; import org.chromium.chrome.browser.toolbar.ControlContainer; import org.chromium.chrome.browser.util.ChromeAccessibilityUtil; import org.chromium.chrome.features.start_surface.StartSurface; +import org.chromium.chrome.features.start_surface.StartSurfaceDelegate; import org.chromium.components.browser_ui.widget.gesture.SwipeGestureListener.ScrollDirection; import org.chromium.components.browser_ui.widget.gesture.SwipeGestureListener.SwipeHandler; import org.chromium.components.browser_ui.widget.scrim.ScrimCoordinator; @@ -109,11 +108,8 @@ if (createOverviewLayout) { if (startSurface != null) { assert TabUiFeatureUtilities.isGridTabSwitcherEnabled(context); - TabManagementDelegate tabManagementDelegate = - TabManagementModuleProvider.getDelegate(); - assert tabManagementDelegate != null; - mOverviewLayout = tabManagementDelegate.createStartSurfaceLayout(context, this, + mOverviewLayout = StartSurfaceDelegate.createStartSurfaceLayout(context, this, renderHost, startSurface, jankTracker, startSurfaceScrimAnchor, scrimCoordinator);
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchManager.java b/chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchManager.java index f197dff..f54c3502 100644 --- a/chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchManager.java +++ b/chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchManager.java
@@ -908,7 +908,6 @@ if (mSearchPanel.isContentShowing() || shouldPreload) { loadSearchUrl(); } - mPolicy.logSearchTermResolutionDetails(searchTerm); } }
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchPolicy.java b/chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchPolicy.java index 43ffe64b..2970c39 100644 --- a/chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchPolicy.java +++ b/chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchPolicy.java
@@ -38,14 +38,11 @@ import org.chromium.components.version_info.VersionInfo; import org.chromium.url.GURL; -import java.util.regex.Pattern; - /** * Handles business decision policy for the {@code ContextualSearchManager}. */ class ContextualSearchPolicy { private static final String TAG = "ContextualSearch"; - private static final Pattern CONTAINS_WHITESPACE_PATTERN = Pattern.compile("\\s"); private static final String DOMAIN_GOOGLE = "google"; private static final String PATH_AMP = "/amp/"; private static final int REMAINING_NOT_APPLICABLE = -1; @@ -342,24 +339,6 @@ } /** - * Logs details about the Search Term Resolution. - * Should only be called when a search term has been resolved. - * @param searchTerm The Resolved Search Term. - */ - void logSearchTermResolutionDetails(String searchTerm) { - // Only log for decided users so the data reflect fully-enabled behavior. - // Otherwise we'll get skewed data; more HTTP pages than HTTPS (since those don't resolve), - // and it's also possible that public pages, e.g. news, have more searches for multi-word - // entities like people. - if (isContextualSearchFullyEnabled()) { - GURL url = mNetworkCommunicator.getBasePageUrl(); - ContextualSearchUma.logBasePageProtocol(isBasePageHTTP(url)); - boolean isSingleWord = !CONTAINS_WHITESPACE_PATTERN.matcher(searchTerm.trim()).find(); - ContextualSearchUma.logSearchTermResolvedWords(isSingleWord); - } - } - - /** * Logs whether the current user is qualified to do Related Searches requests. This does not * check if Related Searches is actually enabled for the current user, only whether they are * qualified. We use this to gauge whether each group has a balanced number of qualified users.
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchUma.java b/chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchUma.java index c81f3ff9..db0a9a31 100644 --- a/chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchUma.java +++ b/chrome/android/java/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchUma.java
@@ -269,24 +269,6 @@ int NUM_ENTRIES = 6; } - // Constants used to log UMA "enum" histograms for HTTP / HTTPS. - @IntDef({Protocol.IS_HTTP, Protocol.NOT_HTTP}) - @Retention(RetentionPolicy.SOURCE) - private @interface Protocol { - int IS_HTTP = 0; - int NOT_HTTP = 1; - int NUM_ENTRIES = 2; - } - - // Constants used to log UMA "enum" histograms for single / multi-word. - @IntDef({ResolvedGranularity.SINGLE_WORD, ResolvedGranularity.MULTI_WORD}) - @Retention(RetentionPolicy.SOURCE) - private @interface ResolvedGranularity { - int SINGLE_WORD = 0; - int MULTI_WORD = 1; - int NUM_ENTRIES = 2; - } - // Constants used to log UMA "enum" histograms for Quick Answers. @IntDef({QuickAnswerSeen.ACTIVATED_WAS_AN_ANSWER_SEEN, QuickAnswerSeen.ACTIVATED_WAS_AN_ANSWER_NOT_SEEN, @@ -654,26 +636,6 @@ } /** - * Logs whether the Search Term was single or multiword. - * @param isSingleWord Whether the resolved search term is a single word or not. - */ - public static void logSearchTermResolvedWords(boolean isSingleWord) { - RecordHistogram.recordEnumeratedHistogram("Search.ContextualSearchResolvedTermWords", - isSingleWord ? ResolvedGranularity.SINGLE_WORD : ResolvedGranularity.MULTI_WORD, - ResolvedGranularity.NUM_ENTRIES); - } - - /** - * Logs whether the base page was using the HTTP protocol or not. - * @param isHttpBasePage Whether the base page was using the HTTP protocol or not (should - * be false for HTTPS or other URIs). - */ - public static void logBasePageProtocol(boolean isHttpBasePage) { - RecordHistogram.recordEnumeratedHistogram("Search.ContextualSearchBasePageProtocol", - isHttpBasePage ? Protocol.IS_HTTP : Protocol.NOT_HTTP, Protocol.NUM_ENTRIES); - } - - /** * Logs changes to the Contextual Search preference, aside from those resulting from the first * run flow. * @param enabled Whether the preference is being enabled or disabled. @@ -1396,16 +1358,6 @@ } /** - * Logs whether results were seen when Contextual Cards data was shown. - * @param wasSeen Whether the search results were seen. - */ - public static void logContextualCardsResultsSeen(boolean wasSeen) { - RecordHistogram.recordEnumeratedHistogram( - "Search.ContextualSearchContextualCardsIntegration.ResultsSeen", - wasSeen ? Results.SEEN : Results.NOT_SEEN, Results.NUM_ENTRIES); - } - - /** * Logs whether a quick action intent resolved to zero, one, or many apps. * @param quickActionCategory The {@link QuickActionCategory} for the quick action. * @param numMatchingAppsApps The number of apps that the resolved intent matched.
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/history/HistoryActivity.java b/chrome/android/java/src/org/chromium/chrome/browser/history/HistoryActivity.java index 6635967..d1f14a55 100644 --- a/chrome/android/java/src/org/chromium/chrome/browser/history/HistoryActivity.java +++ b/chrome/android/java/src/org/chromium/chrome/browser/history/HistoryActivity.java
@@ -5,19 +5,27 @@ package org.chromium.chrome.browser.history; import android.os.Bundle; +import android.text.TextUtils; +import android.view.View; +import androidx.annotation.Nullable; import androidx.annotation.VisibleForTesting; import org.chromium.base.IntentUtils; import org.chromium.chrome.browser.BackPressHelper; import org.chromium.chrome.browser.IntentHandler; import org.chromium.chrome.browser.SnackbarActivity; +import org.chromium.chrome.browser.flags.ChromeFeatureList; +import org.chromium.chrome.browser.history_clusters.HistoryClustersCoordinator; +import org.chromium.chrome.browser.history_clusters.HistoryClustersIntent; +import org.chromium.chrome.browser.profiles.Profile; /** * Activity for displaying the browsing history manager. */ public class HistoryActivity extends SnackbarActivity { private HistoryManager mHistoryManager; + private @Nullable HistoryClustersCoordinator mHistoryClustersCoordinator; @Override public void onCreate(Bundle savedInstanceState) { @@ -25,10 +33,33 @@ boolean isIncognito = IntentUtils.safeGetBooleanExtra( getIntent(), IntentHandler.EXTRA_INCOGNITO_MODE, false); + + // TODO(https://crbug.com/1303171): Move history clusters feature flag and view switching + // logic to HistoryManager in order to support the tablet UI; HistoryActivity is currently + // only for phones. + boolean historyClustersEnabled = + ChromeFeatureList.isEnabled(ChromeFeatureList.HISTORY_JOURNEYS); + boolean showHistoryClusters = false; + if (historyClustersEnabled) { + mHistoryClustersCoordinator = new HistoryClustersCoordinator( + Profile.getLastUsedRegularProfile(), this, null, null); + showHistoryClusters = IntentUtils.safeGetBooleanExtra( + getIntent(), HistoryClustersIntent.EXTRA_SHOW_HISTORY_CLUSTERS, false); + String query = IntentUtils.safeGetStringExtra( + getIntent(), HistoryClustersIntent.EXTRA_HISTORY_CLUSTERS_QUERY); + if (!TextUtils.isEmpty(query)) { + mHistoryClustersCoordinator.setQuery(query); + } + } + mHistoryManager = new HistoryManager( this, true, getSnackbarManager(), isIncognito, /* Supplier<Tab>= */ null); - setContentView(mHistoryManager.getView()); BackPressHelper.create(this, getOnBackPressedDispatcher(), mHistoryManager::onBackPressed); + + View contentView = showHistoryClusters + ? mHistoryClustersCoordinator.getActivityContentView() + : mHistoryManager.getView(); + setContentView(contentView); } @Override
diff --git a/chrome/android/javatests/src/org/chromium/chrome/browser/app/appmenu/TabbedAppMenuTest.java b/chrome/android/javatests/src/org/chromium/chrome/browser/app/appmenu/TabbedAppMenuTest.java index b965248..2090a08 100644 --- a/chrome/android/javatests/src/org/chromium/chrome/browser/app/appmenu/TabbedAppMenuTest.java +++ b/chrome/android/javatests/src/org/chromium/chrome/browser/app/appmenu/TabbedAppMenuTest.java
@@ -25,6 +25,7 @@ import org.chromium.base.test.util.CommandLineFlags; import org.chromium.base.test.util.Criteria; import org.chromium.base.test.util.CriteriaHelper; +import org.chromium.base.test.util.DisabledTest; import org.chromium.base.test.util.Feature; import org.chromium.base.test.util.Restriction; import org.chromium.base.test.util.UrlUtils; @@ -288,6 +289,7 @@ @Feature({"Browser", "Main", "RenderTest"}) @Restriction(UiRestriction.RESTRICTION_TYPE_PHONE) @EnableFeatures(ChromeFeatureList.APP_MENU_MOBILE_SITE_OPTION) + @DisabledTest(message = "https://crbug.com/1322581") public void testRequestDesktopSiteMenuItem() throws IOException { Tab tab = mActivityTestRule.getActivity().getTabModelSelector().getCurrentTab(); boolean isRequestDesktopSite = @@ -322,6 +324,7 @@ @Feature({"Browser", "Main", "RenderTest"}) @DisableFeatures(ChromeFeatureList.APP_MENU_MOBILE_SITE_OPTION) @Restriction(UiRestriction.RESTRICTION_TYPE_PHONE) + @DisabledTest(message = "https://crbug.com/1322581") public void testRequestDesktopSiteMenuItem_checkbox() throws IOException { Tab tab = mActivityTestRule.getActivity().getTabModelSelector().getCurrentTab(); boolean isRequestDesktopSite =
diff --git a/chrome/android/javatests/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchManagerTest.java b/chrome/android/javatests/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchManagerTest.java index 9ae6cf9..44e3729f 100644 --- a/chrome/android/javatests/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchManagerTest.java +++ b/chrome/android/javatests/src/org/chromium/chrome/browser/contextualsearch/ContextualSearchManagerTest.java
@@ -25,6 +25,7 @@ import com.google.common.collect.ImmutableMap; import org.hamcrest.Matchers; +import org.junit.After; import org.junit.Assert; import org.junit.Before; import org.junit.Test; @@ -149,6 +150,12 @@ super.setUp(); } + @Override + @After + public void tearDown() throws Exception { + if (mActionTester != null) mActionTester.tearDown(); + } + //============================================================================================ // UMA assertions //============================================================================================
diff --git a/chrome/android/javatests/src/org/chromium/chrome/browser/status_indicator/StatusIndicatorTest.java b/chrome/android/javatests/src/org/chromium/chrome/browser/status_indicator/StatusIndicatorTest.java index f9cbb92..63fc2684 100644 --- a/chrome/android/javatests/src/org/chromium/chrome/browser/status_indicator/StatusIndicatorTest.java +++ b/chrome/android/javatests/src/org/chromium/chrome/browser/status_indicator/StatusIndicatorTest.java
@@ -206,8 +206,7 @@ // clang-format on TabUiTestHelper.enterTabSwitcher(mActivityTestRule.getActivity()); - onView(withId(org.chromium.chrome.start_surface.R.id.secondary_tasks_surface_view)) - .check(matches(isDisplayed())); + onView(withId(R.id.secondary_tasks_surface_view)).check(matches(isDisplayed())); onView(withId(R.id.status_indicator)).check(matches(withEffectiveVisibility(GONE))); onView(withId(R.id.control_container)).check(matches(withTopMargin(0))); Assert.assertFalse("Wrong initial composited view visibility.", @@ -226,7 +225,7 @@ onView(withId(R.id.control_container)) .check(matches(withTopMargin(getStatusIndicator().getHeight()))); - onView(withId(org.chromium.chrome.start_surface.R.id.secondary_tasks_surface_view)) + onView(withId(R.id.secondary_tasks_surface_view)) .check(matches( withTopMargin(mBrowserControlsStateProvider.getTopControlsHeight()))); @@ -238,7 +237,7 @@ onView(withId(R.id.status_indicator)).check(matches(withEffectiveVisibility(VISIBLE))); onView(withId(R.id.control_container)) .check(matches(withTopMargin(getStatusIndicator().getHeight()))); - onView(withId(org.chromium.chrome.start_surface.R.id.secondary_tasks_surface_view)) + onView(withId(R.id.secondary_tasks_surface_view)) .check(matches( withTopMargin(mBrowserControlsStateProvider.getTopControlsHeight()))); @@ -250,7 +249,7 @@ onView(withId(R.id.status_indicator)).check(matches(withEffectiveVisibility(GONE))); onView(withId(R.id.control_container)).check(matches(withTopMargin(0))); - onView(withId(org.chromium.chrome.start_surface.R.id.secondary_tasks_surface_view)) + onView(withId(R.id.secondary_tasks_surface_view)) .check(matches( withTopMargin(mBrowserControlsStateProvider.getTopControlsHeight()))); }
diff --git a/chrome/android/javatests/src/org/chromium/chrome/browser/sync/SyncTest.java b/chrome/android/javatests/src/org/chromium/chrome/browser/sync/SyncTest.java index ac2d5a9..9e8e82f 100644 --- a/chrome/android/javatests/src/org/chromium/chrome/browser/sync/SyncTest.java +++ b/chrome/android/javatests/src/org/chromium/chrome/browser/sync/SyncTest.java
@@ -38,10 +38,10 @@ private static final String TAG = "SyncTest"; - @DisabledTest(message = "https://crbug.com/1197554") @Test @LargeTest @Feature({"Sync"}) + @DisabledTest(message = "https://crbug.com/1197554") public void testSignInAndOut() { CoreAccountInfo accountInfo = mSyncTestRule.setUpAccountAndEnableSyncForTesting(); @@ -57,6 +57,7 @@ @Test @LargeTest @Feature({"Sync"}) + @DisabledTest(message = "https://crbug.com/1322619") public void testStopAndClear() { mSyncTestRule.setUpAccountAndEnableSyncForTesting(); CriteriaHelper.pollUiThread(
diff --git a/chrome/android/junit/src/org/chromium/chrome/browser/history_clusters/HistoryClustersMediatorTest.java b/chrome/android/junit/src/org/chromium/chrome/browser/history_clusters/HistoryClustersMediatorTest.java index 295d0fb..89be260 100644 --- a/chrome/android/junit/src/org/chromium/chrome/browser/history_clusters/HistoryClustersMediatorTest.java +++ b/chrome/android/junit/src/org/chromium/chrome/browser/history_clusters/HistoryClustersMediatorTest.java
@@ -80,6 +80,7 @@ mBottomSheetContent = new HistoryClustersBottomSheetContent(); mMediator = new HistoryClustersMediator(mBridge, mLargeIconBridge, mContext, mResources, mModelList, new PropertyModel(HistoryClustersBottomSheetToolbarProperties.ALL_KEYS), + new PropertyModel(HistoryClustersToolbarProperties.ALL_KEYS), mBottomSheetController, mBottomSheetContent, mHistoryActivityIntentFactory); mVisit1 = new ClusterVisit(1.0F, mGurl1, "Title 1"); mVisit2 = new ClusterVisit(1.0F, mGurl2, "Title 1");
diff --git a/chrome/app/chrome_main_delegate.cc b/chrome/app/chrome_main_delegate.cc index bd46fe2..52920c2 100644 --- a/chrome/app/chrome_main_delegate.cc +++ b/chrome/app/chrome_main_delegate.cc
@@ -93,6 +93,7 @@ #include "chrome/chrome_elf/chrome_elf_main.h" #include "chrome/common/child_process_logging.h" #include "chrome/common/protobuf_init.h" +#include "chrome/common/win/delay_load_failure_hook.h" #include "chrome/install_static/install_util.h" #include "components/browser_watcher/extended_crash_reporting.h" #include "sandbox/win/src/sandbox.h" @@ -528,6 +529,11 @@ // Initialize the cleaner of left-behind tmp files now that the main thread // has its SequencedTaskRunner; see https://crbug.com/1075917. base::ImportantFileWriterCleaner::GetInstance().Initialize(); + + // For now, do not enable delay load failure hooks for browser process except + // in tests, where failures really shouldn't happen. + if (!is_running_tests) + chrome::DisableDelayLoadFailureHooksForCurrentModule(); #endif // Chrome disallows cookies by default. All code paths that want to use
diff --git a/chrome/browser/about_flags.cc b/chrome/browser/about_flags.cc index d4c1918c..c50a1fb 100644 --- a/chrome/browser/about_flags.cc +++ b/chrome/browser/about_flags.cc
@@ -6897,6 +6897,10 @@ {"shared-highlighting-amp", flag_descriptions::kSharedHighlightingAmpName, flag_descriptions::kSharedHighlightingAmpDescription, kOsAll, FEATURE_VALUE_TYPE(shared_highlighting::kSharedHighlightingAmp)}, + {"shared-highlighting-refined-blocklist", + flag_descriptions::kSharedHighlightingRefinedBlocklistName, + flag_descriptions::kSharedHighlightingRefinedBlocklistDescription, kOsAll, + FEATURE_VALUE_TYPE(share::kSharedHighlightingRefinedBlocklist)}, #if BUILDFLAG(IS_CHROMEOS_ASH) {"shimless-rma-flow", flag_descriptions::kShimlessRMAFlowName,
diff --git a/chrome/browser/ash/arc/input_overlay/input_overlay_resources_util.cc b/chrome/browser/ash/arc/input_overlay/input_overlay_resources_util.cc index 55f308b..d919cd91 100644 --- a/chrome/browser/ash/arc/input_overlay/input_overlay_resources_util.cc +++ b/chrome/browser/ash/arc/input_overlay/input_overlay_resources_util.cc
@@ -20,6 +20,7 @@ {"com.fingersoft.hillclimb", IDR_IO_COM_FINGERSOFT_HILLCLIMB}, {"com.androbaby.game2048", IDR_IO_COM_ANDROBABY_GAME2048}, {"co.imba.archero", IDR_IO_CO_IMBA_ARCHERO}, + {"com.datavisionstudio.roguelike", IDR_IO_COM_DATAVISIONSTUDIO_ROGUELIKE}, }; auto it = resource_id_map.find(package_name);
diff --git a/chrome/browser/ash/crostini/crostini_shelf_utils.cc b/chrome/browser/ash/crostini/crostini_shelf_utils.cc index 8ba5b26..4316baf 100644 --- a/chrome/browser/ash/crostini/crostini_shelf_utils.cc +++ b/chrome/browser/ash/crostini/crostini_shelf_utils.cc
@@ -4,6 +4,8 @@ #include "chrome/browser/ash/crostini/crostini_shelf_utils.h" +#include "ash/constants/ash_features.h" +#include "base/feature_list.h" #include "base/logging.h" #include "base/no_destructor.h" #include "base/strings/string_piece.h" @@ -223,8 +225,10 @@ if (IsUnmatchedCrostiniShelfAppId(shelf_app_id)) { return true; } - if (shelf_app_id == kCrostiniTerminalSystemAppId) + if (!base::FeatureList::IsEnabled(chromeos::features::kTerminalSSH) && + shelf_app_id == kCrostiniTerminalSystemAppId) { return true; + } // TODO(timloh): We need to handle desktop files that have been removed. // For example, running windows with a no-longer-valid app id will try to // use the ExtensionContextMenuModel.
diff --git a/chrome/browser/ash/crostini/crostini_test_helper.h b/chrome/browser/ash/crostini/crostini_test_helper.h index 06168ece..f5485a6 100644 --- a/chrome/browser/ash/crostini/crostini_test_helper.h +++ b/chrome/browser/ash/crostini/crostini_test_helper.h
@@ -69,8 +69,8 @@ // Returns an ApplicationList with a single desktop file. static vm_tools::apps::ApplicationList BasicAppList( const std::string& desktop_file_id, - const std::string& vm_name, - const std::string& container_name); + const std::string& vm_name = kCrostiniDefaultVmName, + const std::string& container_name = kCrostiniDefaultContainerName); private: void UpdateRegistry();
diff --git a/chrome/browser/ash/crostini/crostini_util.cc b/chrome/browser/ash/crostini/crostini_util.cc index 3d9570a..94104e4 100644 --- a/chrome/browser/ash/crostini/crostini_util.cc +++ b/chrome/browser/ash/crostini/crostini_util.cc
@@ -7,6 +7,7 @@ #include <utility> #include "ash/constants/app_types.h" +#include "ash/constants/ash_features.h" #include "base/bind.h" #include "base/callback.h" #include "base/callback_helpers.h" @@ -353,7 +354,8 @@ return std::move(callback).Run(false, "Crostini UI not allowed"); } - if (app_id == kCrostiniTerminalSystemAppId) { + if (!base::FeatureList::IsEnabled(ash::features::kTerminalSSH) && + app_id == kCrostiniTerminalSystemAppId) { // Terminal supports a single directory as arg. If it exists, convert it // to an intent file. // TODO(crbug.com/1028898): This can be deleted when TerminalSSH flag
diff --git a/chrome/browser/ash/guest_os/guest_os_registry_service_unittest.cc b/chrome/browser/ash/guest_os/guest_os_registry_service_unittest.cc index 902517fa..64dc95c 100644 --- a/chrome/browser/ash/guest_os/guest_os_registry_service_unittest.cc +++ b/chrome/browser/ash/guest_os/guest_os_registry_service_unittest.cc
@@ -6,7 +6,9 @@ #include <stddef.h> +#include "ash/constants/ash_features.h" #include "base/test/metrics/histogram_tester.h" +#include "base/test/scoped_feature_list.h" #include "base/test/simple_test_clock.h" #include "chrome/browser/ash/crostini/crostini_pref_names.h" #include "chrome/browser/ash/crostini/crostini_test_helper.h" @@ -32,6 +34,7 @@ class GuestOsRegistryServiceTest : public testing::Test { public: GuestOsRegistryServiceTest() : crostini_test_helper_(&profile_) { + features_.InitWithFeatures({ash::features::kTerminalSSH}, {}); RecreateService(); } @@ -82,6 +85,7 @@ content::BrowserTaskEnvironment task_environment_; TestingProfile profile_; crostini::CrostiniTestHelper crostini_test_helper_; + base::test::ScopedFeatureList features_; std::unique_ptr<GuestOsRegistryService> service_; }; @@ -363,10 +367,8 @@ std::string app_id_3 = crostini::CrostiniTestHelper::GenerateAppId("app", "vm 2", "container 1"); - EXPECT_THAT( - GetRegisteredAppIds(), - testing::UnorderedElementsAre(app_id_1, app_id_2, app_id_3, - crostini::kCrostiniTerminalSystemAppId)); + EXPECT_THAT(GetRegisteredAppIds(), + testing::UnorderedElementsAre(app_id_1, app_id_2, app_id_3)); // Clobber app_id_2 service()->UpdateApplicationList(crostini::CrostiniTestHelper::BasicAppList( @@ -374,10 +376,8 @@ std::string new_app_id = crostini::CrostiniTestHelper::GenerateAppId( "app 2", "vm 1", "container 2"); - EXPECT_THAT( - GetRegisteredAppIds(), - testing::UnorderedElementsAre(app_id_1, app_id_3, new_app_id, - crostini::kCrostiniTerminalSystemAppId)); + EXPECT_THAT(GetRegisteredAppIds(), + testing::UnorderedElementsAre(app_id_1, app_id_3, new_app_id)); } // Test that ClearApplicationList works, and only removes apps from the @@ -402,16 +402,14 @@ EXPECT_THAT( GetRegisteredAppIds(), - testing::UnorderedElementsAre(app_id_1, app_id_2, app_id_3, app_id_4, - crostini::kCrostiniTerminalSystemAppId)); + testing::UnorderedElementsAre(app_id_1, app_id_2, app_id_3, app_id_4)); service()->ClearApplicationList( GuestOsRegistryService::VmType::ApplicationList_VmType_TERMINA, "vm 2", ""); EXPECT_THAT(GetRegisteredAppIds(), - testing::UnorderedElementsAre( - app_id_1, app_id_2, crostini::kCrostiniTerminalSystemAppId)); + testing::UnorderedElementsAre(app_id_1, app_id_2)); } TEST_F(GuestOsRegistryServiceTest, IsScaledReturnFalseWhenNotSet) { @@ -541,28 +539,6 @@ EXPECT_EQ(result_no_package_id->PackageId(), ""); } -// Validates crash fix from crbug.com/1113477. -TEST_F(GuestOsRegistryServiceTest, TerminalPrefsAppMerge) { - // Add prefs entry for terminal. - base::DictionaryValue registry; - registry.SetKey(crostini::kCrostiniTerminalSystemAppId, - base::DictionaryValue()); - profile()->GetPrefs()->Set(guest_os::prefs::kGuestOsRegistry, - std::move(registry)); - - // Pref values should merge with app values, and reading Terminal VmName - // should not crash. - bool terminal_found = false; - for (const auto& pair : service()->GetAllRegisteredApps()) { - const auto& registration = pair.second; - if (registration.app_id() == crostini::kCrostiniTerminalSystemAppId) { - terminal_found = true; - EXPECT_EQ(crostini::kCrostiniDefaultVmName, registration.VmName()); - } - } - EXPECT_TRUE(terminal_found); -} - TEST_F(GuestOsRegistryServiceTest, GetEnabledApps) { crostini::FakeCrostiniFeatures fake_crostini_features; plugin_vm::FakePluginVmFeatures fake_plugin_vm_features; @@ -575,7 +551,6 @@ *crostini_list.add_apps() = crostini::CrostiniTestHelper::BasicApp("c"); std::string c = crostini::CrostiniTestHelper::GenerateAppId("c", "termina", "penguin"); - const std::string& t = crostini::kCrostiniTerminalSystemAppId; service()->UpdateApplicationList(crostini_list); ApplicationList plugin_vm_list; @@ -591,25 +566,25 @@ // All enabled. fake_crostini_features.set_enabled(true); fake_plugin_vm_features.set_enabled(true); - EXPECT_THAT(GetRegisteredAppIds(), testing::UnorderedElementsAre(t, p, c)); - EXPECT_THAT(GetEnabledAppIds(), testing::UnorderedElementsAre(t, p, c)); + EXPECT_THAT(GetRegisteredAppIds(), testing::UnorderedElementsAre(p, c)); + EXPECT_THAT(GetEnabledAppIds(), testing::UnorderedElementsAre(p, c)); // Crostini disabled. fake_crostini_features.set_enabled(false); fake_plugin_vm_features.set_enabled(true); - EXPECT_THAT(GetRegisteredAppIds(), testing::UnorderedElementsAre(t, p, c)); + EXPECT_THAT(GetRegisteredAppIds(), testing::UnorderedElementsAre(p, c)); EXPECT_THAT(GetEnabledAppIds(), testing::UnorderedElementsAre(p)); // Plugin VM disabled. fake_crostini_features.set_enabled(true); fake_plugin_vm_features.set_enabled(false); - EXPECT_THAT(GetRegisteredAppIds(), testing::UnorderedElementsAre(t, p, c)); - EXPECT_THAT(GetEnabledAppIds(), testing::UnorderedElementsAre(t, c)); + EXPECT_THAT(GetRegisteredAppIds(), testing::UnorderedElementsAre(p, c)); + EXPECT_THAT(GetEnabledAppIds(), testing::UnorderedElementsAre(c)); // All disabled. fake_crostini_features.set_enabled(false); fake_plugin_vm_features.set_enabled(false); - EXPECT_THAT(GetRegisteredAppIds(), testing::UnorderedElementsAre(t, p, c)); + EXPECT_THAT(GetRegisteredAppIds(), testing::UnorderedElementsAre(p, c)); EXPECT_THAT(GetEnabledAppIds(), testing::IsEmpty()); }
diff --git a/chrome/browser/ash/network_change_manager_client.cc b/chrome/browser/ash/network_change_manager_client.cc index 6ca1e8b..f96b319 100644 --- a/chrome/browser/ash/network_change_manager_client.cc +++ b/chrome/browser/ash/network_change_manager_client.cc
@@ -221,6 +221,8 @@ technology == shill::kNetworkTechnologyLteAdvanced) { return net::NetworkChangeNotifier::CONNECTION_4G; } + if (technology == shill::kNetworkTechnology5gNr) + return net::NetworkChangeNotifier::CONNECTION_5G; // Default cellular type is 2G. return net::NetworkChangeNotifier::CONNECTION_2G;
diff --git a/chrome/browser/ash/network_change_manager_client_unittest.cc b/chrome/browser/ash/network_change_manager_client_unittest.cc index 8d49723..b47d667 100644 --- a/chrome/browser/ash/network_change_manager_client_unittest.cc +++ b/chrome/browser/ash/network_change_manager_client_unittest.cc
@@ -92,6 +92,8 @@ NetworkChangeNotifier::CONNECTION_4G}, {shill::kTypeCellular, shill::kNetworkTechnologyLteAdvanced, NetworkChangeNotifier::CONNECTION_4G}, + {shill::kTypeCellular, shill::kNetworkTechnology5gNr, + NetworkChangeNotifier::CONNECTION_5G}, {shill::kTypeCellular, "unknown technology", NetworkChangeNotifier::CONNECTION_2G}};
diff --git a/chrome/browser/ash/policy/status_collector/device_status_collector_browsertest.cc b/chrome/browser/ash/policy/status_collector/device_status_collector_browsertest.cc index 52aea1a7..8bcb1f2c 100644 --- a/chrome/browser/ash/policy/status_collector/device_status_collector_browsertest.cc +++ b/chrome/browser/ash/policy/status_collector/device_status_collector_browsertest.cc
@@ -2246,8 +2246,10 @@ testing_profile_->GetPrefs()->SetBoolean(crostini::prefs::kCrostiniEnabled, true); - scoped_feature_list_.InitAndEnableFeature( - features::kCrostiniAdditionalEnterpriseReporting); + scoped_feature_list_.InitWithFeatures( + {features::kCrostiniAdditionalEnterpriseReporting, + ash::features::kTerminalSSH}, + {}); const std::string desktop_file_id = "vim"; const std::string package_id = @@ -2275,7 +2277,7 @@ GetStatus(); EXPECT_TRUE(got_session_status_); - EXPECT_EQ(2, session_status_.crostini_status().installed_apps_size()); + EXPECT_EQ(1, session_status_.crostini_status().installed_apps_size()); EXPECT_EQ(desktop_file_id, session_status_.crostini_status().installed_apps()[0].app_name()); EXPECT_EQ(em::CROSTINI_APP_TYPE_INTERACTIVE, @@ -2293,19 +2295,6 @@ EXPECT_EQ( "2:8.0.0197-4+deb9u1", session_status_.crostini_status().installed_apps()[0].package_version()); - EXPECT_EQ("Terminal", - session_status_.crostini_status().installed_apps()[1].app_name()); - EXPECT_EQ(em::CROSTINI_APP_TYPE_TERMINAL, - session_status_.crostini_status().installed_apps()[1].app_type()); - EXPECT_EQ( - std::string(), - session_status_.crostini_status().installed_apps()[1].package_name()); - EXPECT_EQ( - std::string(), - session_status_.crostini_status().installed_apps()[1].package_version()); - EXPECT_EQ(0, session_status_.crostini_status() - .installed_apps()[1] - .last_launch_time_window_start_timestamp()); // In tests, GetUserDMToken returns the e-mail for easy verification. EXPECT_EQ(account_id.GetUserEmail(), session_status_.user_dm_token());
diff --git a/chrome/browser/ash/policy/status_collector/legacy_device_status_collector_browsertest.cc b/chrome/browser/ash/policy/status_collector/legacy_device_status_collector_browsertest.cc index f0e4f5b..947804a2 100644 --- a/chrome/browser/ash/policy/status_collector/legacy_device_status_collector_browsertest.cc +++ b/chrome/browser/ash/policy/status_collector/legacy_device_status_collector_browsertest.cc
@@ -19,6 +19,7 @@ #include "ash/components/settings/cros_settings_names.h" #include "ash/components/settings/timezone_settings.h" #include "ash/components/tpm/stub_install_attributes.h" +#include "ash/constants/ash_features.h" #include "base/bind.h" #include "base/environment.h" #include "base/files/file_path.h" @@ -2270,8 +2271,10 @@ testing_profile_->GetPrefs()->SetBoolean(crostini::prefs::kCrostiniEnabled, true); - scoped_feature_list_.InitAndEnableFeature( - features::kCrostiniAdditionalEnterpriseReporting); + scoped_feature_list_.InitWithFeatures( + {features::kCrostiniAdditionalEnterpriseReporting, + ash::features::kTerminalSSH}, + {}); const std::string desktop_file_id = "vim"; const std::string package_id = @@ -2299,7 +2302,7 @@ GetStatus(); EXPECT_TRUE(got_session_status_); - EXPECT_EQ(2, session_status_.crostini_status().installed_apps_size()); + EXPECT_EQ(1, session_status_.crostini_status().installed_apps_size()); EXPECT_EQ(desktop_file_id, session_status_.crostini_status().installed_apps()[0].app_name()); EXPECT_EQ(em::CROSTINI_APP_TYPE_INTERACTIVE, @@ -2317,19 +2320,6 @@ EXPECT_EQ( "2:8.0.0197-4+deb9u1", session_status_.crostini_status().installed_apps()[0].package_version()); - EXPECT_EQ("Terminal", - session_status_.crostini_status().installed_apps()[1].app_name()); - EXPECT_EQ(em::CROSTINI_APP_TYPE_TERMINAL, - session_status_.crostini_status().installed_apps()[1].app_type()); - EXPECT_EQ( - std::string(), - session_status_.crostini_status().installed_apps()[1].package_name()); - EXPECT_EQ( - std::string(), - session_status_.crostini_status().installed_apps()[1].package_version()); - EXPECT_EQ(0, session_status_.crostini_status() - .installed_apps()[1] - .last_launch_time_window_start_timestamp()); // In tests, GetUserDMToken returns the e-mail for easy verification. EXPECT_EQ(account_id.GetUserEmail(), session_status_.user_dm_token());
diff --git a/chrome/browser/ash/web_applications/terminal_source.cc b/chrome/browser/ash/web_applications/terminal_source.cc index 8ac46c5..d968832 100644 --- a/chrome/browser/ash/web_applications/terminal_source.cc +++ b/chrome/browser/ash/web_applications/terminal_source.cc
@@ -73,6 +73,7 @@ kTestFiles({ {"html/crosh.html", ""}, {"html/terminal.html", "<script src='/js/terminal.js'></script>"}, + {"html/terminal_home.html", ""}, {"js/terminal.js", "chrome.terminalPrivate.openVmshellProcess([], () => {})"}, });
diff --git a/chrome/browser/cart/resources/cart_domain_name_mapping.json b/chrome/browser/cart/resources/cart_domain_name_mapping.json index cd8aad9a..eca268d 100644 --- a/chrome/browser/cart/resources/cart_domain_name_mapping.json +++ b/chrome/browser/cart/resources/cart_domain_name_mapping.json
@@ -68,7 +68,7 @@ "neimanmarcus.com": "Neiman Marcus", "newegg.com": "Newegg", "nike.com": "Nike", -"nordstrom.com": "Nordstorm", +"nordstrom.com": "Nordstrom", "officedepot.com": "Office Depot", "opticsplanet.com": "OpticsPlanet", "overstock.com": "Overstock.com",
diff --git a/chrome/browser/chrome_browser_main_win.cc b/chrome/browser/chrome_browser_main_win.cc index 8968aba5..600097b 100644 --- a/chrome/browser/chrome_browser_main_win.cc +++ b/chrome/browser/chrome_browser_main_win.cc
@@ -7,6 +7,7 @@ // windows.h must be included before shellapi.h #include <windows.h> +#include <delayimp.h> #include <shellapi.h> #include <stddef.h> #include <stdint.h> @@ -681,6 +682,10 @@ void ChromeBrowserMainPartsWin::PostBrowserStart() { ChromeBrowserMainParts::PostBrowserStart(); + // Verify that the delay load helper hooks are in place. This cannot be tested + // from unit tests, so rely on this failing here. + DCHECK(__pfnDliFailureHook2); + InitializeChromeElf(); // Reset settings for the current profile if it's tagged to be reset after a
diff --git a/chrome/browser/extensions/api/identity/identity_get_auth_token_function.cc b/chrome/browser/extensions/api/identity/identity_get_auth_token_function.cc index a9449c4..24c2561d 100644 --- a/chrome/browser/extensions/api/identity/identity_get_auth_token_function.cc +++ b/chrome/browser/extensions/api/identity/identity_get_auth_token_function.cc
@@ -325,14 +325,12 @@ const std::set<std::string>& granted_scopes) { RecordFunctionResult(IdentityGetAuthTokenError(), remote_consent_approved_); - std::unique_ptr<base::Value> granted_scopes_value = - std::make_unique<base::Value>(base::Value::Type::LIST); + base::Value::List granted_scopes_value; for (const auto& scope : granted_scopes) - granted_scopes_value->Append(scope); + granted_scopes_value.Append(scope); - CompleteAsyncRun(TwoArguments( - base::Value(access_token), - base::Value::FromUniquePtrValue(std::move(granted_scopes_value)))); + CompleteAsyncRun(TwoArguments(base::Value(access_token), + base::Value(std::move(granted_scopes_value)))); } void IdentityGetAuthTokenFunction::CompleteFunctionWithError(
diff --git a/chrome/browser/extensions/api/language_settings_private/language_settings_private_api.cc b/chrome/browser/extensions/api/language_settings_private/language_settings_private_api.cc index 31c16c3..cac2da0 100644 --- a/chrome/browser/extensions/api/language_settings_private/language_settings_private_api.cc +++ b/chrome/browser/extensions/api/language_settings_private/language_settings_private_api.cc
@@ -19,7 +19,6 @@ #include "base/strings/string_split.h" #include "base/strings/string_util.h" #include "base/strings/utf_string_conversions.h" -#include "base/values.h" #include "build/build_config.h" #include "build/chromeos_buildflags.h" #include "chrome/browser/browser_process.h" @@ -205,8 +204,7 @@ } // namespace LanguageSettingsPrivateGetLanguageListFunction:: - LanguageSettingsPrivateGetLanguageListFunction() - : language_list_(std::make_unique<base::ListValue>()) {} + LanguageSettingsPrivateGetLanguageListFunction() = default; LanguageSettingsPrivateGetLanguageListFunction:: ~LanguageSettingsPrivateGetLanguageListFunction() = default; @@ -229,7 +227,7 @@ std::move(spellcheck_languages)); // Build the language list. - language_list_->ClearList(); + language_list_.clear(); #if BUILDFLAG(IS_CHROMEOS_ASH) const base::flat_set<std::string> allowed_ui_locales(GetAllowedLanguages( Profile::FromBrowserContext(browser_context())->GetPrefs())); @@ -259,7 +257,7 @@ } #endif // BUILDFLAG(IS_CHROMEOS_ASH) - language_list_->Append(base::Value::FromUniquePtrValue(language.ToValue())); + language_list_.Append(base::Value::FromUniquePtrValue(language.ToValue())); } #if BUILDFLAG(IS_CHROMEOS_ASH) @@ -271,7 +269,7 @@ language.code = ash::extension_ime_util::kArcImeLanguage; language.display_name = l10n_util::GetStringUTF8(IDS_SETTINGS_LANGUAGES_KEYBOARD_APPS); - language_list_->Append(base::Value::FromUniquePtrValue(language.ToValue())); + language_list_.Append(base::Value::FromUniquePtrValue(language.ToValue())); } #endif // BUILDFLAG(IS_CHROMEOS_ASH) @@ -295,16 +293,14 @@ } #endif // BUILDFLAG(IS_WIN) - return RespondNow( - OneArgument(base::Value::FromUniquePtrValue(std::move(language_list_)))); + return RespondNow(OneArgument(base::Value(std::move(language_list_)))); } #if BUILDFLAG(IS_WIN) void LanguageSettingsPrivateGetLanguageListFunction:: OnDictionariesInitialized() { UpdateSupportedPlatformDictionaries(); - Respond( - OneArgument(base::Value::FromUniquePtrValue(std::move(language_list_)))); + Respond(OneArgument(base::Value(std::move(language_list_)))); // Matches the AddRef in Run(). Release(); } @@ -313,7 +309,7 @@ UpdateSupportedPlatformDictionaries() { SpellcheckService* service = SpellcheckServiceFactory::GetForContext(browser_context()); - for (auto& language_val : language_list_->GetListDeprecated()) { + for (auto& language_val : language_list_) { if (service->UsesWindowsDictionary(*language_val.FindStringKey("code"))) { language_val.SetBoolKey("supportsSpellcheck", new bool(true)); }
diff --git a/chrome/browser/extensions/api/language_settings_private/language_settings_private_api.h b/chrome/browser/extensions/api/language_settings_private/language_settings_private_api.h index 6ed068d..b6c94ee 100644 --- a/chrome/browser/extensions/api/language_settings_private/language_settings_private_api.h +++ b/chrome/browser/extensions/api/language_settings_private/language_settings_private_api.h
@@ -5,6 +5,7 @@ #ifndef CHROME_BROWSER_EXTENSIONS_API_LANGUAGE_SETTINGS_PRIVATE_LANGUAGE_SETTINGS_PRIVATE_API_H_ #define CHROME_BROWSER_EXTENSIONS_API_LANGUAGE_SETTINGS_PRIVATE_LANGUAGE_SETTINGS_PRIVATE_API_H_ +#include "base/values.h" #include "build/build_config.h" #include "chrome/browser/spellchecker/spellcheck_custom_dictionary.h" #include "extensions/browser/extension_function.h" @@ -37,7 +38,7 @@ #endif // BUILDFLAG(IS_WIN) private: - std::unique_ptr<base::ListValue> language_list_; + base::Value::List language_list_; }; // Implements the languageSettingsPrivate.enableLanguage method.
diff --git a/chrome/browser/extensions/api/notifications/notifications_api.cc b/chrome/browser/extensions/api/notifications/notifications_api.cc index 91e1b7e8..c0ae468 100644 --- a/chrome/browser/extensions/api/notifications/notifications_api.cc +++ b/chrome/browser/extensions/api/notifications/notifications_api.cc
@@ -648,16 +648,13 @@ std::set<std::string> notification_ids = GetDisplayHelper()->GetNotificationIdsForExtension(extension_->url()); - std::unique_ptr<base::DictionaryValue> result(new base::DictionaryValue()); + base::Value::Dict result; - for (auto iter = notification_ids.begin(); iter != notification_ids.end(); - iter++) { - result->SetKey(StripScopeFromIdentifier(extension_->id(), *iter), - base::Value(true)); + for (const auto& entry : notification_ids) { + result.Set(StripScopeFromIdentifier(extension_->id(), entry), true); } - return RespondNow( - OneArgument(base::Value::FromUniquePtrValue(std::move(result)))); + return RespondNow(OneArgument(base::Value(std::move(result)))); } NotificationsGetPermissionLevelFunction::
diff --git a/chrome/browser/extensions/api/signed_in_devices/signed_in_devices_api.cc b/chrome/browser/extensions/api/signed_in_devices/signed_in_devices_api.cc index 7bc74f2..a42bd771 100644 --- a/chrome/browser/extensions/api/signed_in_devices/signed_in_devices_api.cc +++ b/chrome/browser/extensions/api/signed_in_devices/signed_in_devices_api.cc
@@ -127,24 +127,22 @@ if (is_local) { std::unique_ptr<DeviceInfo> device = GetLocalDeviceInfo(extension_id(), profile); - std::unique_ptr<base::ListValue> result(new base::ListValue()); + base::Value::List result; if (device.get()) { - result->Append(base::Value::FromUniquePtrValue(device->ToValue())); + result.Append(base::Value::FromUniquePtrValue(device->ToValue())); } - return RespondNow( - OneArgument(base::Value::FromUniquePtrValue(std::move(result)))); + return RespondNow(OneArgument(base::Value(std::move(result)))); } std::vector<std::unique_ptr<DeviceInfo>> devices = GetAllSignedInDevices(extension_id(), profile); - std::unique_ptr<base::ListValue> result(new base::ListValue()); + base::Value::List result; for (const std::unique_ptr<DeviceInfo>& device : devices) - result->Append(base::Value::FromUniquePtrValue(device->ToValue())); + result.Append(base::Value::FromUniquePtrValue(device->ToValue())); - return RespondNow( - OneArgument(base::Value::FromUniquePtrValue(std::move(result)))); + return RespondNow(OneArgument(base::Value(std::move(result)))); } } // namespace extensions
diff --git a/chrome/browser/extensions/api/system_private/system_private_api.cc b/chrome/browser/extensions/api/system_private/system_private_api.cc index abd18e42..6c5df053 100644 --- a/chrome/browser/extensions/api/system_private/system_private_api.cc +++ b/chrome/browser/extensions/api/system_private/system_private_api.cc
@@ -124,11 +124,10 @@ } #endif - std::unique_ptr<base::DictionaryValue> dict(new base::DictionaryValue()); - dict->SetStringKey(kStateKey, state); - dict->SetDoubleKey(kDownloadProgressKey, download_progress); - return RespondNow( - OneArgument(base::Value::FromUniquePtrValue(std::move(dict)))); + base::Value::Dict dict; + dict.Set(kStateKey, state); + dict.Set(kDownloadProgressKey, download_progress); + return RespondNow(OneArgument(base::Value(std::move(dict)))); } ExtensionFunction::ResponseAction SystemPrivateGetApiKeyFunction::Run() {
diff --git a/chrome/browser/extensions/api/tab_capture/tab_capture_api.cc b/chrome/browser/extensions/api/tab_capture/tab_capture_api.cc index 11e53dc2..85a7158 100644 --- a/chrome/browser/extensions/api/tab_capture/tab_capture_api.cc +++ b/chrome/browser/extensions/api/tab_capture/tab_capture_api.cc
@@ -216,19 +216,16 @@ // virtual audio/video capture devices and set up all the data flows. The // custom JS bindings can be found here: // chrome/renderer/resources/extensions/tab_capture_custom_bindings.js - std::unique_ptr<base::DictionaryValue> result(new base::DictionaryValue()); - result->MergeDictionary(params->options.ToValue().get()); - return RespondNow( - OneArgument(base::Value::FromUniquePtrValue(std::move(result)))); + base::Value result = params->options.ToValue()->Clone(); + return RespondNow(OneArgument(std::move(result))); } ExtensionFunction::ResponseAction TabCaptureGetCapturedTabsFunction::Run() { TabCaptureRegistry* registry = TabCaptureRegistry::Get(browser_context()); - std::unique_ptr<base::ListValue> list(new base::ListValue()); + base::Value::List list; if (registry) - registry->GetCapturedTabs(extension()->id(), list.get()); - return RespondNow( - OneArgument(base::Value::FromUniquePtrValue(std::move(list)))); + registry->GetCapturedTabs(extension()->id(), &list); + return RespondNow(OneArgument(base::Value(std::move(list)))); } ExtensionFunction::ResponseAction TabCaptureGetMediaStreamIdFunction::Run() {
diff --git a/chrome/browser/extensions/api/tab_capture/tab_capture_registry.cc b/chrome/browser/extensions/api/tab_capture/tab_capture_registry.cc index 4be5de0e..6db988e2 100644 --- a/chrome/browser/extensions/api/tab_capture/tab_capture_registry.cc +++ b/chrome/browser/extensions/api/tab_capture/tab_capture_registry.cc
@@ -145,18 +145,17 @@ void TabCaptureRegistry::GetCapturedTabs( const std::string& extension_id, - base::ListValue* list_of_capture_info) const { + base::Value::List* capture_info_list) const { DCHECK_CURRENTLY_ON(BrowserThread::UI); - DCHECK(list_of_capture_info); - list_of_capture_info->ClearList(); + DCHECK(capture_info_list); + capture_info_list->clear(); for (const std::unique_ptr<LiveRequest>& request : requests_) { if (request->is_anonymous() || !request->is_verified() || request->extension_id() != extension_id) continue; tab_capture::CaptureInfo info; request->GetCaptureInfo(&info); - list_of_capture_info->GetList().Append( - base::Value::FromUniquePtrValue(info.ToValue())); + capture_info_list->Append(base::Value::FromUniquePtrValue(info.ToValue())); } }
diff --git a/chrome/browser/extensions/api/tab_capture/tab_capture_registry.h b/chrome/browser/extensions/api/tab_capture/tab_capture_registry.h index 02a674c..8c08310 100644 --- a/chrome/browser/extensions/api/tab_capture/tab_capture_registry.h +++ b/chrome/browser/extensions/api/tab_capture/tab_capture_registry.h
@@ -11,6 +11,7 @@ #include "base/memory/raw_ptr.h" #include "base/scoped_observation.h" +#include "base/values.h" #include "chrome/browser/media/webrtc/media_capture_devices_dispatcher.h" #include "chrome/common/extensions/api/tab_capture.h" #include "content/public/browser/desktop_media_id.h" @@ -19,10 +20,6 @@ #include "extensions/browser/extension_registry.h" #include "extensions/browser/extension_registry_observer.h" -namespace base { -class ListValue; -} - namespace content { class BrowserContext; class WebContents; @@ -47,7 +44,7 @@ // List all pending, active and stopped capture requests. void GetCapturedTabs(const std::string& extension_id, - base::ListValue* list_of_capture_info) const; + base::Value::List* capture_info_list) const; // Add a tab capture request to the registry when a stream is requested // through the API and create a randomly generated device id after user
diff --git a/chrome/browser/extensions/api/tabs/tabs_api.cc b/chrome/browser/extensions/api/tabs/tabs_api.cc index 7379854..7d41dc1 100644 --- a/chrome/browser/extensions/api/tabs/tabs_api.cc +++ b/chrome/browser/extensions/api/tabs/tabs_api.cc
@@ -555,7 +555,7 @@ EXTENSION_FUNCTION_VALIDATE(params.get()); ApiParameterExtractor<windows::GetAll::Params> extractor(params.get()); - std::unique_ptr<base::ListValue> window_list(new base::ListValue()); + base::Value::List window_list; ExtensionTabUtil::PopulateTabBehavior populate_tab_behavior = extractor.populate_tabs() ? ExtensionTabUtil::kPopulateTabs : ExtensionTabUtil::kDontPopulateTabs; @@ -565,14 +565,13 @@ extractor.type_filters())) { continue; } - window_list->Append(base::Value::FromUniquePtrValue( + window_list.Append(base::Value::FromUniquePtrValue( ExtensionTabUtil::CreateWindowValueForExtension( *controller->GetBrowser(), extension(), populate_tab_behavior, source_context_type()))); } - return RespondNow( - OneArgument(base::Value::FromUniquePtrValue(std::move(window_list)))); + return RespondNow(OneArgument(base::Value(std::move(window_list)))); } bool WindowsCreateFunction::ShouldOpenIncognitoWindow( @@ -1126,7 +1125,7 @@ if (params->query_info.window_type != tabs::WINDOW_TYPE_NONE) window_type = tabs::ToString(params->query_info.window_type); - std::unique_ptr<base::ListValue> result(new base::ListValue()); + base::Value::List result; Profile* profile = Profile::FromBrowserContext(browser_context()); Browser* last_active_browser = chrome::FindAnyBrowser(profile, include_incognito_information()); @@ -1268,15 +1267,14 @@ continue; } - result->Append(base::Value::FromUniquePtrValue( + result.Append(base::Value::FromUniquePtrValue( CreateTabObjectHelper(web_contents, extension(), source_context_type(), tab_strip, i) ->ToValue())); } } - return RespondNow( - OneArgument(base::Value::FromUniquePtrValue(std::move(result)))); + return RespondNow(OneArgument(base::Value(std::move(result)))); } ExtensionFunction::ResponseAction TabsCreateFunction::Run() {
diff --git a/chrome/browser/flag-metadata.json b/chrome/browser/flag-metadata.json index 0d2b26b..c7cfa5d 100644 --- a/chrome/browser/flag-metadata.json +++ b/chrome/browser/flag-metadata.json
@@ -801,12 +801,12 @@ { "name": "chrome-whats-new-in-main-menu-new-badge", "owners": [ "rbpotter" ], - "expiry_milestone": 102 + "expiry_milestone": 106 }, { "name": "chrome-whats-new-ui", "owners": [ "rbpotter" ], - "expiry_milestone": 102 + "expiry_milestone": 106 }, { "name": "chrome-wide-echo-cancellation", @@ -5297,6 +5297,11 @@ "expiry_milestone": 101 }, { + "name": "shared-highlighting-refined-blocklist", + "owners": ["jeffreycohen", "chrome-with-friends-robots@google.com" ], + "expiry_milestone": 105 + }, + { "name": "shared-highlighting-v2", "owners": ["jeffreycohen", "kristipark", "cheickcisse@google.com", "chrome-with-friends-robots@google.com"], "expiry_milestone": 99
diff --git a/chrome/browser/flag_descriptions.cc b/chrome/browser/flag_descriptions.cc index 143496d..b2463be0 100644 --- a/chrome/browser/flag_descriptions.cc +++ b/chrome/browser/flag_descriptions.cc
@@ -2871,6 +2871,11 @@ const char kSharedHighlightingAmpDescription[] = "Enables Shared Highlighting for AMP Viwers."; +const char kSharedHighlightingRefinedBlocklistName[] = + "Shared Highlighting Blocklist Refinement"; +const char kSharedHighlightingRefinedBlocklistDescription[] = + "Narrow the Blocklist for enabling Shared Highlighting."; + const char kDraw1PredictedPoint12Ms[] = "1 point 12ms ahead."; const char kDraw2PredictedPoints6Ms[] = "2 points, each 6ms ahead."; const char kDraw1PredictedPoint6Ms[] = "1 point 6ms ahead.";
diff --git a/chrome/browser/flag_descriptions.h b/chrome/browser/flag_descriptions.h index a9698fb..b7aafdaf 100644 --- a/chrome/browser/flag_descriptions.h +++ b/chrome/browser/flag_descriptions.h
@@ -1616,6 +1616,9 @@ extern const char kSharedHighlightingAmpName[]; extern const char kSharedHighlightingAmpDescription[]; +extern const char kSharedHighlightingRefinedBlocklistName[]; +extern const char kSharedHighlightingRefinedBlocklistDescription[]; + extern const char kDraw1PredictedPoint12Ms[]; extern const char kDraw2PredictedPoints6Ms[]; extern const char kDraw1PredictedPoint6Ms[];
diff --git a/chrome/browser/headless/headless_mode_browsertest.cc b/chrome/browser/headless/headless_mode_browsertest.cc index 766e0db..349b546 100644 --- a/chrome/browser/headless/headless_mode_browsertest.cc +++ b/chrome/browser/headless/headless_mode_browsertest.cc
@@ -39,6 +39,10 @@ #include "ui/ozone/public/ozone_platform.h" #endif // BUILDFLAG(IS_LINUX) +#if BUILDFLAG(IS_WIN) +#include "ui/views/widget/desktop_aura/desktop_window_tree_host_win.h" +#endif // BUILDFLAG(IS_WIN) + namespace { const int kErrorResultCode = -1; } // namespace @@ -66,10 +70,23 @@ #endif // BUILDFLAG(IS_LINUX) #if BUILDFLAG(IS_WIN) +// A class to expose a protected method for testing purposes. +class DesktopWindowTreeHostWinWrapper : public views::DesktopWindowTreeHostWin { + public: + HWND GetHWND() const { return DesktopWindowTreeHostWin::GetHWND(); } +}; + IN_PROC_BROWSER_TEST_F(HeadlessModeBrowserTest, BrowserDesktopWindowHidden) { - // On Windows the Native Headless Chrome browser window exists but is - // hidden. - EXPECT_FALSE(browser()->window()->IsVisible()); + // On Windows, the Native Headless Chrome browser window exists and is + // visible, while the underlying platform window is hidden. + EXPECT_TRUE(browser()->window()->IsVisible()); + + DesktopWindowTreeHostWinWrapper* desktop_window_tree_host = + static_cast<DesktopWindowTreeHostWinWrapper*>( + browser()->window()->GetNativeWindow()->GetHost()); + DWORD native_window_style = + ::GetWindowLong(desktop_window_tree_host->GetHWND(), GWL_STYLE); + EXPECT_EQ(native_window_style & WS_VISIBLE, 0u); } #endif // BUILDFLAG(IS_WIN)
diff --git a/chrome/browser/history_clusters/BUILD.gn b/chrome/browser/history_clusters/BUILD.gn index d808382d..5cb596fc 100644 --- a/chrome/browser/history_clusters/BUILD.gn +++ b/chrome/browser/history_clusters/BUILD.gn
@@ -10,8 +10,11 @@ sources = [ "java/res/drawable/ic_journeys.xml", "java/res/layout/history_cluster_visit.xml", + "java/res/layout/history_clusters_activity_content.xml", "java/res/layout/history_clusters_bottom_sheet_content.xml", "java/res/layout/history_clusters_bottom_sheet_toolbar.xml", + "java/res/layout/history_clusters_toolbar.xml", + "java/res/menu/history_clusters_menu.xml", ] deps = [ "//components/browser_ui/widget/android:java_resources" ] } @@ -30,6 +33,8 @@ "java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersMediator.java", "java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersResult.java", "java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersTabHelper.java", + "java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersToolbar.java", + "java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersToolbarProperties.java", "java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersViewBinder.java", ]
diff --git a/chrome/browser/history_clusters/java/res/layout/history_clusters_activity_content.xml b/chrome/browser/history_clusters/java/res/layout/history_clusters_activity_content.xml new file mode 100644 index 0000000..24a3bfc --- /dev/null +++ b/chrome/browser/history_clusters/java/res/layout/history_clusters_activity_content.xml
@@ -0,0 +1,10 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Copyright 2022 The Chromium Authors. All rights reserved. + Use of this source code is governed by a BSD-style license that can be + found in the LICENSE file. --> + +<org.chromium.components.browser_ui.widget.selectable_list.SelectableListLayout + xmlns:android="http://schemas.android.com/apk/res/android" + android:id="@+id/selectable_list" + android:layout_width="match_parent" + android:layout_height="match_parent" /> \ No newline at end of file
diff --git a/chrome/browser/history_clusters/java/res/layout/history_clusters_toolbar.xml b/chrome/browser/history_clusters/java/res/layout/history_clusters_toolbar.xml new file mode 100644 index 0000000..1d73001 --- /dev/null +++ b/chrome/browser/history_clusters/java/res/layout/history_clusters_toolbar.xml
@@ -0,0 +1,12 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Copyright 2022 The Chromium Authors. All rights reserved. + Use of this source code is governed by a BSD-style license that can be + found in the LICENSE file. --> + +<org.chromium.chrome.browser.history_clusters.HistoryClustersToolbar + xmlns:android="http://schemas.android.com/apk/res/android" + android:layout_width="match_parent" + android:layout_height="match_parent" + android:paddingStart="0dp" + android:paddingEnd="0dp" + style="@style/ModernToolbar"/> \ No newline at end of file
diff --git a/chrome/browser/history_clusters/java/res/menu/history_clusters_menu.xml b/chrome/browser/history_clusters/java/res/menu/history_clusters_menu.xml new file mode 100644 index 0000000..01375bb --- /dev/null +++ b/chrome/browser/history_clusters/java/res/menu/history_clusters_menu.xml
@@ -0,0 +1,21 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- Copyright 2022 The Chromium Authors. All rights reserved. + Use of this source code is governed by a BSD-style license that can be + found in the LICENSE file. --> + +<menu xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:app="http://schemas.android.com/apk/res-auto" > + <group android:id="@+id/normal_menu_group" > + <item + android:id="@+id/search_menu_id" + android:icon="@drawable/ic_search" + android:title="@string/search" + android:visible="false" + app:showAsAction="ifRoom" + app:iconTint="@color/default_icon_color_secondary_tint_list" /> + </group> + <group + android:id="@+id/selection_mode_menu_group" + android:visible="false" > + </group> +</menu> \ No newline at end of file
diff --git a/chrome/browser/history_clusters/java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersCoordinator.java b/chrome/browser/history_clusters/java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersCoordinator.java index 405d5b4..90493af5 100644 --- a/chrome/browser/history_clusters/java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersCoordinator.java +++ b/chrome/browser/history_clusters/java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersCoordinator.java
@@ -7,18 +7,23 @@ import android.content.Context; import android.content.Intent; import android.view.LayoutInflater; +import android.view.MenuItem; import android.view.View; import android.view.ViewGroup; import androidx.annotation.NonNull; +import androidx.appcompat.widget.Toolbar.OnMenuItemClickListener; import androidx.recyclerview.widget.LinearLayoutManager; import androidx.recyclerview.widget.RecyclerView; import org.chromium.base.supplier.Supplier; import org.chromium.chrome.browser.history_clusters.HistoryClustersItemProperties.ItemType; +import org.chromium.chrome.browser.history_clusters.HistoryClustersToolbarProperties.QueryState; import org.chromium.chrome.browser.profiles.Profile; import org.chromium.components.browser_ui.bottomsheet.BottomSheetController; import org.chromium.components.browser_ui.widget.selectable_list.SelectableItemView; +import org.chromium.components.browser_ui.widget.selectable_list.SelectableListLayout; +import org.chromium.components.browser_ui.widget.selectable_list.SelectionDelegate; import org.chromium.components.favicon.LargeIconBridge; import org.chromium.ui.modelutil.MVCListAdapter.ModelList; import org.chromium.ui.modelutil.PropertyModel; @@ -29,14 +34,20 @@ * Root component for the HistoryClusters UI component, which displays lists of related history * visits grouped into clusters. */ -public class HistoryClustersCoordinator { +public class HistoryClustersCoordinator implements OnMenuItemClickListener { private final HistoryClustersMediator mMediator; private final ModelList mModelList; private final HistoryClustersBottomSheetContent mBottomSheetContent; private SimpleRecyclerViewAdapter mAdapter; private final Context mContext; private boolean mBottomSheetInflated; + private boolean mActivityViewInflated; private final PropertyModel mBottomSheetToolbarModel; + private final PropertyModel mToolbarModel; + private View mActivityContentView; + private HistoryClustersToolbar mToolbar; + private SelectionDelegate mSelectionDelegate; + private SelectableListLayout mSelectableListLayout; /** * Construct a new HistoryClustersCoordinator. @@ -49,16 +60,20 @@ * We can't directly set the class ourselves without creating a circular dependency. */ public HistoryClustersCoordinator(@NonNull Profile profile, @NonNull Context context, - @NonNull BottomSheetController bottomSheetController, + BottomSheetController bottomSheetController, Supplier<Intent> historyActivityIntentFactory) { mContext = context; mModelList = new ModelList(); mBottomSheetContent = new HistoryClustersBottomSheetContent(); mBottomSheetToolbarModel = new PropertyModel(HistoryClustersBottomSheetToolbarProperties.ALL_KEYS); + mToolbarModel = new PropertyModel.Builder(HistoryClustersToolbarProperties.ALL_KEYS) + .with(HistoryClustersToolbarProperties.QUERY_STATE, + QueryState.forQueryless()) + .build(); mMediator = new HistoryClustersMediator(HistoryClustersBridge.getForProfile(profile), new LargeIconBridge(profile), context, context.getResources(), mModelList, - mBottomSheetToolbarModel, bottomSheetController, mBottomSheetContent, + mBottomSheetToolbarModel, mToolbarModel, bottomSheetController, mBottomSheetContent, historyActivityIntentFactory); } @@ -66,6 +81,19 @@ mMediator.destroy(); } + public void setQuery(String query) { + mMediator.startSearch(query); + } + + /** Gets the root view for a "full activity" presentation of the user's history clusters. */ + public View getActivityContentView() { + if (!mActivityViewInflated) { + inflateActivityView(); + } + + return mActivityContentView; + } + /** Shows the bottom sheet, populating it with clusters matching the given query. */ public void showBottomSheet(String query) { if (!mBottomSheetInflated) { @@ -74,6 +102,40 @@ mMediator.showBottomSheet(query); } + void inflateActivityView() { + mAdapter = new SimpleRecyclerViewAdapter(mModelList); + mAdapter.registerType( + ItemType.VISIT, this::buildVisitView, HistoryClustersViewBinder::bindVisitView); + + LayoutInflater layoutInflater = LayoutInflater.from(mContext); + mActivityContentView = + layoutInflater.inflate(R.layout.history_clusters_activity_content, null); + + mSelectableListLayout = mActivityContentView.findViewById(R.id.selectable_list); + RecyclerView recyclerView = mSelectableListLayout.initializeRecyclerView(mAdapter); + + recyclerView.setLayoutManager(new LinearLayoutManager( + recyclerView.getContext(), LinearLayoutManager.VERTICAL, false)); + recyclerView.setItemAnimator(null); + + mSelectionDelegate = new SelectionDelegate<>(); + mToolbar = (HistoryClustersToolbar) mSelectableListLayout.initializeToolbar( + R.layout.history_clusters_toolbar, mSelectionDelegate, + R.string.history_clusters_journeys_tab_label, R.id.normal_menu_group, + R.id.selection_mode_menu_group, this, true); + mToolbar.initializeSearchView( + mMediator, R.string.history_clusters_search_your_journeys, R.id.search_menu_id); + mSelectableListLayout.configureWideDisplayStyle(); + mToolbar.setSearchEnabled(true); + + PropertyModelChangeProcessor.create( + mToolbarModel, mToolbar, HistoryClustersViewBinder::bindToolbar); + PropertyModelChangeProcessor.create( + mToolbarModel, mSelectableListLayout, HistoryClustersViewBinder::bindListLayout); + + mActivityViewInflated = true; + } + void inflateBottomSheet() { mAdapter = new SimpleRecyclerViewAdapter(mModelList); mAdapter.registerType( @@ -105,4 +167,13 @@ .inflate(R.layout.history_cluster_visit, parent, false); return itemView; } + + @Override + public boolean onMenuItemClick(MenuItem menuItem) { + if (menuItem.getItemId() == R.id.search_menu_id) { + mMediator.startSearch(""); + return true; + } + return false; + } } \ No newline at end of file
diff --git a/chrome/browser/history_clusters/java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersMediator.java b/chrome/browser/history_clusters/java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersMediator.java index ab92a94..1c45c4f 100644 --- a/chrome/browser/history_clusters/java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersMediator.java +++ b/chrome/browser/history_clusters/java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersMediator.java
@@ -16,23 +16,26 @@ import org.chromium.base.Promise; import org.chromium.base.supplier.Supplier; import org.chromium.chrome.browser.history_clusters.HistoryClustersItemProperties.ItemType; +import org.chromium.chrome.browser.history_clusters.HistoryClustersToolbarProperties.QueryState; import org.chromium.chrome.browser.ui.favicon.FaviconUtils; import org.chromium.components.browser_ui.bottomsheet.BottomSheetContent; import org.chromium.components.browser_ui.bottomsheet.BottomSheetController; import org.chromium.components.browser_ui.bottomsheet.BottomSheetController.StateChangeReason; import org.chromium.components.browser_ui.bottomsheet.EmptyBottomSheetObserver; import org.chromium.components.browser_ui.widget.RoundedIconGenerator; +import org.chromium.components.browser_ui.widget.selectable_list.SelectableListToolbar.SearchDelegate; import org.chromium.components.favicon.LargeIconBridge; import org.chromium.ui.modelutil.MVCListAdapter.ListItem; import org.chromium.ui.modelutil.MVCListAdapter.ModelList; import org.chromium.ui.modelutil.PropertyModel; -class HistoryClustersMediator extends EmptyBottomSheetObserver { +class HistoryClustersMediator extends EmptyBottomSheetObserver implements SearchDelegate { private final HistoryClustersBridge mHistoryClustersBridge; private final Context mContext; private final Resources mResources; private final ModelList mModelList; private final PropertyModel mBottomSheetToolbarModel; + private final PropertyModel mToolbarModel; private final RoundedIconGenerator mIconGenerator; private final LargeIconBridge mLargeIconBridge; private final int mFaviconSize; @@ -49,6 +52,8 @@ * @param resources Android resources object from which strings, colors etc. should be fetched. * @param modelList Model list to which fetched cluster data should be pushed to. * @param bottomSheetToolbarModel Model for properties affecting the bottom sheet toolbar. + * @param toolbarModel Model for properties affecting the "full page" toolbar shown in the + * history activity. * @param bottomSheetController Controller for interacting with the bottom sheet system, e.g. to * request to show our content. * @param bottomSheetContent {@link BottomSheetContent} instance that tells the BottomSheet @@ -57,6 +62,7 @@ HistoryClustersMediator(@NonNull HistoryClustersBridge historyClustersBridge, LargeIconBridge largeIconBridge, @NonNull Context context, @NonNull Resources resources, @NonNull ModelList modelList, @NonNull PropertyModel bottomSheetToolbarModel, + @NonNull PropertyModel toolbarModel, @NonNull BottomSheetController bottomSheetController, @NonNull BottomSheetContent bottomSheetContent, Supplier<Intent> historyActivityIntentFactory) { @@ -66,6 +72,7 @@ mContext = context; mResources = resources; mBottomSheetToolbarModel = bottomSheetToolbarModel; + mToolbarModel = toolbarModel; mBottomSheetController = bottomSheetController; mBottomSheetContent = bottomSheetContent; mHistoryActivityIntentFactory = historyActivityIntentFactory; @@ -80,10 +87,27 @@ mBottomSheetController.removeObserver(this); } + // SearchDelegate implementation. + @Override + public void onSearchTextChanged(String query) { + mModelList.clear(); + query(query); + } + + @Override + public void onEndSearch() { + mModelList.clear(); + query(""); + } + void destroy() { mLargeIconBridge.destroy(); } + void startSearch(String query) { + mToolbarModel.set(HistoryClustersToolbarProperties.QUERY_STATE, QueryState.forQuery(query)); + } + void query(String query) { mPromise = mHistoryClustersBridge.queryClusters(query); mPromise.then(this::queryComplete);
diff --git a/chrome/browser/history_clusters/java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersToolbar.java b/chrome/browser/history_clusters/java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersToolbar.java new file mode 100644 index 0000000..a01d8b4 --- /dev/null +++ b/chrome/browser/history_clusters/java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersToolbar.java
@@ -0,0 +1,39 @@ +// Copyright 2022 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +package org.chromium.chrome.browser.history_clusters; + +import android.content.Context; +import android.util.AttributeSet; +import android.widget.EditText; + +import org.chromium.components.browser_ui.widget.selectable_list.SelectableListToolbar; +import org.chromium.ui.modelutil.PropertyModel; + +/** + * Toolbar for controlling the list of history clusters in the Journeys UI. + */ +class HistoryClustersToolbar extends SelectableListToolbar<PropertyModel> { + private EditText mSearchText; + + /** + * Constructor for inflating from XML. + */ + public HistoryClustersToolbar(Context context, AttributeSet attrs) { + super(context, attrs); + inflateMenu(R.menu.history_clusters_menu); + } + + @Override + public void initializeSearchView( + SearchDelegate searchDelegate, int hintStringResId, int searchMenuItemId) { + super.initializeSearchView(searchDelegate, hintStringResId, searchMenuItemId); + mSearchText = findViewById(R.id.search_text); + } + + void setSearchText(String text) { + mSearchText.setText(text); + mSearchText.setSelection(text.length()); + } +}
diff --git a/chrome/browser/history_clusters/java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersToolbarProperties.java b/chrome/browser/history_clusters/java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersToolbarProperties.java new file mode 100644 index 0000000..4354abe --- /dev/null +++ b/chrome/browser/history_clusters/java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersToolbarProperties.java
@@ -0,0 +1,43 @@ +// Copyright 2022 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +package org.chromium.chrome.browser.history_clusters; + +import androidx.annotation.NonNull; + +import org.chromium.ui.modelutil.PropertyKey; +import org.chromium.ui.modelutil.PropertyModel.WritableObjectPropertyKey; + +class HistoryClustersToolbarProperties { + static class QueryState { + private final String mQuery; + private final boolean mIsSearching; + + static QueryState forQuery(@NonNull String query) { + return new QueryState(query, true); + } + + static QueryState forQueryless() { + return new QueryState(null, false); + } + + private QueryState(String query, boolean isSearching) { + mQuery = query; + mIsSearching = isSearching; + } + + String getQuery() { + return mQuery; + } + + boolean isSearching() { + return mIsSearching; + } + } + + static final WritableObjectPropertyKey<QueryState> QUERY_STATE = + new WritableObjectPropertyKey<>("query state"); + + static final PropertyKey[] ALL_KEYS = {QUERY_STATE}; +}
diff --git a/chrome/browser/history_clusters/java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersViewBinder.java b/chrome/browser/history_clusters/java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersViewBinder.java index 9ca864dd..c5e4e933 100644 --- a/chrome/browser/history_clusters/java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersViewBinder.java +++ b/chrome/browser/history_clusters/java/src/org/chromium/chrome/browser/history_clusters/HistoryClustersViewBinder.java
@@ -7,6 +7,8 @@ import android.view.View; import android.widget.TextView; +import org.chromium.chrome.browser.history_clusters.HistoryClustersToolbarProperties.QueryState; +import org.chromium.components.browser_ui.widget.selectable_list.SelectableListLayout; import org.chromium.ui.modelutil.PropertyKey; import org.chromium.ui.modelutil.PropertyModel; import org.chromium.ui.widget.ChromeImageButton; @@ -35,4 +37,29 @@ textView.setText(model.get(HistoryClustersBottomSheetToolbarProperties.QUERY_TEXT)); } } + + public static void bindToolbar( + PropertyModel model, HistoryClustersToolbar toolbar, PropertyKey key) { + if (key == HistoryClustersToolbarProperties.QUERY_STATE) { + QueryState queryState = model.get(HistoryClustersToolbarProperties.QUERY_STATE); + if (queryState.isSearching()) { + toolbar.showSearchView(); + toolbar.setSearchText(queryState.getQuery()); + } else { + toolbar.hideSearchView(); + } + } + } + + public static void bindListLayout( + PropertyModel model, SelectableListLayout listLayout, PropertyKey key) { + if (key == HistoryClustersToolbarProperties.QUERY_STATE) { + QueryState queryState = model.get(HistoryClustersToolbarProperties.QUERY_STATE); + if (queryState.isSearching()) { + listLayout.onStartSearch(""); + } else { + listLayout.onEndSearch(); + } + } + } } \ No newline at end of file
diff --git a/chrome/browser/resources/chromeos/accessibility/chromevox/background/panel/panel_background.js b/chrome/browser/resources/chromeos/accessibility/chromevox/background/panel/panel_background.js index d01396b..eabec89 100644 --- a/chrome/browser/resources/chromeos/accessibility/chromevox/background/panel/panel_background.js +++ b/chrome/browser/resources/chromeos/accessibility/chromevox/background/panel/panel_background.js
@@ -14,6 +14,8 @@ constructor() { /** @private {ISearch} */ this.iSearch_; + /** @private {chrome.automation.AutomationNode} */ + this.nodeForActions_; } static init() { @@ -21,6 +23,7 @@ throw 'Trying to create two copies of singleton PanelBackground'; } PanelBackground.instance = new PanelBackground(); + PanelBackground.stateObserver_ = new PanelStateObserver(); BridgeHelper.registerHandler( BridgeTarget.PANEL_BACKGROUND, BridgeAction.CREATE_NEW_I_SEARCH, @@ -29,11 +32,27 @@ BridgeTarget.PANEL_BACKGROUND, BridgeAction.DESTROY_I_SEARCH, () => PanelBackground.instance.destroyISearch_()); BridgeHelper.registerHandler( + BridgeTarget.PANEL_BACKGROUND, + BridgeAction.GET_ACTIONS_FOR_CURRENT_NODE, + () => PanelBackground.instance.getActionsForCurrentNode_()); + BridgeHelper.registerHandler( BridgeTarget.PANEL_BACKGROUND, BridgeAction.INCREMENTAL_SEARCH, ({searchStr, dir, opt_nextObject}) => PanelBackground.instance.incrementalSearch_( searchStr, dir, opt_nextObject)); BridgeHelper.registerHandler( + BridgeTarget.PANEL_BACKGROUND, + BridgeAction.PERFORM_CUSTOM_ACTION_ON_CURRENT_NODE, + (actionId) => + PanelBackground.instance.performCustomActionOnCurrentNode_( + actionId)); + BridgeHelper.registerHandler( + BridgeTarget.PANEL_BACKGROUND, + BridgeAction.PERFORM_STANDARD_ACTION_ON_CURRENT_NODE, + (action) => + PanelBackground.instance.performStandardActionOnCurrentNode_( + action)); + BridgeHelper.registerHandler( BridgeTarget.PANEL_BACKGROUND, BridgeAction.SET_RANGE_TO_I_SEARCH_NODE, () => PanelBackground.instance.setRangeToISearchNode_()); BridgeHelper.registerHandler( @@ -64,6 +83,31 @@ } /** + * @return {{ + * standardActions: !Array<!chrome.automation.ActionType>, + * customActions: !Array<!chrome.automation.CustomAction> + * }} + * @private + */ + getActionsForCurrentNode_() { + this.nodeForActions_ = ChromeVoxState.instance.currentRange.start; + const result = { + standardActions: [], + customActions: [], + }; + if (!this.nodeForActions_) { + return result; + } + if (this.nodeForActions_.standardActions) { + result.standardActions = this.nodeForActions_.standardActions; + } + if (this.nodeForActions_.customActions) { + result.customActions = this.nodeForActions_.customActions; + } + return result; + } + + /** * @param {string} searchStr * @param {constants.Dir} dir * @param {boolean=} opt_nextObject @@ -80,6 +124,26 @@ } /** + * @param {number} actionId + * @private + */ + performCustomActionOnCurrentNode_(actionId) { + if (this.nodeForActions_) { + this.nodeForActions_.performCustomAction(actionId); + } + } + + /** + * @param {!chrome.automation.ActionType} action + * @private + */ + performStandardActionOnCurrentNode_(action) { + if (this.nodeForActions_) { + this.nodeForActions_.performStandardAction(action); + } + } + + /** * Sets the current ChromeVox focus to the current ISearch node. * @private */ @@ -167,3 +231,14 @@ /** @type {PanelBackground} */ PanelBackground.instance; + +/** @private {PanelStateObserver} */ +PanelBackground.stateObserver_; + +/** @implements {ChromeVoxStateObserver} */ +class PanelStateObserver { + /** @override */ + onCurrentRangeChanged(range, opt_fromEditing) { + PanelBridge.onCurrentRangeChanged(); + } +}
diff --git a/chrome/browser/resources/chromeos/accessibility/chromevox/background/prefs.js b/chrome/browser/resources/chromeos/accessibility/chromevox/background/prefs.js index fe8b7eab..f6e0638 100644 --- a/chrome/browser/resources/chromeos/accessibility/chromevox/background/prefs.js +++ b/chrome/browser/resources/chromeos/accessibility/chromevox/background/prefs.js
@@ -58,7 +58,8 @@ /** * Get the prefs (not including keys). - * @return {Object} A map of all prefs except the key map from localStorage. + * @return {Object<string, string>} A map of all prefs except the key map from + * localStorage. */ getPrefs() { const prefs = {};
diff --git a/chrome/browser/resources/chromeos/accessibility/chromevox/common/background_bridge.js b/chrome/browser/resources/chromeos/accessibility/chromevox/common/background_bridge.js index 8adfc6b9..6017e285 100644 --- a/chrome/browser/resources/chromeos/accessibility/chromevox/common/background_bridge.js +++ b/chrome/browser/resources/chromeos/accessibility/chromevox/common/background_bridge.js
@@ -26,7 +26,7 @@ /** * @param {string} brailleTable The table for this translator to use. - * @return {!Promise} + * @return {!Promise<boolean>} */ async refreshBrailleTable(brailleTable) { return BridgeHelper.sendMessage( @@ -48,8 +48,8 @@ BackgroundBridge.ChromeVoxPrefs = { /** * Get the prefs (not including keys). - * @return {!Promise<Object>} A map of all prefs except the key map from - * localStorage. + * @return {!Promise<Object<string, string>>} A map of all prefs except the + * key map from localStorage. */ async getPrefs() { return BridgeHelper.sendMessage( @@ -85,7 +85,7 @@ * Method that updates the punctuation echo level, and also persists setting * to local storage. * @param {number} punctuationEcho The index of the desired punctuation echo - * level in AbstractTts.PUNCTUATION_ECHOES. + * level in AbstractTts.PUNCTUATION_ECHOES. * @return {!Promise} */ async updatePunctuationEcho(punctuationEcho) { @@ -160,6 +160,18 @@ }, /** + * @return {!Promise<{ + * standardActions: !Array<!chrome.automation.ActionType>, + * customActions: !Array<!chrome.automation.CustomAction> + * }>} + */ + async getActionsForCurrentNode() { + return BridgeHelper.sendMessage( + BridgeTarget.PANEL_BACKGROUND, + BridgeAction.GET_ACTIONS_FOR_CURRENT_NODE); + }, + + /** * @param {string} searchStr * @param {constants.Dir} dir * @param {boolean=} opt_nextObject @@ -172,6 +184,26 @@ }, /** + * @param {number} actionId + * @return {!Promise} + */ + async performCustomActionOnCurrentNode(actionId) { + return BridgeHelper.sendMessage( + BridgeTarget.PANEL_BACKGROUND, + BridgeAction.PERFORM_CUSTOM_ACTION_ON_CURRENT_NODE, actionId); + }, + + /** + * @param {!chrome.automation.ActionType} action + * @return {!Promise} + */ + async performStandardActionOnCurrentNode(action) { + return BridgeHelper.sendMessage( + BridgeTarget.PANEL_BACKGROUND, + BridgeAction.PERFORM_STANDARD_ACTION_ON_CURRENT_NODE, action); + }, + + /** * Sets the current ChromeVox focus to the current ISearch node. * @return {!Promise} */
diff --git a/chrome/browser/resources/chromeos/accessibility/chromevox/common/bridge_constants.js b/chrome/browser/resources/chromeos/accessibility/chromevox/common/bridge_constants.js index 3280aba..31de2a4 100644 --- a/chrome/browser/resources/chromeos/accessibility/chromevox/common/bridge_constants.js +++ b/chrome/browser/resources/chromeos/accessibility/chromevox/common/bridge_constants.js
@@ -20,6 +20,7 @@ EVENT_SOURCE_STATE: 'EventSourceState', LOG_STORE: 'LogStore', PANEL_BACKGROUND: 'PanelBackground', + PANEL: 'Panel', }; /** @@ -32,10 +33,14 @@ CREATE_NEW_I_SEARCH: 'createNewISearch', DESTROY_I_SEARCH: 'destroyISearch', GET: 'get', + GET_ACTIONS_FOR_CURRENT_NODE: 'getActionsForCurrentNode', GET_LOGS: 'getLogs', GET_PREFS: 'getPrefs', INCREMENTAL_SEARCH: 'incrementalSearch', ON_COMMAND: 'onCommand', + ON_CURRENT_RANGE_CHANGED: 'onCurrentRangeChanged', + PERFORM_CUSTOM_ACTION_ON_CURRENT_NODE: 'performCustomActionOnCurrentNode', + PERFORM_STANDARD_ACTION_ON_CURRENT_NODE: 'performStandardActionOnCurrentNode', REFRESH_BRAILLE_TABLE: 'refreshBrailleTable', SET_LOGGING_PREFS: 'setLoggingPrefs', SET_PREF: 'setPref',
diff --git a/chrome/browser/resources/chromeos/accessibility/chromevox/common/panel_bridge.js b/chrome/browser/resources/chromeos/accessibility/chromevox/common/panel_bridge.js new file mode 100644 index 0000000..2953828b --- /dev/null +++ b/chrome/browser/resources/chromeos/accessibility/chromevox/common/panel_bridge.js
@@ -0,0 +1,17 @@ +// Copyright 2022 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +/** + * @fileoverview Provides an interface for other renderers to communicate with + * the ChromeVox panel. + */ + +goog.provide('PanelBridge'); + +PanelBridge = { + async onCurrentRangeChanged() { + return BridgeHelper.sendMessage( + BridgeTarget.PANEL, BridgeAction.ON_CURRENT_RANGE_CHANGED); + }, +};
diff --git a/chrome/browser/resources/chromeos/accessibility/chromevox/panel/panel.js b/chrome/browser/resources/chromeos/accessibility/chromevox/panel/panel.js index 28b20eb..9dad025 100644 --- a/chrome/browser/resources/chromeos/accessibility/chromevox/panel/panel.js +++ b/chrome/browser/resources/chromeos/accessibility/chromevox/panel/panel.js
@@ -503,29 +503,28 @@ Panel.addNodeMenu(menuData, node, isActivatedMenu); } - if (node && node.standardActions) { - for (let i = 0; i < node.standardActions.length; i++) { - const standardAction = node.standardActions[i]; - const actionMsg = Panel.ACTION_TO_MSG_ID[standardAction]; - if (!actionMsg) { - continue; - } - const actionDesc = Msgs.getMsg(actionMsg); - actionsMenu.addMenuItem( - actionDesc, '' /* menuItemShortcut */, '' /* menuItemBraille */, - '' /* gesture */, - node.performStandardAction.bind(node, standardAction)); + const actions = + await BackgroundBridge.PanelBackground.getActionsForCurrentNode(); + for (const standardAction of actions.standardActions) { + const actionMsg = Panel.ACTION_TO_MSG_ID[standardAction]; + if (!actionMsg) { + continue; } + + const actionDesc = Msgs.getMsg(actionMsg); + actionsMenu.addMenuItem( + actionDesc, '' /* menuItemShortcut */, '' /* menuItemBraille */, + '' /* gesture */, + () => BackgroundBridge.PanelBackground + .performStandardActionOnCurrentNode(standardAction)); } - if (node && node.customActions) { - for (let i = 0; i < node.customActions.length; i++) { - const customAction = node.customActions[i]; - actionsMenu.addMenuItem( - customAction.description, '' /* menuItemShortcut */, - '' /* menuItemBraille */, '' /* gesture */, - node.performCustomAction.bind(node, customAction.id)); - } + for (const customAction of actions.customActions) { + actionsMenu.addMenuItem( + customAction.description, '' /* menuItemShortcut */, + '' /* menuItemBraille */, '' /* gesture */, + () => BackgroundBridge.PanelBackground + .performCustomActionOnCurrentNode(customAction.id)); } // Activate either the specified menu or the search menu. @@ -1181,9 +1180,6 @@ Panel.onCloseTutorial(); chrome.tabs.create({url}); }); - - Panel.observer_ = new Panel.PanelStateObserver(); - chromeVoxState.addObserver(Panel.observer_); } /** @@ -1239,27 +1235,15 @@ } Panel.searchMenu.activateItem(0); } -} -/** - * An observer that reacts to ChromeVox range changes. - * @implements {ChromeVoxStateObserver} - */ -Panel.PanelStateObserver = class { - constructor() {} - - /** - * @param {cursors.Range} range The new range. - * @param {boolean=} opt_fromEditing - */ - onCurrentRangeChanged(range, opt_fromEditing) { + static onCurrentRangeChanged() { if (Panel.mode_ === PanelMode.FULLSCREEN_TUTORIAL) { if (Panel.tutorial && Panel.tutorial.restartNudges) { Panel.tutorial.restartNudges(); } } } -}; +} Panel.ACTION_TO_MSG_ID = { decrement: 'action_decrement_description', @@ -1271,16 +1255,9 @@ }; -/** - * @private {string} - */ +/** @private {string} */ Panel.lastMenu_ = ''; -/** - * @private {ChromeVoxStateObserver} - */ -Panel.observer_ = null; - window.addEventListener('load', function() { Panel.init(); @@ -1314,3 +1291,7 @@ function $(id) { return document.getElementById(id); } + +BridgeHelper.registerHandler( + BridgeTarget.PANEL, BridgeAction.ON_CURRENT_RANGE_CHANGED, + () => Panel.onCurrentRangeChanged());
diff --git a/chrome/browser/resources/feed/BUILD.gn b/chrome/browser/resources/feed/BUILD.gn index 1d17dd4db..66501bc5 100644 --- a/chrome/browser/resources/feed/BUILD.gn +++ b/chrome/browser/resources/feed/BUILD.gn
@@ -57,7 +57,6 @@ root_dir = "$target_gen_dir/$preprocess_folder" out_dir = "$target_gen_dir/tsc" tsconfig_base = "tsconfig_base.json" - composite = true in_files = [ "feed.ts", "feed_side_panel_handler.ts",
diff --git a/chrome/browser/resources/feed/feed_side_panel_handler.ts b/chrome/browser/resources/feed/feed_side_panel_handler.ts index 83546d7..00519e2 100644 --- a/chrome/browser/resources/feed/feed_side_panel_handler.ts +++ b/chrome/browser/resources/feed/feed_side_panel_handler.ts
@@ -1,3 +1,6 @@ +// Copyright 2022 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. import {FeedSidePanelCallbackRouter, FeedSidePanelHandlerFactory, FeedSidePanelHandlerRemote} from './feed.mojom-webui.js';
diff --git a/chrome/browser/resources/settings/languages_page/languages_page.html b/chrome/browser/resources/settings/languages_page/languages_page.html index 3ab0c9f..919f38f 100644 --- a/chrome/browser/resources/settings/languages_page/languages_page.html +++ b/chrome/browser/resources/settings/languages_page/languages_page.html
@@ -1,8 +1,4 @@ <style include="cr-shared-style settings-shared action-link iron-flex"> - #languagesCollapse .list-item.selected { - min-height: var(--settings-row-two-line-min-height); - } - .name-with-error-list { padding: 14px 0; } @@ -72,24 +68,11 @@ </cr-link-row> </template> <template is="dom-if" if="[[!enableDesktopRestructuredLanguageSettings_]]"> - <cr-expand-button - aria-label="$i18n{languagesExpandA11yLabel}" - class="cr-row first" - expanded="{{languagesOpened_}}"> - <div>$i18n{languagesListTitle}</div> -<if expr="is_win"> - <div class="secondary" id="languageSectionSecondaryText"> - [[getProspectiveUILanguageName_(languages.prospectiveUILanguage)]] - </div> -</if> - </cr-expand-button> - <iron-collapse id="languagesCollapse" opened="[[languagesOpened_]]"> - <settings-languages-subpage - languages="{{languages}}" - prefs="{{prefs}}" - language-helper="{{languageHelper}}"> - </settings-languages-subpage> - </iron-collapse> + <settings-languages-subpage + languages="{{languages}}" + prefs="{{prefs}}" + language-helper="{{languageHelper}}"> + </settings-languages-subpage> </template> <settings-toggle-button id="enableSpellcheckingToggle"
diff --git a/chrome/browser/resources/settings/languages_page/languages_page.ts b/chrome/browser/resources/settings/languages_page/languages_page.ts index 41c2547..0148637 100644 --- a/chrome/browser/resources/settings/languages_page/languages_page.ts +++ b/chrome/browser/resources/settings/languages_page/languages_page.ts
@@ -8,7 +8,6 @@ */ import 'chrome://resources/cr_elements/cr_button/cr_button.m.js'; -import 'chrome://resources/cr_elements/cr_expand_button/cr_expand_button.m.js'; import 'chrome://resources/cr_elements/cr_link_row/cr_link_row.js'; import 'chrome://resources/cr_elements/cr_toggle/cr_toggle.m.js'; import 'chrome://resources/cr_elements/icons.m.js'; @@ -17,7 +16,10 @@ import 'chrome://resources/cr_elements/shared_vars_css.m.js'; import 'chrome://resources/js/action_link.js'; import 'chrome://resources/cr_elements/action_link_css.m.js'; +// <if expr="_google_chrome or not is_macosx"> import 'chrome://resources/polymer/v3_0/iron-collapse/iron-collapse.js'; +// </if> + import 'chrome://resources/polymer/v3_0/iron-flex-layout/iron-flex-layout-classes.js'; import 'chrome://resources/polymer/v3_0/iron-icon/iron-icon.js'; import './languages.js'; @@ -36,14 +38,14 @@ // </if> import {assert} from 'chrome://resources/js/assert_ts.js'; import {focusWithoutInk} from 'chrome://resources/js/cr/ui/focus_without_ink.m.js'; -import {I18nMixin} from 'chrome://resources/js/i18n_mixin.js'; +import {I18nMixin, I18nMixinInterface} from 'chrome://resources/js/i18n_mixin.js'; import {DomRepeatEvent, PolymerElement} from 'chrome://resources/polymer/v3_0/polymer/polymer_bundled.min.js'; import {BaseMixin} from '../base_mixin.js'; import {loadTimeData} from '../i18n_setup.js'; -import {PrefsMixin} from '../prefs/prefs_mixin.js'; +import {PrefsMixin, PrefsMixinInterface} from '../prefs/prefs_mixin.js'; import {routes} from '../route.js'; -import {Router} from '../router.js'; +import {Route, RouteObserverMixin, RouteObserverMixinInterface, Router} from '../router.js'; import {getTemplate} from './languages_page.html.js'; import {LanguageSettingsMetricsProxy, LanguageSettingsMetricsProxyImpl, LanguageSettingsPageImpressionType} from './languages_settings_metrics_proxy.js'; @@ -52,7 +54,10 @@ type FocusConfig = Map<string, (string|(() => void))>; const SettingsLanguagesPageElementBase = - I18nMixin(PrefsMixin(BaseMixin(PolymerElement))); + RouteObserverMixin(I18nMixin(PrefsMixin(BaseMixin(PolymerElement)))) as { + new (): PolymerElement & RouteObserverMixinInterface & + PrefsMixinInterface & I18nMixinInterface, + }; export class SettingsLanguagesPageElement extends SettingsLanguagesPageElementBase { @@ -116,14 +121,6 @@ value: false, }, - /** - * Whether the language settings list is opened. - */ - languagesOpened_: { - type: Boolean, - observer: 'onLanguagesOpenedChanged_', - }, - showAddLanguagesDialog_: Boolean, focusConfig_: { @@ -167,7 +164,6 @@ private detailLanguage_?: LanguageState; private enableDesktopRestructuredLanguageSettings_: boolean; private hideSpellCheckLanguages_: boolean; - private languagesOpened_: boolean; private showAddLanguagesDialog_: boolean; private focusConfig_: FocusConfig; private languageSettingsMetricsProxy_: LanguageSettingsMetricsProxy = @@ -300,13 +296,6 @@ } /** - * @return The display name for a given language code. - */ - private getProspectiveUILanguageName_(languageCode: string): string { - return this.languageHelper.getLanguage(languageCode)!.displayName; - } - - /** * Handler to initiate another attempt at downloading the spell check * dictionary for a specified language. */ @@ -348,12 +337,8 @@ return undefined; } - /** - * @param newVal The new value of languagesOpened_. - * @param oldVal The old value of languagesOpened_. - */ - private onLanguagesOpenedChanged_(newVal: boolean, oldVal: boolean) { - if (!oldVal && newVal) { + override currentRouteChanged(currentRoute: Route) { + if (currentRoute === routes.LANGUAGES) { this.languageSettingsMetricsProxy_.recordPageImpressionMetric( LanguageSettingsPageImpressionType.MAIN); }
diff --git a/chrome/browser/resources/settings/settings.ts b/chrome/browser/resources/settings/settings.ts index 63bc7a50..f972cd3f 100644 --- a/chrome/browser/resources/settings/settings.ts +++ b/chrome/browser/resources/settings/settings.ts
@@ -14,7 +14,6 @@ export {CrToolbarElement} from 'chrome://resources/cr_elements/cr_toolbar/cr_toolbar.js'; export {CrToolbarSearchFieldElement} from 'chrome://resources/cr_elements/cr_toolbar/cr_toolbar_search_field.js'; export {PluralStringProxyImpl as SettingsPluralStringProxyImpl} from 'chrome://resources/js/plural_string_proxy.js'; -export {IronCollapseElement} from 'chrome://resources/polymer/v3_0/iron-collapse/iron-collapse.js'; export {SettingsAboutPageElement} from './about_page/about_page.js'; export {AboutPageBrowserProxy, AboutPageBrowserProxyImpl, UpdateStatus} from './about_page/about_page_browser_proxy.js'; // <if expr="_google_chrome and is_macosx">
diff --git a/chrome/browser/resources/side_panel/read_anything/app.ts b/chrome/browser/resources/side_panel/read_anything/app.ts index aae4513b..d984a1a 100644 --- a/chrome/browser/resources/side_panel/read_anything/app.ts +++ b/chrome/browser/resources/side_panel/read_anything/app.ts
@@ -65,7 +65,7 @@ callbackRouter.onFontNameChange.addListener( (newFontName: string) => this.updateFontName_(newFontName)) ]; - this.apiProxy_.showUI(); + this.apiProxy_.onUIReady(); } override disconnectedCallback() {
diff --git a/chrome/browser/resources/side_panel/read_anything/read_anything_api_proxy.ts b/chrome/browser/resources/side_panel/read_anything/read_anything_api_proxy.ts index a4096a0..305626d 100644 --- a/chrome/browser/resources/side_panel/read_anything/read_anything_api_proxy.ts +++ b/chrome/browser/resources/side_panel/read_anything/read_anything_api_proxy.ts
@@ -8,7 +8,7 @@ export interface ReadAnythingApiProxy { getCallbackRouter(): PageCallbackRouter; - showUI(): void; + onUIReady(): void; } export class ReadAnythingApiProxyImpl implements ReadAnythingApiProxy { @@ -28,8 +28,8 @@ return this.callbackRouter; } - showUI() { - this.handler.showUI(); + onUIReady() { + this.handler.onUIReady(); } static getInstance(): ReadAnythingApiProxy {
diff --git a/chrome/browser/share/core/resources/share_targets.asciipb b/chrome/browser/share/core/resources/share_targets.asciipb index 9f20a272..3ab9b15c 100644 --- a/chrome/browser/share/core/resources/share_targets.asciipb +++ b/chrome/browser/share/core/resources/share_targets.asciipb
@@ -8,14 +8,14 @@ ## ## Top level settings ## -version_id: 11 +version_id: 12 ## ## Share Targets ## targets { - nickname: "reddit" + nickname: "Reddit" url: "http://reddit.com/submit?url=%(escaped_url)&title=%(escaped_title)" icon: "iVBORw0KGgoAAAANSUhEUgAAABQAAAAUCAYAAACNiR0NAAAAAXNSR0IArs4c6QAA" @@ -888,7 +888,7 @@ locale_keys: "CA" targets: "Facebook" targets: "Twitter" - targets: "reddit" + targets: "Reddit" targets: "LinkedIn" targets: "Pinterest" } @@ -953,7 +953,7 @@ targets: "Facebook" targets: "LinkedIn" targets: "Pinterest" - targets: "reddit" + targets: "Reddit" targets: "Twitter" targets: "VK" targets: "WhatsApp"
diff --git a/chrome/browser/share/share_features.cc b/chrome/browser/share/share_features.cc index d1d6b10..d7dffcd7 100644 --- a/chrome/browser/share/share_features.cc +++ b/chrome/browser/share/share_features.cc
@@ -10,6 +10,8 @@ const base::Feature kPersistShareHubOnAppSwitch{ "PersistShareHubOnAppSwitch", base::FEATURE_DISABLED_BY_DEFAULT}; +const base::Feature kSharedHighlightingRefinedBlocklist{ + "SharedHighlightingRefinedBlocklist", base::FEATURE_DISABLED_BY_DEFAULT}; const base::Feature kSharingDesktopScreenshotsEdit{ "SharingDesktopScreenshotsEdit", base::FEATURE_DISABLED_BY_DEFAULT}; const base::Feature kUpcomingSharingFeatures{"UpcomingSharingFeatures",
diff --git a/chrome/browser/share/share_features.h b/chrome/browser/share/share_features.h index 24cb317..9f17fdc2 100644 --- a/chrome/browser/share/share_features.h +++ b/chrome/browser/share/share_features.h
@@ -13,6 +13,7 @@ namespace share { extern const base::Feature kPersistShareHubOnAppSwitch; +extern const base::Feature kSharedHighlightingRefinedBlocklist; extern const base::Feature kSharingDesktopScreenshotsEdit; extern const base::Feature kUpcomingSharingFeatures;
diff --git a/chrome/browser/ui/app_list/app_service/app_service_app_model_builder_unittest.cc b/chrome/browser/ui/app_list/app_service/app_service_app_model_builder_unittest.cc index 03c87ed..706d5ef 100644 --- a/chrome/browser/ui/app_list/app_service/app_service_app_model_builder_unittest.cc +++ b/chrome/browser/ui/app_list/app_service/app_service_app_model_builder_unittest.cc
@@ -9,6 +9,7 @@ #include <string> #include "ash/components/settings/cros_settings_names.h" +#include "ash/constants/ash_features.h" #include "ash/public/cpp/app_list/app_list_config.h" #include "ash/public/cpp/app_list/app_list_types.h" #include "base/files/file_path.h" @@ -17,6 +18,7 @@ #include "base/strings/utf_string_conversions.h" #include "base/test/bind.h" #include "base/test/scoped_command_line.h" +#include "base/test/scoped_feature_list.h" #include "base/values.h" #include "chrome/browser/apps/app_service/app_service_proxy.h" #include "chrome/browser/apps/app_service/app_service_proxy_factory.h" @@ -724,7 +726,9 @@ class CrostiniAppTest : public AppServiceAppModelBuilderTest { public: - CrostiniAppTest() = default; + CrostiniAppTest() { + features_.InitWithFeatures({ash::features::kTerminalSSH}, {}); + } ~CrostiniAppTest() override {} @@ -824,6 +828,7 @@ std::unique_ptr<app_list::AppListSyncableService> sync_service_; std::unique_ptr<CrostiniTestHelper> test_helper_; + base::test::ScopedFeatureList features_; private: std::unique_ptr< @@ -843,26 +848,18 @@ EXPECT_EQ(0u, GetModelItemCount()); CrostiniTestHelper::EnableCrostini(testing_profile()); - EXPECT_THAT(GetAllApps(), - testing::UnorderedElementsAre( - IsChromeApp(crostini::kCrostiniTerminalSystemAppId, - TerminalAppName(), ash::kCrostiniFolderId), - IsChromeApp(ash::kCrostiniFolderId, _, ""))); - + EXPECT_THAT(GetAllApps(), testing::IsEmpty()); CrostiniTestHelper::DisableCrostini(testing_profile()); EXPECT_THAT(GetAllApps(), testing::IsEmpty()); } TEST_F(CrostiniAppTest, AppInstallation) { - // Terminal app and the Crostini folder. - EXPECT_EQ(2u, GetModelItemCount()); + EXPECT_EQ(0u, GetModelItemCount()); test_helper_->SetupDummyApps(); EXPECT_THAT(GetAllApps(), testing::UnorderedElementsAre( - IsChromeApp(crostini::kCrostiniTerminalSystemAppId, - TerminalAppName(), ash::kCrostiniFolderId), IsChromeApp(_, kDummyApp1Name, ash::kCrostiniFolderId), IsChromeApp(_, kDummyApp2Name, ash::kCrostiniFolderId), IsChromeApp(ash::kCrostiniFolderId, _, ""))); @@ -871,8 +868,6 @@ CrostiniTestHelper::BasicApp(kBananaAppId, kBananaAppName)); EXPECT_THAT(GetAllApps(), testing::UnorderedElementsAre( - IsChromeApp(crostini::kCrostiniTerminalSystemAppId, - TerminalAppName(), ash::kCrostiniFolderId), IsChromeApp(_, kDummyApp1Name, ash::kCrostiniFolderId), IsChromeApp(_, kDummyApp2Name, ash::kCrostiniFolderId), IsChromeApp(_, kBananaAppName, ash::kCrostiniFolderId), @@ -883,8 +878,8 @@ TEST_F(CrostiniAppTest, UpdateApps) { test_helper_->SetupDummyApps(); - // 4 items: Terminal, two dummy apps and the Crostini folder. - EXPECT_EQ(4u, GetModelItemCount()); + // 3 items: two dummy apps and the Crostini folder. + EXPECT_EQ(3u, GetModelItemCount()); // Setting NoDisplay to true should hide an app. vm_tools::apps::App dummy1 = test_helper_->GetApp(0); @@ -893,7 +888,6 @@ EXPECT_THAT( GetAllApps(), testing::UnorderedElementsAre( - IsChromeApp(crostini::kCrostiniTerminalSystemAppId, _, _), IsChromeApp(CrostiniTestHelper::GenerateAppId(kDummyApp2Name), _, _), IsChromeApp(ash::kCrostiniFolderId, _, ""))); @@ -903,7 +897,6 @@ EXPECT_THAT( GetAllApps(), testing::UnorderedElementsAre( - IsChromeApp(crostini::kCrostiniTerminalSystemAppId, _, _), IsChromeApp(CrostiniTestHelper::GenerateAppId(kDummyApp1Name), _, _), IsChromeApp(CrostiniTestHelper::GenerateAppId(kDummyApp2Name), _, _), IsChromeApp(ash::kCrostiniFolderId, _, ""))); @@ -914,7 +907,6 @@ test_helper_->AddApp(dummy2); EXPECT_THAT(GetAllApps(), testing::UnorderedElementsAre( - IsChromeApp(crostini::kCrostiniTerminalSystemAppId, _, _), IsChromeApp(CrostiniTestHelper::GenerateAppId(kDummyApp1Name), kDummyApp1Name, _), IsChromeApp(CrostiniTestHelper::GenerateAppId(kDummyApp2Name), @@ -925,24 +917,25 @@ // Test that the app model builder handles removed apps TEST_F(CrostiniAppTest, RemoveApps) { test_helper_->SetupDummyApps(); - // 4 items: Terminal, two dummy apps and the Crostini folder. - EXPECT_EQ(4u, GetModelItemCount()); + // 3 items: two dummy apps and the Crostini folder. + EXPECT_EQ(3u, GetModelItemCount()); // Remove dummy1 test_helper_->RemoveApp(0); - EXPECT_EQ(3u, GetModelItemCount()); + EXPECT_EQ(2u, GetModelItemCount()); // Remove dummy2 test_helper_->RemoveApp(0); - EXPECT_EQ(2u, GetModelItemCount()); + EXPECT_EQ(0u, GetModelItemCount()); } // Tests that the crostini folder is created with the correct parameters. TEST_F(CrostiniAppTest, CreatesFolder) { + test_helper_->SetupDummyApps(); EXPECT_THAT(GetAllApps(), testing::UnorderedElementsAre( - IsChromeApp(crostini::kCrostiniTerminalSystemAppId, - TerminalAppName(), ash::kCrostiniFolderId), + IsChromeApp(_, kDummyApp1Name, ash::kCrostiniFolderId), + IsChromeApp(_, kDummyApp2Name, ash::kCrostiniFolderId), testing::AllOf( IsChromeApp(ash::kCrostiniFolderId, kRootFolderName, ""), IsPersistentApp()))); @@ -951,8 +944,8 @@ // Test that the Terminal app is removed when Crostini is disabled. TEST_F(CrostiniAppTest, DisableCrostini) { test_helper_->SetupDummyApps(); - // 4 items: one termnial, two dummy apps and the Crostini folder. - EXPECT_EQ(4u, GetModelItemCount()); + // 3 items: two dummy apps and the Crostini folder. + EXPECT_EQ(3u, GetModelItemCount()); // The uninstall flow removes all apps before setting the CrostiniEnabled pref // to false, so we need to do that explicitly too.
diff --git a/chrome/browser/ui/app_list/search/app_search_provider_unittest.cc b/chrome/browser/ui/app_list/search/app_search_provider_unittest.cc index 3fe07fc..88896c2 100644 --- a/chrome/browser/ui/app_list/search/app_search_provider_unittest.cc +++ b/chrome/browser/ui/app_list/search/app_search_provider_unittest.cc
@@ -585,39 +585,6 @@ } }; -TEST_F(AppSearchProviderCrostiniTest, CrostiniTerminal) { - CreateSearch(); - - // Crostini UI is not allowed yet. - EXPECT_EQ("", RunQuery("terminal")); - EXPECT_EQ("", RunQuery("linux")); - - // This both allows Crostini UI and enables Crostini. - crostini::CrostiniTestHelper crostini_test_helper(testing_profile()); - crostini_test_helper.ReInitializeAppServiceIntegration(); - CreateSearch(); - EXPECT_EQ("Terminal,Hosted App", RunQuery("te")); - EXPECT_EQ("Terminal", RunQuery("ter")); - EXPECT_EQ("Terminal", RunQuery("terminal")); - EXPECT_EQ("Terminal", RunQuery("li")); - EXPECT_EQ("Terminal", RunQuery("linux")); - EXPECT_EQ("Terminal", RunQuery("crosti")); - - // If Crostini UI is allowed but disabled (i.e. not installed), a match score - // of 0.8 is required before surfacing search results. - crostini::CrostiniTestHelper::DisableCrostini(testing_profile()); - CreateSearch(); - EXPECT_EQ("Hosted App", RunQuery("te")); - EXPECT_EQ("Terminal", RunQuery("ter")); - EXPECT_EQ("Terminal", RunQuery("terminal")); - EXPECT_EQ("", RunQuery("li")); - EXPECT_EQ("Terminal", RunQuery("lin")); - EXPECT_EQ("Terminal", RunQuery("linux")); - EXPECT_EQ("", RunQuery("cr")); - EXPECT_EQ("Terminal", RunQuery("cro")); - EXPECT_EQ("Terminal", RunQuery("cros")); -} - TEST_F(AppSearchProviderCrostiniTest, CrostiniApp) { // This both allows Crostini UI and enables Crostini. crostini::CrostiniTestHelper crostini_test_helper(testing_profile());
diff --git a/chrome/browser/ui/ash/shelf/app_shortcut_shelf_item_controller_browsertest.cc b/chrome/browser/ui/ash/shelf/app_shortcut_shelf_item_controller_browsertest.cc index fb44b3e19..88bbb53a 100644 --- a/chrome/browser/ui/ash/shelf/app_shortcut_shelf_item_controller_browsertest.cc +++ b/chrome/browser/ui/ash/shelf/app_shortcut_shelf_item_controller_browsertest.cc
@@ -4,9 +4,11 @@ #include "chrome/browser/ui/ash/shelf/app_shortcut_shelf_item_controller.h" +#include "ash/constants/ash_features.h" #include "ash/public/cpp/shelf_model.h" #include "ash/public/cpp/shelf_types.h" #include "base/callback_helpers.h" +#include "base/test/scoped_feature_list.h" #include "chrome/browser/ash/crostini/crostini_terminal.h" #include "chrome/browser/ui/ash/shelf/chrome_shelf_controller.h" #include "chrome/browser/ui/ash/shelf/chrome_shelf_controller_util.h" @@ -58,6 +60,10 @@ // which allows us to test app menu with either windows or tabs (shift click). class AppShortcutShelfItemControllerBrowserTest : public InProcessBrowserTest { protected: + AppShortcutShelfItemControllerBrowserTest() { + features_.InitWithFeatures({ash::features::kTerminalSSH}, {}); + } + void SetUpOnMainThread() override { controller_ = ChromeShelfController::instance(); ASSERT_TRUE(controller_); @@ -92,6 +98,7 @@ web_app::AppId app_id_; ash::ShelfID app_shelf_id_; + base::test::ScopedFeatureList features_; }; // Test interacting with the app menu without shift key down: the app menu has @@ -146,25 +153,25 @@ EXPECT_EQ(0u, GetAppMenuItems(ui::EF_SHIFT_DOWN).size()); - // Launch an app window. + // Launch an app window. Terminal includes pinned home tab, and Linux tab. Browser* app_browser0 = LaunchApp(); - EXPECT_EQ(1u, GetAppMenuItems(ui::EF_SHIFT_DOWN).size()); + EXPECT_EQ(2u, GetAppMenuItems(ui::EF_SHIFT_DOWN).size()); // Launch a new app window. Browser* app_browser1 = LaunchApp(); - EXPECT_EQ(2u, GetAppMenuItems(ui::EF_SHIFT_DOWN).size()); + EXPECT_EQ(4u, GetAppMenuItems(ui::EF_SHIFT_DOWN).size()); - // Open a new app tab in an existing app browser. There are 3 tab items. + // Open a new app tab in an existing app browser. chrome::NewTab(app_browser1); - EXPECT_EQ(3u, GetAppMenuItems(ui::EF_SHIFT_DOWN).size()); + EXPECT_EQ(5u, GetAppMenuItems(ui::EF_SHIFT_DOWN).size()); - // Clicking the second item in the menu should activate the first tab in the + // Clicking the third item in the menu should activate the first tab in the // second window. app_browser1->tab_strip_model()->ActivateTabAt(1); app_browser1->window()->Minimize(); GetAppMenuItems(ui::EF_SHIFT_DOWN); GetShelfItemDelegate()->ExecuteCommand(/*from_context_menu=*/false, - /*command_id=*/1, ui::EF_NONE, + /*command_id=*/2, ui::EF_NONE, display::kInvalidDisplayId); EXPECT_TRUE(app_browser1->window()->IsActive()); EXPECT_TRUE(app_browser1->tab_strip_model()->active_index() == 0); @@ -177,9 +184,9 @@ display::kInvalidDisplayId); // Shift-clicking on a item should close it. - EXPECT_EQ(2u, GetAppMenuItems(ui::EF_SHIFT_DOWN).size()); + EXPECT_EQ(3u, GetAppMenuItems(ui::EF_SHIFT_DOWN).size()); GetShelfItemDelegate()->ExecuteCommand(/*from_context_menu=*/false, /*command_id=*/0, ui::EF_SHIFT_DOWN, display::kInvalidDisplayId); - EXPECT_EQ(1u, GetAppMenuItems(ui::EF_SHIFT_DOWN).size()); + EXPECT_EQ(2u, GetAppMenuItems(ui::EF_SHIFT_DOWN).size()); }
diff --git a/chrome/browser/ui/ash/shelf/chrome_shelf_controller_unittest.cc b/chrome/browser/ui/ash/shelf/chrome_shelf_controller_unittest.cc index 6af6535..9bb73860 100644 --- a/chrome/browser/ui/ash/shelf/chrome_shelf_controller_unittest.cc +++ b/chrome/browser/ui/ash/shelf/chrome_shelf_controller_unittest.cc
@@ -929,8 +929,6 @@ result += "Platform_App"; } else if (app == arc_support_host_->id()) { result += "Play Store"; - } else if (app == crostini::kCrostiniTerminalSystemAppId) { - result += "Terminal"; } else if (app == arc::kSettingsAppId) { result += "Android Settings"; } else { @@ -5102,32 +5100,6 @@ GetPinnableForAppID(web_app_id, profile())); } -TEST_P(ChromeShelfControllerTest, CrostiniTerminalPinUnpin) { - InitShelfController(); - - // Load pinned Terminal from prefs without Crostini UI being allowed - syncer::SyncChangeList sync_list; - InsertAddPinChange(&sync_list, 1, crostini::kCrostiniTerminalSystemAppId); - SendPinChanges(sync_list, true); - EXPECT_EQ("Chrome", GetPinnedAppStatus()); - - // Reload after allowing Crostini UI - crostini::CrostiniTestHelper test_helper(profile()); - test_helper.ReInitializeAppServiceIntegration(); - // TODO(crubug.com/918739): Fix pins are not refreshed on enabling Crostini. - // As a workaround add any app that triggers pin update. - AddExtension(extension1_.get()); - EXPECT_EQ("Chrome, Terminal", GetPinnedAppStatus()); - - // Unpin the Terminal - shelf_controller_->UnpinAppWithID(crostini::kCrostiniTerminalSystemAppId); - EXPECT_EQ("Chrome", GetPinnedAppStatus()); - - // Pin Terminal again. - PinAppWithIDToShelf(crostini::kCrostiniTerminalSystemAppId); - EXPECT_EQ("Chrome, Terminal", GetPinnedAppStatus()); -} - // Tests behavior for ensuring some component apps can be marked unpinnable. TEST_P(ChromeShelfControllerTest, UnpinnableComponentApps) { InitShelfController();
diff --git a/chrome/browser/ui/ash/shelf/shelf_context_menu_unittest.cc b/chrome/browser/ui/ash/shelf/shelf_context_menu_unittest.cc index a812923..1f80694f 100644 --- a/chrome/browser/ui/ash/shelf/shelf_context_menu_unittest.cc +++ b/chrome/browser/ui/ash/shelf/shelf_context_menu_unittest.cc
@@ -628,33 +628,6 @@ } } -// Checks some properties for crostini's terminal app's context menu, -// specifically that every menu item has an icon. -TEST_F(ShelfContextMenuTest, CrostiniTerminalApp) { - const std::string app_id = crostini::kCrostiniTerminalSystemAppId; - crostini::CrostiniManager::GetForProfile(profile())->AddRunningVmForTesting( - crostini::kCrostiniDefaultVmName); - - PinAppWithIDToShelf(app_id); - const ash::ShelfItem* item = controller()->GetItem(ash::ShelfID(app_id)); - ASSERT_TRUE(item); - - ash::ShelfItemDelegate* item_delegate = - model()->GetShelfItemDelegate(ash::ShelfID(app_id)); - ASSERT_TRUE(item_delegate); - int64_t primary_id = GetPrimaryDisplay().id(); - std::unique_ptr<ui::MenuModel> menu = - GetContextMenu(item_delegate, primary_id); - - // Check that every menu item has an icon - for (int i = 0; i < menu->GetItemCount(); ++i) - EXPECT_FALSE(menu->GetIconAt(i).IsEmpty()); - - // When crostini is running, the terminal should have an option to kill the - // vm. - EXPECT_TRUE(IsItemEnabledInMenu(menu.get(), ash::SHUTDOWN_GUEST_OS)); -} - // Checks the context menu for a "normal" crostini app (i.e. a registered one). // Particularly, we ensure that the density changing option exists. // TODO(crbug.com/1177126) Re-enable test
diff --git a/chrome/browser/ui/views/crostini/crostini_update_component_view_browsertest.cc b/chrome/browser/ui/views/crostini/crostini_update_component_view_browsertest.cc index aa01388..8624b35a 100644 --- a/chrome/browser/ui/views/crostini/crostini_update_component_view_browsertest.cc +++ b/chrome/browser/ui/views/crostini/crostini_update_component_view_browsertest.cc
@@ -10,7 +10,10 @@ #include "base/test/metrics/histogram_tester.h" #include "base/test/scoped_feature_list.h" #include "chrome/browser/ash/crostini/crostini_manager.h" +#include "chrome/browser/ash/crostini/crostini_test_helper.h" #include "chrome/browser/ash/crostini/crostini_util.h" +#include "chrome/browser/ash/guest_os/guest_os_registry_service.h" +#include "chrome/browser/ash/guest_os/guest_os_registry_service_factory.h" #include "chrome/browser/profiles/profile.h" #include "chrome/browser/ui/browser.h" #include "chrome/browser/ui/browser_list.h" @@ -28,6 +31,9 @@ #include "testing/gtest/include/gtest/gtest.h" namespace { + +constexpr char kDesktopFile[] = "desktop_file"; + class Waiter : public BrowserListObserver { public: static void WaitForNewBrowser() { @@ -51,7 +57,7 @@ class CrostiniUpdateComponentViewBrowserTest : public CrostiniDialogBrowserTest { - public: + protected: CrostiniUpdateComponentViewBrowserTest() : CrostiniDialogBrowserTest(true /*register_termina*/) { // TODO(crbug/953544) DLC makes this entire feature redundant, so once we're @@ -60,6 +66,15 @@ chromeos::features::kCrostiniUseDlc); } + void SetUpOnMainThread() override { + vm_tools::apps::ApplicationList app_list = + crostini::CrostiniTestHelper::BasicAppList(kDesktopFile); + auto* registry_service = + guest_os::GuestOsRegistryServiceFactory::GetForProfile( + browser()->profile()); + registry_service->UpdateApplicationList(app_list); + } + // DialogBrowserTest: void ShowUi(const std::string& name) override { ShowCrostiniUpdateComponentView(browser()->profile(), @@ -134,18 +149,14 @@ ExpectNoView(); UnregisterTermina(); - crostini::LaunchCrostiniApp(browser()->profile(), - crostini::kCrostiniTerminalSystemAppId, 0); + crostini::LaunchCrostiniApp( + browser()->profile(), + crostini::CrostiniTestHelper::GenerateAppId(kDesktopFile), 0); ExpectNoView(); } IN_PROC_BROWSER_TEST_F(CrostiniUpdateComponentViewBrowserTest, LaunchAppOffline_UpgradeNeeded) { - // Ensure Terminal System App is installed. - web_app::WebAppProvider::GetForTest(browser()->profile()) - ->system_web_app_manager() - .InstallSystemAppsForTesting(); - base::HistogramTester histogram_tester; SetConnectionType(network::mojom::ConnectionType::CONNECTION_NONE); crostini::CrostiniManager::GetForProfile(browser()->profile()) @@ -154,16 +165,9 @@ ExpectNoView(); UnregisterTermina(); - crostini::LaunchCrostiniApp(browser()->profile(), - crostini::kCrostiniTerminalSystemAppId, 0); - Waiter::WaitForNewBrowser(); - - // For Terminal System App, we must wait for browser to load. - Browser* terminal_browser = web_app::FindSystemWebAppBrowser( - browser()->profile(), web_app::SystemAppType::TERMINAL); - CHECK_NE(nullptr, terminal_browser); - WaitForLoadFinished(terminal_browser->tab_strip_model()->GetWebContentsAt(0)); - + crostini::LaunchCrostiniApp( + browser()->profile(), + crostini::CrostiniTestHelper::GenerateAppId(kDesktopFile), 0); ExpectView(); ActiveView()->AcceptDialog();
diff --git a/chrome/browser/ui/views/frame/browser_view.cc b/chrome/browser/ui/views/frame/browser_view.cc index af434ef..3b2930f 100644 --- a/chrome/browser/ui/views/frame/browser_view.cc +++ b/chrome/browser/ui/views/frame/browser_view.cc
@@ -8,6 +8,7 @@ #include <algorithm> #include <memory> +#include <set> #include <utility> #include "base/auto_reset.h" @@ -1303,6 +1304,13 @@ #elif BUILDFLAG(IS_WIN) if (base::win::GetVersion() < base::win::Version::WIN10) return true; + absl::optional<bool> on_current_workspace = + native_win->GetHost()->on_current_workspace(); + base::UmaHistogramBoolean("Windows.OnCurrentWorkspaceCached", + on_current_workspace.has_value()); + if (on_current_workspace.has_value()) + return on_current_workspace.value(); + Microsoft::WRL::ComPtr<IVirtualDesktopManager> virtual_desktop_manager; if (!SUCCEEDED(::CoCreateInstance(_uuidof(VirtualDesktopManager), nullptr, CLSCTX_ALL,
diff --git a/chrome/browser/ui/views/side_panel/read_anything/read_anything_controller.cc b/chrome/browser/ui/views/side_panel/read_anything/read_anything_controller.cc index 519c5b8..8a0a585 100644 --- a/chrome/browser/ui/views/side_panel/read_anything/read_anything_controller.cc +++ b/chrome/browser/ui/views/side_panel/read_anything/read_anything_controller.cc
@@ -5,6 +5,7 @@ #include "chrome/browser/ui/views/side_panel/read_anything/read_anything_controller.h" #include <string> +#include <utility> #include <vector> #include "base/strings/utf_string_conversions.h" @@ -47,16 +48,37 @@ ReadAnythingController::ReadAnythingController(ReadAnythingModel* model, Browser* browser) - : model_(model), browser_(browser) {} + : model_(model), browser_(browser) { + DCHECK(browser_); + if (browser_->tab_strip_model()) + browser_->tab_strip_model()->AddObserver(this); +} + +ReadAnythingController::~ReadAnythingController() { + DCHECK(browser_); + if (browser_->tab_strip_model()) + browser_->tab_strip_model()->RemoveObserver(this); +} void ReadAnythingController::OnFontChoiceChanged(int new_choice) { model_->SetSelectedFontIndex(new_choice); } -void ReadAnythingController::OnUIShown() { - if (!browser_) - return; +void ReadAnythingController::OnUIReady() { + DistillAXTree(); +} +void ReadAnythingController::OnTabStripModelChanged( + TabStripModel* tab_strip_model, + const TabStripModelChange& change, + const TabStripSelectionChange& selection) { + if (!selection.active_tab_changed()) + return; + DistillAXTree(); +} + +void ReadAnythingController::DistillAXTree() { + DCHECK(browser_); content::WebContents* web_contents = browser_->tab_strip_model()->GetActiveWebContents(); if (!web_contents) @@ -97,5 +119,3 @@ // Update the content in the model. model_->SetContent(std::move(content_nodes)); } - -ReadAnythingController::~ReadAnythingController() = default;
diff --git a/chrome/browser/ui/views/side_panel/read_anything/read_anything_controller.h b/chrome/browser/ui/views/side_panel/read_anything/read_anything_controller.h index e173c4c..8427aa2 100644 --- a/chrome/browser/ui/views/side_panel/read_anything/read_anything_controller.h +++ b/chrome/browser/ui/views/side_panel/read_anything/read_anything_controller.h
@@ -8,6 +8,7 @@ #include <vector> #include "base/memory/weak_ptr.h" +#include "chrome/browser/ui/tabs/tab_strip_model_observer.h" #include "chrome/browser/ui/views/side_panel/read_anything/read_anything_coordinator.h" #include "chrome/browser/ui/views/side_panel/read_anything/read_anything_model.h" #include "chrome/browser/ui/views/side_panel/read_anything/read_anything_toolbar_view.h" @@ -32,19 +33,30 @@ // as the browser. // class ReadAnythingController : public ReadAnythingToolbarView::Delegate, - public ReadAnythingPageHandler::Delegate { + public ReadAnythingPageHandler::Delegate, + public TabStripModelObserver { public: - explicit ReadAnythingController(ReadAnythingModel* model, Browser* browser); + ReadAnythingController(ReadAnythingModel* model, Browser* browser); ReadAnythingController(const ReadAnythingController&) = delete; ReadAnythingController& operator=(const ReadAnythingController&) = delete; - virtual ~ReadAnythingController(); + ~ReadAnythingController() override; private: // ReadAnythingToolbarView::Delegate: void OnFontChoiceChanged(int new_choice) override; // ReadAnythingPageHandler::Delegate: - void OnUIShown() override; + void OnUIReady() override; + + // TabStripModelObserver: + void OnTabStripModelChanged( + TabStripModel* tab_strip_model, + const TabStripModelChange& change, + const TabStripSelectionChange& selection) override; + + // Requests a distilled AXTree for the main frame of the currently active + // web contents. + void DistillAXTree(); // Callback method which receives an AXTree snapshot and a list of AXNodes // which correspond to nodes in the tree that contain main content. @@ -52,9 +64,12 @@ const std::vector<ui::AXNodeID>& content_node_ids); const raw_ptr<ReadAnythingModel> model_; - Browser* browser_; std::vector<ReadAnythingModel::Observer*> observers_; + // ReadAnythingController is owned by ReadAnythingCoordinator which is a + // browser user data, so this pointer is always valid. + Browser* browser_; + base::WeakPtrFactory<ReadAnythingController> weak_pointer_factory_{this}; }; #endif // CHROME_BROWSER_UI_VIEWS_SIDE_PANEL_READ_ANYTHING_READ_ANYTHING_CONTROLLER_H_
diff --git a/chrome/browser/ui/views/webid/account_selection_bubble_view.cc b/chrome/browser/ui/views/webid/account_selection_bubble_view.cc index 982a843..a852f90 100644 --- a/chrome/browser/ui/views/webid/account_selection_bubble_view.cc +++ b/chrome/browser/ui/views/webid/account_selection_bubble_view.cc
@@ -85,7 +85,6 @@ } // namespace AccountSelectionBubbleView::AccountSelectionBubbleView( - AccountSelectionView::Delegate* delegate, const std::string& rp_etld_plus_one, const std::string& idp_etld_plus_one, base::span<const content::IdentityRequestAccount> accounts, @@ -93,14 +92,16 @@ const content::ClientIdData& client_data, views::View* anchor_view, scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory, - TabStripModel* tab_strip_model) + TabStripModel* tab_strip_model, + base::OnceCallback<void(const content::IdentityRequestAccount&)> + on_account_selected_callback) : views::BubbleDialogDelegateView(anchor_view, views::BubbleBorder::Arrow::TOP_RIGHT), idp_etld_plus_one_(base::UTF8ToUTF16(idp_etld_plus_one)), brand_text_color_(idp_metadata.brand_text_color), brand_background_color_(idp_metadata.brand_background_color), tab_strip_model_(tab_strip_model), - delegate_(delegate), + on_account_selected_callback_(std::move(on_account_selected_callback)), client_data_(client_data) { image_fetcher_ = std::make_unique<image_fetcher::ImageFetcherImpl>( std::make_unique<ImageDecoderImpl>(), url_loader_factory); @@ -313,7 +314,7 @@ void AccountSelectionBubbleView::OnAccountSelected( const content::IdentityRequestAccount& account) { ShowVerifySheet(account); - delegate_->OnAccountSelected(account); + std::move(on_account_selected_callback_).Run(account); } void AccountSelectionBubbleView::ShowVerifySheet(
diff --git a/chrome/browser/ui/views/webid/account_selection_bubble_view.h b/chrome/browser/ui/views/webid/account_selection_bubble_view.h index 267d24a..7ef0ac9dd5 100644 --- a/chrome/browser/ui/views/webid/account_selection_bubble_view.h +++ b/chrome/browser/ui/views/webid/account_selection_bubble_view.h
@@ -5,6 +5,7 @@ #ifndef CHROME_BROWSER_UI_VIEWS_WEBID_ACCOUNT_SELECTION_BUBBLE_VIEW_H_ #define CHROME_BROWSER_UI_VIEWS_WEBID_ACCOUNT_SELECTION_BUBBLE_VIEW_H_ +#include "base/callback.h" #include "chrome/browser/ui/tabs/tab_strip_model.h" #include "chrome/browser/ui/webid/account_selection_view.h" #include "components/image_fetcher/core/image_fetcher.h" @@ -21,7 +22,6 @@ public: METADATA_HEADER(AccountSelectionBubbleView); AccountSelectionBubbleView( - AccountSelectionView::Delegate* delegate, const std::string& rp_etld_plus_one, const std::string& idp_etld_plus_one, base::span<const content::IdentityRequestAccount> accounts, @@ -29,7 +29,9 @@ const content::ClientIdData& client_data, views::View* anchor_view, scoped_refptr<network::SharedURLLoaderFactory> url_loader_factory, - TabStripModel* tab_strip_model); + TabStripModel* tab_strip_model, + base::OnceCallback<void(const content::IdentityRequestAccount&)> + on_account_selected_callback); ~AccountSelectionBubbleView() override; private: @@ -94,8 +96,8 @@ // privacy policy and terms of service urls when the user clicks on the links. const raw_ptr<TabStripModel> tab_strip_model_; - // The delegate to which the account selection is sent. - raw_ptr<AccountSelectionView::Delegate> delegate_ = nullptr; + base::OnceCallback<void(const content::IdentityRequestAccount&)> + on_account_selected_callback_; // The privacy policy and terms of service URLs const content::ClientIdData client_data_;
diff --git a/chrome/browser/ui/views/webid/account_selection_bubble_view_unittest.cc b/chrome/browser/ui/views/webid/account_selection_bubble_view_unittest.cc index 538af86..75c7b74 100644 --- a/chrome/browser/ui/views/webid/account_selection_bubble_view_unittest.cc +++ b/chrome/browser/ui/views/webid/account_selection_bubble_view_unittest.cc
@@ -6,6 +6,7 @@ #include <string> +#include "base/bind.h" #include "base/memory/raw_ptr.h" #include "base/test/scoped_feature_list.h" #include "chrome/browser/ui/views/hover_button.h" @@ -40,6 +41,9 @@ u"Sign in to rp-example.com with idp-example.com"; const std::u16string kTitleSigningIn = u"Verifying…"; +void MockAccountSelectedCallback( + const content::IdentityRequestAccount& selected_account) {} + } // namespace class AccountSelectionBubbleViewTest : public ChromeViewsTestBase { @@ -95,10 +99,11 @@ anchor_widget_ = std::make_unique<views::Widget>(); anchor_widget_->Init(std::move(params)); anchor_widget_->Show(); + dialog_ = new AccountSelectionBubbleView( - delegate_.get(), kRpETLDPlusOne, kIdpETLDPlusOne, accounts, - idp_metadata, client_data, anchor_widget_->GetContentsView(), - shared_url_loader_factory(), nullptr); + kRpETLDPlusOne, kIdpETLDPlusOne, accounts, idp_metadata, client_data, + anchor_widget_->GetContentsView(), shared_url_loader_factory(), nullptr, + base::BindOnce(&MockAccountSelectedCallback)); views::BubbleDialogDelegateView::CreateBubble(dialog_)->Show(); }
diff --git a/chrome/browser/ui/views/webid/fedcm_account_selection_view_desktop.cc b/chrome/browser/ui/views/webid/fedcm_account_selection_view_desktop.cc index 2e774cc4..89481d8 100644 --- a/chrome/browser/ui/views/webid/fedcm_account_selection_view_desktop.cc +++ b/chrome/browser/ui/views/webid/fedcm_account_selection_view_desktop.cc
@@ -4,6 +4,7 @@ #include "chrome/browser/ui/views/webid/fedcm_account_selection_view_desktop.h" +#include "base/bind.h" #include "chrome/browser/net/system_network_context_manager.h" #include "chrome/browser/ui/browser_finder.h" #include "chrome/browser/ui/views/frame/browser_view.h" @@ -36,8 +37,7 @@ content::WebContentsObserver(delegate->GetWebContents()) {} FedCmAccountSelectionView::~FedCmAccountSelectionView() { - if (bubble_widget_) - bubble_widget_->Close(); + Close(); Browser* browser = chrome::FindBrowserWithWebContents(delegate_->GetWebContents()); @@ -60,15 +60,19 @@ views::View* anchor_view = browser_view->top_container(); TabStripModel* tab_strip_model = browser_view->browser()->tab_strip_model(); tab_strip_model->AddObserver(this); - bubble_widget_ = views::BubbleDialogDelegateView::CreateBubble( - new AccountSelectionBubbleView( - delegate_, rp_etld_plus_one, idp_etld_plus_one, - accounts, idp_metadata, client_data, anchor_view, - SystemNetworkContextManager::GetInstance() - ->GetSharedURLLoaderFactory(), - tab_strip_model)) - ->GetWeakPtr(); + bubble_widget_ = + views::BubbleDialogDelegateView::CreateBubble( + new AccountSelectionBubbleView( + rp_etld_plus_one, idp_etld_plus_one, accounts, idp_metadata, + client_data, anchor_view, + SystemNetworkContextManager::GetInstance() + ->GetSharedURLLoaderFactory(), + tab_strip_model, + base::BindOnce(&FedCmAccountSelectionView::OnAccountSelected, + base::Unretained(this)))) + ->GetWeakPtr(); bubble_widget_->Show(); + bubble_widget_->AddObserver(this); } void FedCmAccountSelectionView::OnVisibilityChanged( @@ -85,10 +89,7 @@ void FedCmAccountSelectionView::PrimaryPageChanged(content::Page& page) { // Close the bubble when the user navigates within the same tab. - if (bubble_widget_) { - bubble_widget_->Close(); - bubble_widget_ = nullptr; - } + Close(); } void FedCmAccountSelectionView::OnTabStripModelChanged( @@ -103,7 +104,37 @@ // possible to move the bubble with the tab, even to a different browser // window. if (index == TabStripModel::kNoTab && bubble_widget_) { - bubble_widget_->Close(); - bubble_widget_ = nullptr; + Close(); } } + +void FedCmAccountSelectionView::OnWidgetDestroying(views::Widget* widget) { + bool should_embargo = (bubble_widget_->closed_reason() == + views::Widget::ClosedReason::kCloseButtonClicked); + OnDismiss(should_embargo); +} + +void FedCmAccountSelectionView::OnAccountSelected( + const content::IdentityRequestAccount& account) { + was_account_selected_ = true; + delegate_->OnAccountSelected(account); +} + +void FedCmAccountSelectionView::Close() { + if (!bubble_widget_) + return; + + bubble_widget_->Close(); + OnDismiss(/*should_embargo=*/false); +} + +void FedCmAccountSelectionView::OnDismiss(bool should_embargo) { + if (!bubble_widget_) + return; + + bubble_widget_->RemoveObserver(this); + bubble_widget_.reset(); + + if (!was_account_selected_) + delegate_->OnDismiss(should_embargo); +}
diff --git a/chrome/browser/ui/views/webid/fedcm_account_selection_view_desktop.h b/chrome/browser/ui/views/webid/fedcm_account_selection_view_desktop.h index 0c0a984..da3c2ad 100644 --- a/chrome/browser/ui/views/webid/fedcm_account_selection_view_desktop.h +++ b/chrome/browser/ui/views/webid/fedcm_account_selection_view_desktop.h
@@ -10,13 +10,15 @@ #include "chrome/browser/ui/tabs/tab_strip_model_observer.h" #include "chrome/browser/ui/views/webid/account_selection_bubble_view.h" #include "content/public/browser/web_contents_observer.h" +#include "ui/views/widget/widget_observer.h" // Provides an implementation of the AccountSelectionView interface on desktop, // which creates the AccountSelectionBubbleView dialog to display the FedCM // account chooser to the user. class FedCmAccountSelectionView : public AccountSelectionView, content::WebContentsObserver, - TabStripModelObserver { + TabStripModelObserver, + views::WidgetObserver { public: explicit FedCmAccountSelectionView(AccountSelectionView::Delegate* delegate); ~FedCmAccountSelectionView() override; @@ -42,6 +44,24 @@ protected: friend class FedCmAccountSelectionViewBrowserTest; + private: + // views::WidgetObserver: + void OnWidgetDestroying(views::Widget* widget) override; + + // Called when the user selected an account AND granted consent. + void OnAccountSelected(const content::IdentityRequestAccount& account); + + // Closes the widget and notifies the delegate. + void Close(); + + // Notify the delegate that the widget was closed. + // |should_embargo| indicates whether the FedCM API should be embargoed due + // to the user explicitly dismissing the dialog. + void OnDismiss(bool should_embargo); + + // Whether the user selected an account in the dialog. + bool was_account_selected_{false}; + base::WeakPtr<views::Widget> bubble_widget_; };
diff --git a/chrome/browser/ui/webui/feed/BUILD.gn b/chrome/browser/ui/webui/feed/BUILD.gn index c35be68..d2fb9ba 100644 --- a/chrome/browser/ui/webui/feed/BUILD.gn +++ b/chrome/browser/ui/webui/feed/BUILD.gn
@@ -1,4 +1,8 @@ +# Copyright 2022 The Chromium Authors. All rights reserved. +# Use of this source code is governed by a BSD-style license that can be +# found in the LICENSE file. import("//mojo/public/tools/bindings/mojom.gni") + mojom("mojo_bindings") { sources = [ "feed.mojom" ] public_deps = [ "//mojo/public/mojom/base" ]
diff --git a/chrome/browser/ui/webui/feed/feed_ui.cc b/chrome/browser/ui/webui/feed/feed_ui.cc index 442013d2..352d0e6f 100644 --- a/chrome/browser/ui/webui/feed/feed_ui.cc +++ b/chrome/browser/ui/webui/feed/feed_ui.cc
@@ -73,8 +73,6 @@ // Configurable javascript for prototyping purposes. source->AddString("scriptUrl", kWebUiScriptFetchUrl.Get()); - source->AddResourcePath("feed.mojom-webui.js", IDR_FEED_FEED_MOJOM_WEBUI_JS); - // Register the URLDataSource auto* browser_context = web_ui->GetWebContents()->GetBrowserContext(); content::WebUIDataSource::Add(browser_context, source);
diff --git a/chrome/browser/ui/webui/side_panel/read_anything/read_anything.mojom b/chrome/browser/ui/webui/side_panel/read_anything/read_anything.mojom index c4b30b513..1e634ef 100644 --- a/chrome/browser/ui/webui/side_panel/read_anything/read_anything.mojom +++ b/chrome/browser/ui/webui/side_panel/read_anything/read_anything.mojom
@@ -29,8 +29,8 @@ // Browser-side handler for requests from WebUI page. interface PageHandler { - // Notify the backend that the UI is ready to be shown. - ShowUI(); + // Notify the backend that the WebUI is ready. + OnUIReady(); }; // WebUI-side handler for requests from the browser.
diff --git a/chrome/browser/ui/webui/side_panel/read_anything/read_anything_page_handler.cc b/chrome/browser/ui/webui/side_panel/read_anything/read_anything_page_handler.cc index 863db60..196ee62 100644 --- a/chrome/browser/ui/webui/side_panel/read_anything/read_anything_page_handler.cc +++ b/chrome/browser/ui/webui/side_panel/read_anything/read_anything_page_handler.cc
@@ -41,8 +41,8 @@ } } -void ReadAnythingPageHandler::ShowUI() { - delegate_->OnUIShown(); +void ReadAnythingPageHandler::OnUIReady() { + delegate_->OnUIReady(); } void ReadAnythingPageHandler::OnContentUpdated(
diff --git a/chrome/browser/ui/webui/side_panel/read_anything/read_anything_page_handler.h b/chrome/browser/ui/webui/side_panel/read_anything/read_anything_page_handler.h index e970dd6..9565f74 100644 --- a/chrome/browser/ui/webui/side_panel/read_anything/read_anything_page_handler.h +++ b/chrome/browser/ui/webui/side_panel/read_anything/read_anything_page_handler.h
@@ -34,7 +34,7 @@ public: class Delegate { public: - virtual void OnUIShown() = 0; + virtual void OnUIReady() = 0; }; explicit ReadAnythingPageHandler(mojo::PendingRemote<Page> page, @@ -44,7 +44,7 @@ ~ReadAnythingPageHandler() override; // PageHandler: - void ShowUI() override; + void OnUIReady() override; // ReadAnythingModel::Observer: void OnFontNameUpdated(const std::string& new_font_name) override; @@ -52,6 +52,8 @@ const std::vector<ContentNodePtr>& content_nodes) override; private: + // ReadAnythingPageHandler::Delegate is owned by ReadAnythingCoordinator which + // is a browser user data, so |delegate_| has the same lifetime as |browser_|. raw_ptr<ReadAnythingPageHandler::Delegate> delegate_; Browser* browser_;
diff --git a/chrome/browser/web_applications/commands/web_app_command.cc b/chrome/browser/web_applications/commands/web_app_command.cc index 01d2485..51029d3 100644 --- a/chrome/browser/web_applications/commands/web_app_command.cc +++ b/chrome/browser/web_applications/commands/web_app_command.cc
@@ -31,7 +31,7 @@ lock_type_(lock_type), lock_requests_(std::move(lock_requests)) {} -WebAppCommandLock::WebAppCommandLock(const WebAppCommandLock& lock) = default; +WebAppCommandLock::WebAppCommandLock(WebAppCommandLock&&) = default; WebAppCommandLock::~WebAppCommandLock() = default;
diff --git a/chrome/browser/web_applications/commands/web_app_command.h b/chrome/browser/web_applications/commands/web_app_command.h index 2e7cac02..ff13df7b 100644 --- a/chrome/browser/web_applications/commands/web_app_command.h +++ b/chrome/browser/web_applications/commands/web_app_command.h
@@ -23,7 +23,11 @@ using LockRequestSet = base::flat_set<content::DisjointRangeLockManager::LeveledLockRequest>; - WebAppCommandLock(const WebAppCommandLock& lock); + WebAppCommandLock(WebAppCommandLock&&); + + WebAppCommandLock(const WebAppCommandLock&) = delete; + WebAppCommandLock& operator=(const WebAppCommandLock&) = delete; + ~WebAppCommandLock(); // Creates a lock that guarantees isolation against all commands. @@ -70,9 +74,9 @@ kMaxValue = kApp, }; - const base::flat_set<AppId> app_ids_{}; - const LockType lock_type_; - const LockRequestSet lock_requests_{}; + base::flat_set<AppId> app_ids_{}; + LockType lock_type_; + LockRequestSet lock_requests_{}; }; enum class CommandResult { kSuccess, kFailure, kShutdown };
diff --git a/chrome/build/win32.pgo.txt b/chrome/build/win32.pgo.txt index 133c8a3e..84605ce 100644 --- a/chrome/build/win32.pgo.txt +++ b/chrome/build/win32.pgo.txt
@@ -1 +1 @@ -chrome-win32-main-1651676308-108e8426e9aa6c87d82ffe8544a5a3d6ddc60331.profdata +chrome-win32-main-1651697635-bf6862dd7ebeb6d97ff8dcb3555314c4670c634d.profdata
diff --git a/chrome/build/win64.pgo.txt b/chrome/build/win64.pgo.txt index 12e8c1c..611918c2 100644 --- a/chrome/build/win64.pgo.txt +++ b/chrome/build/win64.pgo.txt
@@ -1 +1 @@ -chrome-win64-main-1651676308-01ab221780c76c9163b8206004985fb57b246048.profdata +chrome-win64-main-1651697635-9faa2ce2dd7296079b362fd175eb8d96ab826392.profdata
diff --git a/chrome/child/BUILD.gn b/chrome/child/BUILD.gn index 53df6c0c..0702617 100644 --- a/chrome/child/BUILD.gn +++ b/chrome/child/BUILD.gn
@@ -14,7 +14,6 @@ if (is_win) { sources += [ - "delay_load_failure_hook.cc", "v8_crashpad_support_win.cc", "v8_crashpad_support_win.h", ]
diff --git a/chrome/common/BUILD.gn b/chrome/common/BUILD.gn index 71de849..959bb4c 100644 --- a/chrome/common/BUILD.gn +++ b/chrome/common/BUILD.gn
@@ -99,9 +99,16 @@ deps = [ "//base" ] } +group("common") { + public_deps = [ ":common_lib" ] + if (is_win) { + public_deps += [ ":delay_load_support" ] + } +} + # Use a static library here because many test binaries depend on this but don't # require many files from it. This makes linking more efficient. -static_library("common") { +static_library("common_lib") { sources = [ "all_messages.h", "child_process_host_flags.h", @@ -680,6 +687,20 @@ } } +if (is_win) { + # delay load support must be a source_set to ensure that it has external + # linkage and will correctly emplace over the correct symbols in + # delayimp.lib at link time. + source_set("delay_load_support") { + sources = [ + "win/delay_load_failure_hook.cc", + "win/delay_load_failure_hook.h", + ] + + deps = [ "//base" ] + } +} + mojom("mojo_bindings") { disable_variants = true
diff --git a/chrome/common/win/BUILD.gn b/chrome/common/win/BUILD.gn index 23e0fcf..2741f40 100644 --- a/chrome/common/win/BUILD.gn +++ b/chrome/common/win/BUILD.gn
@@ -8,8 +8,8 @@ message_compiler("eventlog_messages") { visibility = [ - "//chrome/common", ":eventlog_provider", + "//chrome/common:common_lib", ] sources = [ "eventlog_messages.mc" ]
diff --git a/chrome/child/delay_load_failure_hook.cc b/chrome/common/win/delay_load_failure_hook.cc similarity index 80% rename from chrome/child/delay_load_failure_hook.cc rename to chrome/common/win/delay_load_failure_hook.cc index e0e622df..c896d80 100644 --- a/chrome/child/delay_load_failure_hook.cc +++ b/chrome/common/win/delay_load_failure_hook.cc
@@ -11,13 +11,19 @@ #include "base/debug/alias.h" #include "base/strings/string_util.h" +namespace chrome { + namespace { +bool g_hooks_enabled = true; + // Delay load failure hook that generates a crash report. By default a failure // to delay load will trigger an exception handled by the delay load runtime and // this won't generate a crash report. -extern "C" FARPROC WINAPI DelayLoadFailureHook(unsigned reason, - DelayLoadInfo* dll_info) { +FARPROC WINAPI DelayLoadFailureHook(unsigned reason, DelayLoadInfo* dll_info) { + if (!g_hooks_enabled) + return 0; + char dll_name[MAX_PATH]; base::strlcpy(dll_name, dll_info->szDll, std::size(dll_name)); // It's not an error if "bthprops.cpl" fails to be loaded, there's a custom @@ -36,10 +42,16 @@ } // namespace +void DisableDelayLoadFailureHooksForCurrentModule() { + g_hooks_enabled = false; +} + +} // namespace chrome + // Set the delay load failure hook to the function above. // // The |__pfnDliFailureHook2| failure notification hook gets called // automatically by the delay load runtime in case of failure, see // https://docs.microsoft.com/en-us/cpp/build/reference/failure-hooks?view=vs-2019 // for more information about this. -extern "C" const PfnDliHook __pfnDliFailureHook2 = DelayLoadFailureHook; +extern "C" const PfnDliHook __pfnDliFailureHook2 = chrome::DelayLoadFailureHook;
diff --git a/chrome/common/win/delay_load_failure_hook.h b/chrome/common/win/delay_load_failure_hook.h new file mode 100644 index 0000000..873e3a3 --- /dev/null +++ b/chrome/common/win/delay_load_failure_hook.h
@@ -0,0 +1,16 @@ +// Copyright 2022 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#ifndef CHROME_COMMON_WIN_DELAY_LOAD_FAILURE_HOOK_H_ +#define CHROME_COMMON_WIN_DELAY_LOAD_FAILURE_HOOK_H_ + +namespace chrome { + +// This should be called early in process startup (before any delay load +// failures) to disable the delay load hooks for the current module. +void DisableDelayLoadFailureHooksForCurrentModule(); + +} // namespace chrome + +#endif // CHROME_COMMON_WIN_DELAY_LOAD_FAILURE_HOOK_H_
diff --git a/chrome/common/win/delay_load_failure_hook_unittest.cc b/chrome/common/win/delay_load_failure_hook_unittest.cc new file mode 100644 index 0000000..bc3cdde --- /dev/null +++ b/chrome/common/win/delay_load_failure_hook_unittest.cc
@@ -0,0 +1,15 @@ +// Copyright 2022 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#include <windows.h> + +#include <delayimp.h> + +#include "testing/gtest/include/gtest/gtest.h" + +TEST(ChromeDelayLoadHookTest, HooksAreSetAtLinkTime) { + // This test verifies that delay load hooks are correctly in place for the + // current module. + EXPECT_NE(__pfnDliFailureHook2, nullptr); +}
diff --git a/chrome/renderer/cart/commerce_hint_agent.cc b/chrome/renderer/cart/commerce_hint_agent.cc index b702c35..f9c5dbb 100644 --- a/chrome/renderer/cart/commerce_hint_agent.cc +++ b/chrome/renderer/cart/commerce_hint_agent.cc
@@ -4,6 +4,7 @@ #include "chrome/renderer/cart/commerce_hint_agent.h" +#include "base/features.h" #include "base/json/json_reader.h" #include "base/json/json_writer.h" #include "base/metrics/field_trial_params.h" @@ -856,6 +857,15 @@ if (!url.SchemeIsHTTPOrHTTPS()) return; + // The rest of this method is not concerned with data URLs but makes a copy of + // the URL which can be expensive for large data URLs. + // TODO(crbug.com/1321924): Clean up this method to avoid copies once this + // optimization has been measured in the field and launches. + if (base::FeatureList::IsEnabled(base::features::kOptimizeDataUrls) && + request.Url().ProtocolIs(url::kDataScheme)) { + return; + } + // Only check XHR POST requests for add-to-cart. // Other add-to-cart matches like navigation is handled in // DidStartNavigation(). Some sites use GET requests though, so special-case
diff --git a/chrome/renderer/extensions/chrome_extensions_renderer_client.cc b/chrome/renderer/extensions/chrome_extensions_renderer_client.cc index 175236de..c152ef36 100644 --- a/chrome/renderer/extensions/chrome_extensions_renderer_client.cc +++ b/chrome/renderer/extensions/chrome_extensions_renderer_client.cc
@@ -9,6 +9,7 @@ #include "base/bind.h" #include "base/command_line.h" +#include "base/features.h" #include "base/lazy_instance.h" #include "base/metrics/histogram_functions.h" #include "base/stl_util.h" @@ -228,7 +229,6 @@ const url::Origin* initiator_origin, GURL* new_url) { std::string extension_id; - GURL request_url(url); if (initiator_origin && initiator_origin->scheme() == extensions::kExtensionScheme) { extension_id = initiator_origin->host(); @@ -251,6 +251,12 @@ } } + // The rest of this method is only concerned with extensions URLs. + if (base::FeatureList::IsEnabled(base::features::kOptimizeDataUrls) && + !url.ProtocolIs(extensions::kExtensionScheme)) { + return; + } + if (url.ProtocolIs(extensions::kExtensionScheme) && !resource_request_policy_->CanRequestResource( GURL(url), frame, transition_type, @@ -259,6 +265,7 @@ } // TODO(https://crbug.com/588766): Remove metrics after bug is fixed. + GURL request_url(url); if (url.ProtocolIs(extensions::kExtensionScheme) && request_url.host_piece() == extension_misc::kDocsOfflineExtensionId) { if (!ukm_recorder_) {
diff --git a/chrome/renderer/safe_browsing/phishing_classifier_delegate_browsertest.cc b/chrome/renderer/safe_browsing/phishing_classifier_delegate_browsertest.cc index 19c68397..8c36726 100644 --- a/chrome/renderer/safe_browsing/phishing_classifier_delegate_browsertest.cc +++ b/chrome/renderer/safe_browsing/phishing_classifier_delegate_browsertest.cc
@@ -128,8 +128,7 @@ MOCK_CONST_METHOD2( ApplyVisualTfLiteModel, void(const SkBitmap& bitmap, - base::OnceCallback<void(base::flat_map<std::string, double>)> - callback)); + base::OnceCallback<void(std::vector<double>)> callback)); MOCK_CONST_METHOD0(model_version, int()); MOCK_CONST_METHOD0(HasVisualTfLiteModel, bool()); MOCK_CONST_METHOD0(find_page_word_callback,
diff --git a/chrome/test/BUILD.gn b/chrome/test/BUILD.gn index 24a27fb..3ece5f8 100644 --- a/chrome/test/BUILD.gn +++ b/chrome/test/BUILD.gn
@@ -5829,6 +5829,7 @@ "../common/chrome_constants_win_unittest.cc", "../common/conflicts/module_watcher_win_unittest.cc", "../common/conflicts/remote_module_watcher_win_unittest.cc", + "../common/win/delay_load_failure_hook_unittest.cc", ] data += [ "$root_out_dir/chrome.exe" ]
diff --git a/chrome/test/data/webui/settings/cr_settings_browsertest.js b/chrome/test/data/webui/settings/cr_settings_browsertest.js index feb2a22..95d504d 100644 --- a/chrome/test/data/webui/settings/cr_settings_browsertest.js +++ b/chrome/test/data/webui/settings/cr_settings_browsertest.js
@@ -107,10 +107,6 @@ } }; -TEST_F('CrSettingsLanguagesPageTest', 'LanguageSettings', function() { - mocha.grep(languages_page_tests.TestNames.LanguageSettings).run(); -}); - TEST_F('CrSettingsLanguagesPageTest', 'Spellcheck', function() { mocha.grep(languages_page_tests.TestNames.Spellcheck).run(); });
diff --git a/chrome/test/data/webui/settings/languages_page_tests.ts b/chrome/test/data/webui/settings/languages_page_tests.ts index 03e0ee5..cd8bfa4 100644 --- a/chrome/test/data/webui/settings/languages_page_tests.ts +++ b/chrome/test/data/webui/settings/languages_page_tests.ts
@@ -5,14 +5,16 @@ // clang-format off import {flush} from 'chrome://resources/polymer/v3_0/polymer/polymer_bundled.min.js'; import {LanguageHelper, LanguagesBrowserProxyImpl, SettingsLanguagesPageElement} from 'chrome://settings/lazy_load.js'; -import {CrSettingsPrefs, IronCollapseElement, Router, routes} from 'chrome://settings/settings.js'; - +import {CrSettingsPrefs, Router, routes} from 'chrome://settings/settings.js'; // <if expr="not is_macosx"> import {loadTimeData, SettingsToggleButtonElement} from 'chrome://settings/settings.js'; import {assertDeepEquals} from 'chrome://webui-test/chai_assert.js'; // </if> -import {assertEquals, assertFalse, assertNotEquals, assertTrue} from 'chrome://webui-test/chai_assert.js'; +import {assertEquals, assertFalse, assertTrue} from 'chrome://webui-test/chai_assert.js'; +// <if expr="_google_chrome"> +import {assertNotEquals} from 'chrome://webui-test/chai_assert.js'; +// </if> // <if expr="not is_macosx"> import {FakeChromeEvent} from 'chrome://webui-test/fake_chrome_event.js'; @@ -28,9 +30,10 @@ const languages_page_tests = { TestNames: { - LanguageSettings: 'language_settings', Spellcheck: 'spellcheck_all', + // <if expr="_google_chrome"> SpellcheckOfficialBuild: 'spellcheck_official', + // </if> RestructuredLanguageSettings: 'restructured language settings', }, }; @@ -40,7 +43,6 @@ suite('languages page', function() { let languageHelper: LanguageHelper; let languagesPage: SettingsLanguagesPageElement; - let languagesCollapse: IronCollapseElement; let browserProxy: TestLanguagesBrowserProxy; suiteSetup(function() { @@ -73,11 +75,6 @@ document.body.appendChild(languagesPage); flush(); - languagesCollapse = - languagesPage.shadowRoot!.querySelector<IronCollapseElement>( - '#languagesCollapse')!; - languagesCollapse.opened = true; - languageHelper = languagesPage.languageHelper; return languageHelper.whenReady(); }); @@ -87,22 +84,6 @@ document.body.innerHTML = ''; }); - suite(languages_page_tests.TestNames.LanguageSettings, function() { - test('decoupled language subtitle', function() { - const secondaryText = languagesPage.shadowRoot!.querySelector( - '#languageSectionSecondaryText'); - // <if expr="is_win"> - // Set to English from FakeLanguageSettingsPrivate. - assertEquals( - secondaryText!.textContent!.trim(), 'English (United States)'); - // </if> - - // <if expr="not is_win"> - assertEquals(secondaryText, null); - // </if> - }); - }); - suite(languages_page_tests.TestNames.Spellcheck, function() { // <if expr="is_macosx"> test('structure', function() { @@ -327,6 +308,7 @@ // </if> }); + // <if expr="_google_chrome"> suite(languages_page_tests.TestNames.SpellcheckOfficialBuild, function() { test('enabling and disabling the spelling service', () => { const previousValue = @@ -339,6 +321,7 @@ languagesPage.prefs.spellcheck.use_spelling_service.value); }); }); + // </if> }); suite(languages_page_tests.TestNames.RestructuredLanguageSettings, function() { @@ -387,7 +370,6 @@ }); test('languageSubpageTriggerVisible', function() { - assertFalse(isChildVisible(languagesPage, '#languagesCollapse')); assertTrue(isChildVisible(languagesPage, '#languagesSubpageTrigger')); });
diff --git a/chrome/test/data/webui/side_panel/read_anything/test_read_anything_api_proxy.ts b/chrome/test/data/webui/side_panel/read_anything/test_read_anything_api_proxy.ts index 5ae43dc..a4007fe 100644 --- a/chrome/test/data/webui/side_panel/read_anything/test_read_anything_api_proxy.ts +++ b/chrome/test/data/webui/side_panel/read_anything/test_read_anything_api_proxy.ts
@@ -13,7 +13,7 @@ constructor() { super([ - 'showUI', + 'onUIReady', ]); this.callbackRouter = new PageCallbackRouter(); @@ -29,7 +29,7 @@ return this.callbackRouterRemote; } - showUI() { - this.methodCalled('showUI'); + onUIReady() { + this.methodCalled('onUIReady'); } }
diff --git a/chromecast/media/cma/backend/mixer/mixer_input.cc b/chromecast/media/cma/backend/mixer/mixer_input.cc index 5e5f7fc..99ec25bd5 100644 --- a/chromecast/media/cma/backend/mixer/mixer_input.cc +++ b/chromecast/media/cma/backend/mixer/mixer_input.cc
@@ -262,7 +262,10 @@ mixer_rendering_delay_ = rendering_delay; // resampler_->BufferedFrames() gives incorrect values in the read callback, // so track the number of buffered frames ourselves. - resampler_buffered_frames_ = resampler_->BufferedFrames(); + // Based on testing, the buffered frames reported by SincResampler does not + // include the delay incurred by the filter kernel, so add it explicitly. + resampler_buffered_frames_ = + resampler_->BufferedFrames() + ::media::SincResampler::kKernelSize / 2; filled_for_resampler_ = 0; tried_to_fill_resampler_ = false; resampler_->Resample(num_frames, dest);
diff --git a/components/history_clusters_strings.grdp b/components/history_clusters_strings.grdp index d5b9b11..a47c655 100644 --- a/components/history_clusters_strings.grdp +++ b/components/history_clusters_strings.grdp
@@ -54,4 +54,7 @@ <message name="IDS_HISTORY_CLUSTERS_SHOW_MORE_BUTTON_LABEL" desc="A label for the button that expands the view showing more history items."> Show more </message> + <message name="IDS_HISTORY_CLUSTERS_SEARCH_YOUR_JOURNEYS" desc="A label for the hint text for the search box in Chrome Journeys." formatter_data="android_java"> + Search your Journeys + </message> </grit-part>
diff --git a/components/history_clusters_strings_grdp/IDS_HISTORY_CLUSTERS_SEARCH_YOUR_JOURNEYS.png.sha1 b/components/history_clusters_strings_grdp/IDS_HISTORY_CLUSTERS_SEARCH_YOUR_JOURNEYS.png.sha1 new file mode 100644 index 0000000..82278fa --- /dev/null +++ b/components/history_clusters_strings_grdp/IDS_HISTORY_CLUSTERS_SEARCH_YOUR_JOURNEYS.png.sha1
@@ -0,0 +1 @@ +e68313f5e34b7db95decd346ee5660595f4311fa \ No newline at end of file
diff --git a/components/metrics/field_trials_provider_unittest.cc b/components/metrics/field_trials_provider_unittest.cc index e7d934f..4341b01 100644 --- a/components/metrics/field_trials_provider_unittest.cc +++ b/components/metrics/field_trials_provider_unittest.cc
@@ -15,13 +15,19 @@ namespace { -const ActiveGroupId kFieldTrialIds[] = {{37, 43}, {13, 47}, {23, 17}}; -const ActiveGroupId kSyntheticTrialIds[] = {{55, 15}, {66, 16}}; -const ActiveGroupId kAllTrialIds[] = {{37, 43}, - {13, 47}, - {23, 17}, - {55, 15}, - {66, 16}}; +const ActiveGroupId kFieldTrialIds[] = {MakeActiveGroupId("Trial1", "Group1"), + MakeActiveGroupId("Trial2", "Group2"), + MakeActiveGroupId("Trial3", "Group3")}; +const SyntheticTrialGroup kSyntheticFieldTrials[] = { + SyntheticTrialGroup("Synthetic1", + "SyntheticGroup1", + variations::SyntheticTrialAnnotationMode::kNextLog), + SyntheticTrialGroup("Synthetic2", + "SyntheticGroup2", + variations::SyntheticTrialAnnotationMode::kNextLog)}; +const ActiveGroupId kAllTrialIds[] = { + kFieldTrialIds[0], kFieldTrialIds[1], kFieldTrialIds[2], + kSyntheticFieldTrials[0].id(), kSyntheticFieldTrials[1].id()}; class TestProvider : public FieldTrialsProvider { public: @@ -60,16 +66,15 @@ protected: // Register trials which should get recorded. void RegisterExpectedSyntheticTrials() { - for (const ActiveGroupId& id : kSyntheticTrialIds) { - registry_.RegisterSyntheticFieldTrial(SyntheticTrialGroup( - id.name, id.group, - variations::SyntheticTrialAnnotationMode::kNextLog)); + for (const SyntheticTrialGroup& synthetic_trial : kSyntheticFieldTrials) { + registry_.RegisterSyntheticFieldTrial(synthetic_trial); } } // Register trial which shouldn't get recorded. void RegisterExtraSyntheticTrial() { registry_.RegisterSyntheticFieldTrial(SyntheticTrialGroup( - 100, 1000, variations::SyntheticTrialAnnotationMode::kNextLog)); + "ExtraSynthetic", "ExtraGroup", + variations::SyntheticTrialAnnotationMode::kNextLog)); } // Waits until base::TimeTicks::Now() no longer equals |value|. This should
diff --git a/components/metrics/metrics_service_accessor.cc b/components/metrics/metrics_service_accessor.cc index 3a3d439..897f5a58 100644 --- a/components/metrics/metrics_service_accessor.cc +++ b/components/metrics/metrics_service_accessor.cc
@@ -48,21 +48,10 @@ base::StringPiece trial_name, base::StringPiece group_name, variations::SyntheticTrialAnnotationMode annotation_mode) { - return RegisterSyntheticFieldTrialWithNameAndGroupHash( - metrics_service, variations::HashName(trial_name), - variations::HashName(group_name), annotation_mode); -} - -// static -bool MetricsServiceAccessor::RegisterSyntheticFieldTrialWithNameAndGroupHash( - MetricsService* metrics_service, - uint32_t trial_name_hash, - uint32_t group_name_hash, - variations::SyntheticTrialAnnotationMode annotation_mode) { if (!metrics_service) return false; - variations::SyntheticTrialGroup trial_group(trial_name_hash, group_name_hash, + variations::SyntheticTrialGroup trial_group(trial_name, group_name, annotation_mode); metrics_service->GetSyntheticTrialRegistry()->RegisterSyntheticFieldTrial( trial_group);
diff --git a/components/metrics/metrics_service_accessor.h b/components/metrics/metrics_service_accessor.h index 621ecab..3744528 100644 --- a/components/metrics/metrics_service_accessor.h +++ b/components/metrics/metrics_service_accessor.h
@@ -51,14 +51,6 @@ base::StringPiece group_name, variations::SyntheticTrialAnnotationMode annotation_mode); - // Same as RegisterSyntheticFieldTrial above, but takes in the trial and group - // names as hashes rather than computing those hashes from the strings. - static bool RegisterSyntheticFieldTrialWithNameAndGroupHash( - MetricsService* metrics_service, - uint32_t trial_name_hash, - uint32_t group_name_hash, - variations::SyntheticTrialAnnotationMode annotation_mode); - // IsMetricsReportingEnabled() in non-official builds unconditionally returns // false. This results in different behavior for tests running in official vs // non-official builds. To get consistent behavior call this with true, which
diff --git a/components/optimization_guide/content/browser/page_content_annotations_model_manager.cc b/components/optimization_guide/content/browser/page_content_annotations_model_manager.cc index 7568a9d..daf9921f 100644 --- a/components/optimization_guide/content/browser/page_content_annotations_model_manager.cc +++ b/components/optimization_guide/content/browser/page_content_annotations_model_manager.cc
@@ -118,7 +118,8 @@ } void PageContentAnnotationsModelManager::SetUpPageEntitiesModel( - OptimizationGuideModelProvider* optimization_guide_model_provider) { + OptimizationGuideModelProvider* optimization_guide_model_provider, + base::OnceCallback<void(bool)> callback) { LOCAL_HISTOGRAM_BOOLEAN( "OptimizationGuide.PageContentAnnotationsModelManager." "PageEntitiesModelRequested", @@ -140,9 +141,19 @@ page_entities_model_executor_ = std::make_unique<PageEntitiesModelExecutorImpl>( optimization_guide_model_provider, background_task_runner); + + page_entities_model_executor_->AddOnModelUpdatedCallback( + base::BindOnce(std::move(callback), true)); +#else + std::move(callback).Run(false); #endif } +void PageContentAnnotationsModelManager::SetUpPageEntitiesModel( + OptimizationGuideModelProvider* optimization_guide_model_provider) { + SetUpPageEntitiesModel(optimization_guide_model_provider, base::DoNothing()); +} + void PageContentAnnotationsModelManager:: OverridePageEntitiesModelExecutorForTesting( std::unique_ptr<PageEntitiesModelExecutor> @@ -160,7 +171,7 @@ "PageEntitiesModelExecutionRequested", true); if (page_entities_model_executor_) { - page_entities_model_executor_->HumanReadableExecuteModelWithInput( + page_entities_model_executor_->ExecuteModelWithInput( text, base::BindOnce(&PageContentAnnotationsModelManager:: OnPageEntitiesModelExecutionCompleted, @@ -186,15 +197,8 @@ current_annotations = GetOrCreateCurrentContentModelAnnotations( std::move(current_annotations)); - // Determine the entities with the highest weights. - std::vector<ScoredEntityMetadata> entity_candidates = std::move(*output); - std::sort(entity_candidates.begin(), entity_candidates.end(), - [](const ScoredEntityMetadata& a, const ScoredEntityMetadata& b) { - return a.score > b.score; - }); - // Add the top entities to the working current annotations. - for (const auto& entity : entity_candidates) { + for (const auto& entity : *output) { if (current_annotations->entities.size() >= kMaxPageEntities) { break; } @@ -526,7 +530,16 @@ } } - // TODO(crbug/1278828): Add support for page entities. + if (type == AnnotationType::kPageEntities) { + if (page_entities_model_executor_) { + page_entities_model_executor_->AddOnModelUpdatedCallback( + base::BindOnce(std::move(callback), true)); + } else { + SetUpPageEntitiesModel(optimization_guide_model_provider_, + std::move(callback)); + } + return; + } std::move(callback).Run(false); } @@ -542,7 +555,9 @@ page_visibility_model_executor_) { return page_visibility_model_executor_->GetModelInfo(); } - // TODO(crbug/1278828): Add support for page entities. + if (type == AnnotationType::kPageEntities && page_entities_model_executor_) { + return page_entities_model_executor_->GetModelInfo(); + } return absl::nullopt; } @@ -634,12 +649,16 @@ return; } - // TODO(crbug/1278828): Add support for page entities. if (job->type() == AnnotationType::kPageEntities) { - job->FillWithNullOutputs(); - job->OnComplete(); - job.reset(); - std::move(on_job_complete_callback).Run(); + if (!page_entities_model_executor_) { + job->FillWithNullOutputs(); + job->OnComplete(); + job.reset(); + std::move(on_job_complete_callback).Run(); + return; + } + page_entities_model_executor_->ExecuteJob( + std::move(on_job_complete_callback), std::move(job)); return; } NOTREACHED();
diff --git a/components/optimization_guide/content/browser/page_content_annotations_model_manager.h b/components/optimization_guide/content/browser/page_content_annotations_model_manager.h index 98d2fb7..fb05111 100644 --- a/components/optimization_guide/content/browser/page_content_annotations_model_manager.h +++ b/components/optimization_guide/content/browser/page_content_annotations_model_manager.h
@@ -121,6 +121,11 @@ // only be run at construction. void SetUpPageEntitiesModel(OptimizationGuideModelProvider* model_provider); + // Same as above but runs |callback(true)| when the model executor has a model + // file or |callback(false)| if the model executor is not available. + void SetUpPageEntitiesModel(OptimizationGuideModelProvider* model_provider, + base::OnceCallback<void(bool)> callback); + // Requests to execute the page entities model with |text|, populate // |current_annotations| with detected entities on success, and proceed to // execute any subsequent models.
diff --git a/components/optimization_guide/content/browser/page_content_annotations_model_manager_unittest.cc b/components/optimization_guide/content/browser/page_content_annotations_model_manager_unittest.cc index 2a739af..5530939 100644 --- a/components/optimization_guide/content/browser/page_content_annotations_model_manager_unittest.cc +++ b/components/optimization_guide/content/browser/page_content_annotations_model_manager_unittest.cc
@@ -93,7 +93,7 @@ : entries_(entries), entity_metadata_(entity_metadata) {} ~FakePageEntitiesModelExecutor() override = default; - void HumanReadableExecuteModelWithInput( + void ExecuteModelWithInput( const std::string& text, PageEntitiesMetadataModelExecutedCallback callback) override { auto it = entries_.find(text); @@ -110,6 +110,14 @@ : absl::nullopt); } + void AddOnModelUpdatedCallback(base::OnceClosure callback) override { + std::move(callback).Run(); + } + + absl::optional<ModelInfo> GetModelInfo() const override { + return absl::nullopt; + } + private: base::flat_map<std::string, std::vector<ScoredEntityMetadata>> entries_; base::flat_map<std::string, EntityMetadata> entity_metadata_; @@ -701,6 +709,24 @@ } TEST_F(PageContentAnnotationsModelManagerTest, BatchAnnotate_PageEntities) { + std::vector<ScoredEntityMetadata> input1_entities = { + ScoredEntityMetadata(0.5, EntityMetadata("cat", "cat", {})), + ScoredEntityMetadata(0.6, EntityMetadata("dog", "dog", {})), + }; + std::vector<ScoredEntityMetadata> input2_entities = { + ScoredEntityMetadata(0.7, EntityMetadata("fish", "fish", {})), + }; + SetPageEntitiesModelExecutor( + { + {"input1", input1_entities}, + {"input2", input2_entities}, + {"other input", + { + ScoredEntityMetadata(0.7, EntityMetadata("other", "other", {})), + }}, + }, + /*entity_metadata=*/{}); + base::HistogramTester histogram_tester; base::RunLoop run_loop; std::vector<BatchAnnotationResult> result; @@ -713,15 +739,15 @@ }, &run_loop, &result); - model_manager()->Annotate(std::move(callback), {"input"}, + model_manager()->Annotate(std::move(callback), {"input1", "input2"}, AnnotationType::kPageEntities); histogram_tester.ExpectUniqueSample( "OptimizationGuide.PageContentAnnotations.BatchRequestedSize." "PageEntities", - 1, 1); + 2, 1); histogram_tester.ExpectUniqueSample( "OptimizationGuide.PageContentAnnotations.BatchSuccess.PageEntities", - false, 1); + true, 1); histogram_tester.ExpectTotalCount( "OptimizationGuide.PageContentAnnotations.JobExecutionTime.PageEntities", 1); @@ -731,11 +757,19 @@ run_loop.Run(); - ASSERT_EQ(result.size(), 1U); - EXPECT_EQ(result[0].input(), "input"); + ASSERT_EQ(result.size(), 2U); + + EXPECT_EQ(result[0].input(), "input1"); EXPECT_EQ(result[0].topics(), absl::nullopt); - EXPECT_EQ(result[0].entities(), absl::nullopt); + EXPECT_EQ(result[0].entities(), absl::make_optional(input1_entities)); EXPECT_EQ(result[0].visibility_score(), absl::nullopt); + EXPECT_EQ(result[0].type(), AnnotationType::kPageEntities); + + EXPECT_EQ(result[1].input(), "input2"); + EXPECT_EQ(result[1].topics(), absl::nullopt); + EXPECT_EQ(result[1].entities(), absl::make_optional(input2_entities)); + EXPECT_EQ(result[1].visibility_score(), absl::nullopt); + EXPECT_EQ(result[1].type(), AnnotationType::kPageEntities); } // TODO(crbug.com/1286473): Flaky on Chrome OS. @@ -1016,6 +1050,27 @@ EXPECT_TRUE(visibility_callback_success); } +TEST_F(PageContentAnnotationsModelManagerTest, + NotifyWhenModelAvailable_EntitiesOnly) { + SetPageEntitiesModelExecutor(/*entries=*/{}, /*entity_metadata=*/{}); + + base::RunLoop run_loop; + bool success = false; + + model_manager()->RequestAndNotifyWhenModelAvailable( + AnnotationType::kPageEntities, + base::BindOnce( + [](base::RunLoop* run_loop, bool* out_success, bool success) { + *out_success = success; + run_loop->Quit(); + }, + &run_loop, &success)); + + run_loop.Run(); + + EXPECT_TRUE(success); +} + TEST_F(PageContentAnnotationsModelManagerTest, NotifyWhenModelAvailable_Both) { proto::Any any_metadata; any_metadata.set_type_url(
diff --git a/components/optimization_guide/content/browser/page_content_annotations_web_contents_observer.cc b/components/optimization_guide/content/browser/page_content_annotations_web_contents_observer.cc index 1ed5649e..bb0b348 100644 --- a/components/optimization_guide/content/browser/page_content_annotations_web_contents_observer.cc +++ b/components/optimization_guide/content/browser/page_content_annotations_web_contents_observer.cc
@@ -6,6 +6,7 @@ #include "base/bind.h" #include "base/i18n/case_conversion.h" +#include "base/metrics/histogram_functions.h" #include "base/strings/utf_string_conversions.h" #include "components/google/core/common/google_util.h" #include "components/optimization_guide/content/browser/optimization_guide_decider.h" @@ -25,11 +26,18 @@ // Returns search metadata if |url| is a valid Search URL according to // |template_url_service|. absl::optional<SearchMetadata> ExtractSearchMetadata( - const TemplateURLService* template_url_service, + TemplateURLService* template_url_service, const GURL& url) { if (!template_url_service) return absl::nullopt; + if (!template_url_service->loaded()) { + if (switches::ShouldLogPageContentAnnotationsInput()) { + LOG(ERROR) << "Template URL Service not loaded"; + } + return absl::nullopt; + } + const TemplateURL* template_url = template_url_service->GetTemplateURLForHost(url.host()); const SearchTermsData& search_terms_data = @@ -40,16 +48,27 @@ template_url->ExtractSearchTermsFromURL( url, search_terms_data, &search_terms) && !search_terms.empty(); - if (!is_valid_search_url) + if (!is_valid_search_url) { + if (switches::ShouldLogPageContentAnnotationsInput()) { + LOG(ERROR) << "Url " << url << " is not a valid search URL"; + } return absl::nullopt; + } const std::u16string& normalized_search_query = base::i18n::ToLower(base::CollapseWhitespace(search_terms, false)); TemplateURLRef::SearchTermsArgs search_terms_args(normalized_search_query); const TemplateURLRef& search_url_ref = template_url->url_ref(); - if (!search_url_ref.SupportsReplacement(search_terms_data)) + if (!search_url_ref.SupportsReplacement(search_terms_data)) { + if (switches::ShouldLogPageContentAnnotationsInput()) { + LOG(ERROR) << "Url " << url << " does not support replacement"; + } return absl::nullopt; + } + if (switches::ShouldLogPageContentAnnotationsInput()) { + LOG(ERROR) << "Url " << url << " is a valid search URL"; + } return SearchMetadata{ GURL(search_url_ref.ReplaceSearchTerms(search_terms_args, search_terms_data)), @@ -170,6 +189,11 @@ if (is_google_search_url || optimization_guide::features:: ShouldPersistSearchMetadataForNonGoogleSearches()) { + base::UmaHistogramBoolean( + "OptimizationGuide.PageContentAnnotations." + "TemplateURLServiceLoadedAtNavigationFinish", + template_url_service_ && template_url_service_->loaded()); + absl::optional<SearchMetadata> search_metadata = ExtractSearchMetadata( template_url_service_, navigation_handle->GetURL()); if (search_metadata) {
diff --git a/components/optimization_guide/content/browser/page_content_annotations_web_contents_observer.h b/components/optimization_guide/content/browser/page_content_annotations_web_contents_observer.h index de08469..231d456 100644 --- a/components/optimization_guide/content/browser/page_content_annotations_web_contents_observer.h +++ b/components/optimization_guide/content/browser/page_content_annotations_web_contents_observer.h
@@ -74,7 +74,7 @@ raw_ptr<PageContentAnnotationsService> page_content_annotations_service_; // Not owned. Guaranteed to outlive |this|. - raw_ptr<const TemplateURLService> template_url_service_; + raw_ptr<TemplateURLService> template_url_service_; // Not owned. Guaranteed to outlive |this|. raw_ptr<OptimizationGuideDecider> optimization_guide_decider_;
diff --git a/components/optimization_guide/content/browser/page_content_annotations_web_contents_observer_unittest.cc b/components/optimization_guide/content/browser/page_content_annotations_web_contents_observer_unittest.cc index a862b4f3..736abad 100644 --- a/components/optimization_guide/content/browser/page_content_annotations_web_contents_observer_unittest.cc +++ b/components/optimization_guide/content/browser/page_content_annotations_web_contents_observer_unittest.cc
@@ -266,6 +266,10 @@ return helper()->MaybeRequestFrameTextDump(&navigation_handle); } + void SetTemplateURLServiceLoaded(bool loaded) { + template_url_service_->set_loaded(loaded); + } + private: base::test::ScopedFeatureList scoped_feature_list_; std::unique_ptr<TestOptimizationGuideModelProvider> @@ -383,6 +387,8 @@ TEST_F(PageContentAnnotationsWebContentsObserverTest, SRPURLsAnnotateSearchTerms) { + base::HistogramTester histogram_tester; + // Navigate and commit so there is an entry. content::NavigationSimulator::NavigateAndCommitFromBrowser( web_contents(), GURL("http://default-engine.com/search?q=a")); @@ -401,10 +407,17 @@ EXPECT_EQ(last_search_metadata_persisted->normalized_url, GURL("http://default-engine.com/search?q=a")); EXPECT_EQ(last_search_metadata_persisted->search_terms, u"a"); + + histogram_tester.ExpectUniqueSample( + "OptimizationGuide.PageContentAnnotations." + "TemplateURLServiceLoadedAtNavigationFinish", + true, 1); } TEST_F(PageContentAnnotationsWebContentsObserverTest, NonGoogleSRPURLsAnnotateSearchTerms) { + base::HistogramTester histogram_tester; + // Navigate and commit so there is an entry. content::NavigationSimulator::NavigateAndCommitFromBrowser( web_contents(), GURL("http://non-default-engine.com/?q=a")); @@ -423,6 +436,11 @@ EXPECT_EQ(last_search_metadata_persisted->normalized_url, GURL("http://non-default-engine.com/?q=a")); EXPECT_EQ(last_search_metadata_persisted->search_terms, u"a"); + + histogram_tester.ExpectUniqueSample( + "OptimizationGuide.PageContentAnnotations." + "TemplateURLServiceLoadedAtNavigationFinish", + true, 1); } TEST_F(PageContentAnnotationsWebContentsObserverTest, @@ -602,6 +620,41 @@ ASSERT_FALSE(last_search_metadata_persisted.has_value()); } +TEST_F( + PageContentAnnotationsWebContentsObserverOnlyPersistGoogleSearchMetadataTest, + SRPURLsAnnotateTitleIfTemplateURLServiceNotLoaded) { + SetTemplateURLServiceLoaded(false); + + base::HistogramTester histogram_tester; + + // Navigate and commit so there is an entry. + content::NavigationSimulator::NavigateAndCommitFromBrowser( + web_contents(), GURL("http://default-engine.com/search?q=a")); + + // Set title. + std::u16string title(u"Title"); + web_contents()->UpdateTitleForEntry(controller().GetLastCommittedEntry(), + title); + + // We don't know what the search terms are so no search metadata is persisted. + absl::optional<SearchMetadata> last_search_metadata_persisted = + service()->last_search_metadata_persisted(); + ASSERT_FALSE(last_search_metadata_persisted.has_value()); + + // The title should be what is requested to be annotated. + absl::optional<HistoryVisit> last_annotation_request = + service()->last_annotation_request(); + EXPECT_TRUE(last_annotation_request.has_value()); + EXPECT_EQ(last_annotation_request->url, + GURL("http://default-engine.com/search?q=a")); + EXPECT_EQ(last_annotation_request->text_to_annotate, "Title"); + + histogram_tester.ExpectUniqueSample( + "OptimizationGuide.PageContentAnnotations." + "TemplateURLServiceLoadedAtNavigationFinish", + false, 1); +} + class PageContentAnnotationsWebContentsObserverRemotePageEntitiesTest : public PageContentAnnotationsWebContentsObserverTest { public:
diff --git a/components/optimization_guide/core/BUILD.gn b/components/optimization_guide/core/BUILD.gn index da388e5..34917144 100644 --- a/components/optimization_guide/core/BUILD.gn +++ b/components/optimization_guide/core/BUILD.gn
@@ -187,6 +187,7 @@ "model_validator.h", "page_content_annotation_job_executor.cc", "page_content_annotation_job_executor.h", + "page_entities_model_executor.cc", "page_entities_model_executor.h", "page_topics_model_executor.cc", "page_topics_model_executor.h",
diff --git a/components/optimization_guide/core/page_content_annotations_common.h b/components/optimization_guide/core/page_content_annotations_common.h index 0a7f14c..f2aa257 100644 --- a/components/optimization_guide/core/page_content_annotations_common.h +++ b/components/optimization_guide/core/page_content_annotations_common.h
@@ -29,9 +29,9 @@ // The input will be annotated for the visibility of the content. kContentVisibility, - // The input will be annotated with the entity IDs on the page, for example - // listing the IDs of all the proper nouns on a page. To map the IDs back to - // human-readable strings, use `EntityMetadataProvider`. + // The input will be annotated with the entities on the page. If the entities + // will be persisted, make sure that only the entity IDs are persisted. To map + // the IDs back to human-readable strings, use `EntityMetadataProvider`. kPageEntities, };
diff --git a/components/optimization_guide/core/page_entities_model_executor.cc b/components/optimization_guide/core/page_entities_model_executor.cc new file mode 100644 index 0000000..7b5b978b --- /dev/null +++ b/components/optimization_guide/core/page_entities_model_executor.cc
@@ -0,0 +1,32 @@ +// Copyright 2022 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#include "components/optimization_guide/core/page_entities_model_executor.h" + +#include "base/bind.h" +#include "base/callback.h" + +namespace optimization_guide { + +void PageEntitiesModelExecutor::ExecuteOnSingleInput( + AnnotationType annotation_type, + const std::string& input, + base::OnceCallback<void(const BatchAnnotationResult&)> callback) { + DCHECK_EQ(annotation_type, AnnotationType::kPageEntities); + + ExecuteModelWithInput( + input, base::BindOnce( + [](const std::string& input, + base::OnceCallback<void(const BatchAnnotationResult&)> + pca_callback, + const absl::optional<std::vector<ScoredEntityMetadata>>& + entity_metadata) { + std::move(pca_callback) + .Run(BatchAnnotationResult::CreatePageEntitiesResult( + input, entity_metadata)); + }, + input, std::move(callback))); +} + +} // namespace optimization_guide
diff --git a/components/optimization_guide/core/page_entities_model_executor.h b/components/optimization_guide/core/page_entities_model_executor.h index 86fd964..2dca8a02 100644 --- a/components/optimization_guide/core/page_entities_model_executor.h +++ b/components/optimization_guide/core/page_entities_model_executor.h
@@ -10,6 +10,8 @@ #include "base/callback.h" #include "components/optimization_guide/core/entity_metadata.h" +#include "components/optimization_guide/core/model_info.h" +#include "components/optimization_guide/core/page_content_annotation_job_executor.h" #include "third_party/abseil-cpp/absl/types/optional.h" #include "third_party/tflite_support/src/tensorflow_lite_support/cc/task/core/category.h" @@ -17,7 +19,7 @@ // The PageEntitiesModelExecutor is responsible for executing the PAGE_ENTITIES // model. -class PageEntitiesModelExecutor { +class PageEntitiesModelExecutor : public PageContentAnnotationJobExecutor { public: virtual ~PageEntitiesModelExecutor() = default; @@ -27,7 +29,7 @@ // Annotates |text| with page entities likely represented on the page, // returning the entity metadata in the reader's locale with associated score. // Invokes |callback| when done. - virtual void HumanReadableExecuteModelWithInput( + virtual void ExecuteModelWithInput( const std::string& text, PageEntitiesMetadataModelExecutedCallback callback) = 0; @@ -39,6 +41,19 @@ virtual void GetMetadataForEntityId( const std::string& entity_id, PageEntitiesModelEntityMetadataRetrievedCallback callback) = 0; + + // Runs |callback| now if a model is loaded or the next time |OnModelUpdated| + // is called. + virtual void AddOnModelUpdatedCallback(base::OnceClosure callback) = 0; + + // Returns the ModelInfo for a currently loaded model, if available. + virtual absl::optional<ModelInfo> GetModelInfo() const = 0; + + // PageContentAnnotationJobExecutor: + void ExecuteOnSingleInput( + AnnotationType annotation_type, + const std::string& input, + base::OnceCallback<void(const BatchAnnotationResult&)> callback) override; }; } // namespace optimization_guide
diff --git a/components/optimization_guide/core/page_entities_model_executor_impl.cc b/components/optimization_guide/core/page_entities_model_executor_impl.cc index bbf144ee..71251a49 100644 --- a/components/optimization_guide/core/page_entities_model_executor_impl.cc +++ b/components/optimization_guide/core/page_entities_model_executor_impl.cc
@@ -4,6 +4,8 @@ #include "components/optimization_guide/core/page_entities_model_executor_impl.h" +#include <algorithm> + #include "base/metrics/histogram_functions.h" #include "base/no_destructor.h" #include "base/threading/sequenced_task_runner_handle.h" @@ -152,6 +154,14 @@ "ModelThreadExecutionLatency.PageEntities", annotate_timer.Elapsed()); } + + if (scored_md) { + // Determine the entities with the highest weights. + std::sort(scored_md->begin(), scored_md->end(), + [](const ScoredEntityMetadata& a, const ScoredEntityMetadata& b) { + return a.score > b.score; + }); + } reply_task_runner_->PostTask(FROM_HERE, base::BindOnce(std::move(callback), scored_md)); } @@ -226,20 +236,42 @@ std::move(entity_annotator_holder_)); } +void PageEntitiesModelExecutorImpl::AddOnModelUpdatedCallback( + base::OnceClosure callback) { + if (model_info_) { + std::move(callback).Run(); + return; + } + + // callbacks are not bound locally and are safe to be destroyed at any time. + on_model_updated_callbacks_.AddUnsafe(std::move(callback)); +} + void PageEntitiesModelExecutorImpl::OnModelUpdated( proto::OptimizationTarget optimization_target, const ModelInfo& model_info) { if (optimization_target != proto::OPTIMIZATION_TARGET_PAGE_ENTITIES) return; + model_info_ = model_info; + background_task_runner_->PostTask( FROM_HERE, base::BindOnce( &EntityAnnotatorHolder::CreateAndSetEntityAnnotatorOnBackgroundThread, entity_annotator_holder_->GetBackgroundWeakPtr(), model_info)); + + // Run any observing callbacks after the model file is posted to the + // model executor thread so that any model execution requests are posted to + // the model executor thread after the model update. + on_model_updated_callbacks_.Notify(); } -void PageEntitiesModelExecutorImpl::HumanReadableExecuteModelWithInput( +absl::optional<ModelInfo> PageEntitiesModelExecutorImpl::GetModelInfo() const { + return model_info_; +} + +void PageEntitiesModelExecutorImpl::ExecuteModelWithInput( const std::string& text, PageEntitiesMetadataModelExecutedCallback callback) { if (text.empty()) {
diff --git a/components/optimization_guide/core/page_entities_model_executor_impl.h b/components/optimization_guide/core/page_entities_model_executor_impl.h index dbec4c9..b355636 100644 --- a/components/optimization_guide/core/page_entities_model_executor_impl.h +++ b/components/optimization_guide/core/page_entities_model_executor_impl.h
@@ -5,6 +5,7 @@ #ifndef COMPONENTS_OPTIMIZATION_GUIDE_CORE_PAGE_ENTITIES_MODEL_EXECUTOR_IMPL_H_ #define COMPONENTS_OPTIMIZATION_GUIDE_CORE_PAGE_ENTITIES_MODEL_EXECUTOR_IMPL_H_ +#include "base/callback_list.h" #include "base/task/sequenced_task_runner.h" #include "base/task/task_traits.h" #include "base/task/thread_pool.h" @@ -108,13 +109,22 @@ PageEntitiesModelExecutorImpl& operator=( const PageEntitiesModelExecutorImpl&) = delete; + // TODO(crbug.com/1278828): Remove once src-internal is updated. + void HumanReadableExecuteModelWithInput( + const std::string& text, + PageEntitiesMetadataModelExecutedCallback callback) { + ExecuteModelWithInput(text, std::move(callback)); + } + // PageEntitiesModelExecutor: void GetMetadataForEntityId( const std::string& entity_id, PageEntitiesModelEntityMetadataRetrievedCallback callback) override; - void HumanReadableExecuteModelWithInput( + void ExecuteModelWithInput( const std::string& text, PageEntitiesMetadataModelExecutedCallback callback) override; + void AddOnModelUpdatedCallback(base::OnceClosure callback) override; + absl::optional<ModelInfo> GetModelInfo() const override; // OptimizationTargetModelObserver: void OnModelUpdated(proto::OptimizationTarget optimization_target, @@ -132,6 +142,13 @@ // The holder used to hold the annotator used to annotate entities. std::unique_ptr<EntityAnnotatorHolder> entity_annotator_holder_; + // The most recent model info given to |OnModelUpdated|. + absl::optional<ModelInfo> model_info_; + + // Populated with callbacks if |AddOnModelUpdatedCallback| is called before a + // model file is available, then is notified when |OnModelUpdated| is called. + base::OnceClosureList on_model_updated_callbacks_; + base::WeakPtrFactory<PageEntitiesModelExecutorImpl> weak_ptr_factory_{this}; };
diff --git a/components/optimization_guide/core/page_entities_model_executor_impl_unittest.cc b/components/optimization_guide/core/page_entities_model_executor_impl_unittest.cc index 964f7946..1857521 100644 --- a/components/optimization_guide/core/page_entities_model_executor_impl_unittest.cc +++ b/components/optimization_guide/core/page_entities_model_executor_impl_unittest.cc
@@ -84,12 +84,12 @@ task_environment_.RunUntilIdle(); } - absl::optional<std::vector<ScoredEntityMetadata>> ExecuteHumanReadableModel( + absl::optional<std::vector<ScoredEntityMetadata>> ExecuteModel( const std::string& text) { absl::optional<std::vector<ScoredEntityMetadata>> entity_metadata; base::RunLoop run_loop; - model_executor_->HumanReadableExecuteModelWithInput( + model_executor_->ExecuteModelWithInput( text, base::BindOnce( [](base::RunLoop* run_loop, absl::optional<std::vector<ScoredEntityMetadata>>* @@ -102,14 +102,6 @@ &run_loop, &entity_metadata)); run_loop.Run(); - // Sort the result by score to make validating the output easier. - if (entity_metadata) { - std::sort( - entity_metadata->begin(), entity_metadata->end(), - [](const ScoredEntityMetadata& a, const ScoredEntityMetadata& b) { - return a.score > b.score; - }); - } return entity_metadata; } @@ -133,6 +125,8 @@ return entity_metadata; } + PageEntitiesModelExecutor* model_executor() { return model_executor_.get(); } + ModelObserverTracker* model_observer_tracker() const { return model_observer_tracker_.get(); } @@ -166,7 +160,7 @@ // We expect that there will be no model to evaluate even for this input that // has output in the test model. - EXPECT_EQ(ExecuteHumanReadableModel("Taylor Swift singer"), absl::nullopt); + EXPECT_EQ(ExecuteModel("Taylor Swift singer"), absl::nullopt); histogram_tester.ExpectUniqueSample( "OptimizationGuide.PageEntitiesModelExecutor.CreatedSuccessfully", false, @@ -184,18 +178,18 @@ proto::FieldTrial garbage; garbage.SerializeToString(any.mutable_value()); - proto::PredictionModel model; - model.mutable_model()->set_download_url( - FilePathToString(GetModelTestDataDir().AppendASCII("model.tflite"))); - model.mutable_model_info()->set_version(123); - *model.mutable_model_info()->mutable_model_metadata() = any; - std::unique_ptr<ModelInfo> model_info = ModelInfo::Create(model); + std::unique_ptr<ModelInfo> model_info = + TestModelInfoBuilder() + .SetModelFilePath(GetModelTestDataDir().AppendASCII("model.tflite")) + .SetVersion(123) + .SetModelMetadata(any) + .Build(); ASSERT_TRUE(model_info); PushModelInfoToObservers(*model_info); // We expect that there will be no model to evaluate even for this input that // has output in the test model. - EXPECT_EQ(ExecuteHumanReadableModel("Taylor Swift singer"), absl::nullopt); + EXPECT_EQ(ExecuteModel("Taylor Swift singer"), absl::nullopt); histogram_tester.ExpectUniqueSample( "OptimizationGuide.PageEntitiesModelExecutor.CreatedSuccessfully", false, @@ -213,18 +207,18 @@ any.set_type_url(metadata.GetTypeName()); metadata.SerializeToString(any.mutable_value()); - proto::PredictionModel model; - model.mutable_model()->set_download_url( - FilePathToString(GetModelTestDataDir().AppendASCII("model.tflite"))); - model.mutable_model_info()->set_version(123); - *model.mutable_model_info()->mutable_model_metadata() = any; - std::unique_ptr<ModelInfo> model_info = ModelInfo::Create(model); + std::unique_ptr<ModelInfo> model_info = + TestModelInfoBuilder() + .SetModelFilePath(GetModelTestDataDir().AppendASCII("model.tflite")) + .SetVersion(123) + .SetModelMetadata(any) + .Build(); ASSERT_TRUE(model_info); PushModelInfoToObservers(*model_info); // We expect that there will be no model to evaluate even for this input that // has output in the test model. - EXPECT_EQ(ExecuteHumanReadableModel("Taylor Swift singer"), absl::nullopt); + EXPECT_EQ(ExecuteModel("Taylor Swift singer"), absl::nullopt); histogram_tester.ExpectUniqueSample( "OptimizationGuide.PageEntitiesModelExecutor.CreatedSuccessfully", false, @@ -236,6 +230,35 @@ 1); } +TEST_F(PageEntitiesModelExecutorImplTest, ModelInfoUpdated) { + bool callback_run = false; + model_executor()->AddOnModelUpdatedCallback( + base::BindOnce([](bool* flag) { *flag = true; }, &callback_run)); + + EXPECT_FALSE(callback_run); + EXPECT_FALSE(model_executor()->GetModelInfo()); + + std::unique_ptr<ModelInfo> model_info = + TestModelInfoBuilder() + .SetModelFilePath(GetModelTestDataDir().AppendASCII("test.tflite")) + .SetVersion(1337) + .Build(); + PushModelInfoToObservers(*model_info); + EXPECT_TRUE(callback_run); + + ASSERT_TRUE(model_executor()->GetModelInfo()); + EXPECT_EQ(model_executor()->GetModelInfo()->GetModelFilePath(), + model_info->GetModelFilePath()); + EXPECT_EQ(model_executor()->GetModelInfo()->GetVersion(), + model_info->GetVersion()); + + bool immediate_callback_run = false; + model_executor()->AddOnModelUpdatedCallback(base::BindOnce( + [](bool* flag) { *flag = true; }, &immediate_callback_run)); + // This callback should be run immediately because the model is loaded. + EXPECT_TRUE(immediate_callback_run); +} + TEST_F(PageEntitiesModelExecutorImplTest, CreateMissingFiles) { proto::Any any; proto::PageEntitiesModelMetadata metadata; @@ -268,26 +291,25 @@ for (const auto& missing_file_and_status : expected_additional_files) { base::HistogramTester histogram_tester; - proto::PredictionModel model; - model.mutable_model()->set_download_url( - FilePathToString(dir_path.AppendASCII("model.tflite"))); - model.mutable_model_info()->set_version(123); - *model.mutable_model_info()->mutable_model_metadata() = any; + base::flat_set<base::FilePath> additional_files; for (const auto& additional_file : expected_additional_files) { - if (additional_file.first == missing_file_and_status.first) { - // Don't add the file if it's supposed to be missing. - continue; + if (additional_file.first != missing_file_and_status.first) { + additional_files.insert(*StringToFilePath(additional_file.first)); } - model.mutable_model_info()->add_additional_files()->set_file_path( - additional_file.first); } - std::unique_ptr<ModelInfo> model_info = ModelInfo::Create(model); + std::unique_ptr<ModelInfo> model_info = + TestModelInfoBuilder() + .SetModelFilePath(GetModelTestDataDir().AppendASCII("model.tflite")) + .SetVersion(123) + .SetModelMetadata(any) + .SetAdditionalFiles(additional_files) + .Build(); ASSERT_TRUE(model_info); PushModelInfoToObservers(*model_info); // We expect that there will be no model to evaluate even for this input // that has output in the test model. - EXPECT_EQ(ExecuteHumanReadableModel("Taylor Swift singer"), absl::nullopt); + EXPECT_EQ(ExecuteModel("Taylor Swift singer"), absl::nullopt); histogram_tester.ExpectUniqueSample( "OptimizationGuide.PageEntitiesModelExecutor.CreatedSuccessfully", @@ -303,8 +325,8 @@ EXPECT_EQ(GetMetadataForEntityId("/m/0dl567"), absl::nullopt); } -TEST_F(PageEntitiesModelExecutorImplTest, ExecuteHumanReadableModelNoModel) { - EXPECT_EQ(ExecuteHumanReadableModel("Taylor Swift singer"), absl::nullopt); +TEST_F(PageEntitiesModelExecutorImplTest, ExecuteModelNoModel) { + EXPECT_EQ(ExecuteModel("Taylor Swift singer"), absl::nullopt); } TEST_F(PageEntitiesModelExecutorImplTest,
diff --git a/components/paint_preview/features/features.cc b/components/paint_preview/features/features.cc index 1f62945..65acbda 100644 --- a/components/paint_preview/features/features.cc +++ b/components/paint_preview/features/features.cc
@@ -12,6 +12,6 @@ base::FEATURE_DISABLED_BY_DEFAULT}; const base::Feature kPaintPreviewShowOnStartup{ - "PaintPreviewShowOnStartup", base::FEATURE_ENABLED_BY_DEFAULT}; + "PaintPreviewShowOnStartup", base::FEATURE_DISABLED_BY_DEFAULT}; } // namespace paint_preview
diff --git a/components/safe_browsing/content/renderer/phishing_classifier/flatbuffer_scorer.cc b/components/safe_browsing/content/renderer/phishing_classifier/flatbuffer_scorer.cc index d6b8848..d93c10e 100644 --- a/components/safe_browsing/content/renderer/phishing_classifier/flatbuffer_scorer.cc +++ b/components/safe_browsing/content/renderer/phishing_classifier/flatbuffer_scorer.cc
@@ -178,8 +178,7 @@ #if BUILDFLAG(BUILD_WITH_TFLITE_LIB) void FlatBufferModelScorer::ApplyVisualTfLiteModel( const SkBitmap& bitmap, - base::OnceCallback<void(base::flat_map<std::string, double>)> callback) - const { + base::OnceCallback<void(std::vector<double>)> callback) const { DCHECK(content::RenderThread::IsMainThread()); if (visual_tflite_model_.IsValid()) { base::Time start_post_task_time = base::Time::Now(); @@ -197,7 +196,7 @@ "SBClientPhishing.TfLiteModelLoadTime.FlatbufferScorer", base::Time::Now() - start_post_task_time); } else { - std::move(callback).Run(base::flat_map<std::string, double>()); + std::move(callback).Run(std::vector<double>()); } } #endif
diff --git a/components/safe_browsing/content/renderer/phishing_classifier/flatbuffer_scorer.h b/components/safe_browsing/content/renderer/phishing_classifier/flatbuffer_scorer.h index 3bb5f79..b4622f91 100644 --- a/components/safe_browsing/content/renderer/phishing_classifier/flatbuffer_scorer.h +++ b/components/safe_browsing/content/renderer/phishing_classifier/flatbuffer_scorer.h
@@ -51,8 +51,7 @@ #if BUILDFLAG(BUILD_WITH_TFLITE_LIB) void ApplyVisualTfLiteModel( const SkBitmap& bitmap, - base::OnceCallback<void(base::flat_map<std::string, double>)> callback) - const override; + base::OnceCallback<void(std::vector<double>)> callback) const override; #endif int model_version() const override;
diff --git a/components/safe_browsing/content/renderer/phishing_classifier/phishing_classifier.cc b/components/safe_browsing/content/renderer/phishing_classifier/phishing_classifier.cc index d9787dec..9fcd0153 100644 --- a/components/safe_browsing/content/renderer/phishing_classifier/phishing_classifier.cc +++ b/components/safe_browsing/content/renderer/phishing_classifier/phishing_classifier.cc
@@ -316,27 +316,23 @@ void PhishingClassifier::OnVisualTfLiteModelDone( std::unique_ptr<ClientPhishingRequest> verdict, - base::flat_map<std::string, double> result) { + std::vector<double> result) { + if (static_cast<int>(result.size()) > scorer_->tflite_thresholds().size()) { + // Model is misconfigured, so bail out. + RunFailureCallback(); + return; + } + verdict->set_tflite_model_version(scorer_->tflite_model_version()); - for (const TfLiteModelMetadata::Threshold& label_and_threshold : - scorer_->tflite_thresholds()) { + for (size_t i = 0; i < result.size(); i++) { ClientPhishingRequest::CategoryScore* category = verdict->add_tflite_model_scores(); - category->set_label(label_and_threshold.label()); + category->set_label(scorer_->tflite_thresholds().at(i).label()); + category->set_value(result[i]); - auto it = result.find(label_and_threshold.label()); - if (it == result.end()) { - // Model is misconfigured, so bail out. The class names from - // `visual_model.tflite` should exactly match the threshold labels in - // `client_model.pb` - RunFailureCallback(); - return; - } else { - category->set_value(it->second); - if (it->second >= label_and_threshold.threshold()) { - verdict->set_is_phishing(true); - verdict->set_is_tflite_match(true); - } + if (result[i] >= scorer_->tflite_thresholds().at(i).threshold()) { + verdict->set_is_phishing(true); + verdict->set_is_tflite_match(true); } }
diff --git a/components/safe_browsing/content/renderer/phishing_classifier/phishing_classifier.h b/components/safe_browsing/content/renderer/phishing_classifier/phishing_classifier.h index 9d32f37f..add37ba 100644 --- a/components/safe_browsing/content/renderer/phishing_classifier/phishing_classifier.h +++ b/components/safe_browsing/content/renderer/phishing_classifier/phishing_classifier.h
@@ -26,7 +26,6 @@ #include <vector> #include "base/callback.h" -#include "base/containers/flat_map.h" #include "base/memory/weak_ptr.h" #include "base/time/time.h" #include "third_party/skia/include/core/SkBitmap.h" @@ -139,7 +138,7 @@ // Callback when the visual TFLite model has been applied, and returned a list // of scores. void OnVisualTfLiteModelDone(std::unique_ptr<ClientPhishingRequest> verdict, - base::flat_map<std::string, double> result); + std::vector<double> result); // Helper method to run the DoneCallback and clear the state. void RunCallback(const ClientPhishingRequest& verdict);
diff --git a/components/safe_browsing/content/renderer/phishing_classifier/protobuf_scorer.cc b/components/safe_browsing/content/renderer/phishing_classifier/protobuf_scorer.cc index 9c8a780..cf6e038 100644 --- a/components/safe_browsing/content/renderer/phishing_classifier/protobuf_scorer.cc +++ b/components/safe_browsing/content/renderer/phishing_classifier/protobuf_scorer.cc
@@ -100,8 +100,7 @@ #if BUILDFLAG(BUILD_WITH_TFLITE_LIB) void ProtobufModelScorer::ApplyVisualTfLiteModel( const SkBitmap& bitmap, - base::OnceCallback<void(base::flat_map<std::string, double>)> callback) - const { + base::OnceCallback<void(std::vector<double>)> callback) const { DCHECK(content::RenderThread::IsMainThread()); if (visual_tflite_model_.IsValid()) { base::Time start_post_task_time = base::Time::Now(); @@ -119,7 +118,7 @@ "SBClientPhishing.TfLiteModelLoadTime.ProtobufScorer", base::Time::Now() - start_post_task_time); } else { - std::move(callback).Run(base::flat_map<std::string, double>()); + std::move(callback).Run(std::vector<double>()); } } #endif
diff --git a/components/safe_browsing/content/renderer/phishing_classifier/protobuf_scorer.h b/components/safe_browsing/content/renderer/phishing_classifier/protobuf_scorer.h index df35a75..db968ac 100644 --- a/components/safe_browsing/content/renderer/phishing_classifier/protobuf_scorer.h +++ b/components/safe_browsing/content/renderer/phishing_classifier/protobuf_scorer.h
@@ -49,8 +49,7 @@ #if BUILDFLAG(BUILD_WITH_TFLITE_LIB) void ApplyVisualTfLiteModel( const SkBitmap& bitmap, - base::OnceCallback<void(base::flat_map<std::string, double>)> callback) - const override; + base::OnceCallback<void(std::vector<double>)> callback) const override; #endif int model_version() const override;
diff --git a/components/safe_browsing/content/renderer/phishing_classifier/scorer.cc b/components/safe_browsing/content/renderer/phishing_classifier/scorer.cc index 738fc0f..caf891a2 100644 --- a/components/safe_browsing/content/renderer/phishing_classifier/scorer.cc +++ b/components/safe_browsing/content/renderer/phishing_classifier/scorer.cc
@@ -132,7 +132,7 @@ int input_height, std::unique_ptr<tflite::task::vision::ImageClassifier> classifier, scoped_refptr<base::SequencedTaskRunner> callback_task_runner, - base::OnceCallback<void(base::flat_map<std::string, double>)> callback) { + base::OnceCallback<void(std::vector<double>)> callback) { base::Time before_operation = base::Time::Now(); tflite::task::vision::FrameBuffer::Plane plane{ reinterpret_cast<const tflite::uint8*>(model_input.data()), @@ -147,15 +147,15 @@ if (!statusor_result.ok()) { VLOG(1) << statusor_result.status().ToString(); callback_task_runner->PostTask( - FROM_HERE, base::BindOnce(std::move(callback), - base::flat_map<std::string, double>())); + FROM_HERE, base::BindOnce(std::move(callback), std::vector<double>())); return; } - base::flat_map<std::string, double> scores; + std::vector<double> scores( + statusor_result->classifications(0).classes().size()); for (const tflite::task::vision::Class& clas : statusor_result->classifications(0).classes()) { - scores[clas.class_name()] = clas.score(); + scores[clas.index()] = clas.score(); } callback_task_runner->PostTask( @@ -168,13 +168,12 @@ int input_height, std::unique_ptr<tflite::task::vision::ImageClassifier> classifier, scoped_refptr<base::SequencedTaskRunner> callback_task_runner, - base::OnceCallback<void(base::flat_map<std::string, double>)> callback) { + base::OnceCallback<void(std::vector<double>)> callback) { base::Time before_operation = base::Time::Now(); std::string model_input = GetModelInput(bitmap, input_width, input_height); if (model_input.empty()) { callback_task_runner->PostTask( - FROM_HERE, base::BindOnce(std::move(callback), - base::flat_map<std::string, double>())); + FROM_HERE, base::BindOnce(std::move(callback), std::vector<double>())); return; } base::UmaHistogramTimes("SBClientPhishing.ApplyTfliteTime.GetModelInput", @@ -198,7 +197,7 @@ int input_height, std::string model_data, scoped_refptr<base::SequencedTaskRunner> callback_task_runner, - base::OnceCallback<void(base::flat_map<std::string, double>)> callback) { + base::OnceCallback<void(std::vector<double>)> callback) { TRACE_EVENT0("safe_browsing", "ApplyVisualTfLiteModel"); base::Time before_operation = base::Time::Now(); before_operation = base::Time::Now(); @@ -208,8 +207,7 @@ base::Time::Now() - before_operation); if (!classifier) { callback_task_runner->PostTask( - FROM_HERE, base::BindOnce(std::move(callback), - base::flat_map<std::string, double>())); + FROM_HERE, base::BindOnce(std::move(callback), std::vector<double>())); return; }
diff --git a/components/safe_browsing/content/renderer/phishing_classifier/scorer.h b/components/safe_browsing/content/renderer/phishing_classifier/scorer.h index 951bb728..6a34763 100644 --- a/components/safe_browsing/content/renderer/phishing_classifier/scorer.h +++ b/components/safe_browsing/content/renderer/phishing_classifier/scorer.h
@@ -74,8 +74,7 @@ // order as `tflite_thresholds()`. virtual void ApplyVisualTfLiteModel( const SkBitmap& bitmap, - base::OnceCallback<void(base::flat_map<std::string, double>)> callback) - const = 0; + base::OnceCallback<void(std::vector<double>)> callback) const = 0; #endif // Returns the version number of the loaded client model. @@ -134,7 +133,7 @@ int input_height, std::string model_data, scoped_refptr<base::SequencedTaskRunner> callback_task_runner, - base::OnceCallback<void(base::flat_map<std::string, double>)> callback); + base::OnceCallback<void(std::vector<double>)> callback); base::MemoryMappedFile visual_tflite_model_; base::WeakPtrFactory<Scorer> weak_ptr_factory_{this};
diff --git a/components/sync/protocol/password_specifics.proto b/components/sync/protocol/password_specifics.proto index 640622a9..8154195 100644 --- a/components/sync/protocol/password_specifics.proto +++ b/components/sync/protocol/password_specifics.proto
@@ -130,6 +130,9 @@ message PasswordIssue { // Timestamp set by a client detecting the issue for the first time. // Number of microseconds since Windows epoch (1601). + // This can be unset even if is_muted is set in a few cases in + // storage (for a time mutes were written without setting this + // field - fixed starting 2021-11-10). optional uint64 date_first_detection_microseconds = 1; // Whether the issue was muted by user.
diff --git a/components/variations/synthetic_trial_registry.cc b/components/variations/synthetic_trial_registry.cc index 252fe64..8fb9c1e 100644 --- a/components/variations/synthetic_trial_registry.cc +++ b/components/variations/synthetic_trial_registry.cc
@@ -61,7 +61,7 @@ // When overriding previous external experiments, remove them now. if (mode == kOverrideExistingIds) { auto is_external = [](const SyntheticTrialGroup& group) { - return group.is_external; + return group.is_external(); }; base::EraseIf(synthetic_trial_groups_, is_external); } @@ -80,7 +80,7 @@ // are already registered. if (mode == kDoNotOverrideExistingIds) { auto matches_trial = [trial_hash](const SyntheticTrialGroup& group) { - return group.id.name == trial_hash; + return group.id().name == trial_hash; }; const auto& groups = synthetic_trial_groups_; if (std::any_of(groups.begin(), groups.end(), matches_trial)) { @@ -97,10 +97,10 @@ GOOGLE_WEB_PROPERTIES_SIGNED_IN, {trial_hash, group_hash}, static_cast<VariationID>(experiment_id)); SyntheticTrialGroup entry( - trial_hash, group_hash, + study_name, experiment_id_str, variations::SyntheticTrialAnnotationMode::kNextLog); - entry.start_time = start_time; - entry.is_external = true; + entry.SetStartTime(start_time); + entry.SetIsExternal(true); synthetic_trial_groups_.push_back(entry); trials_added++; } @@ -115,14 +115,14 @@ void SyntheticTrialRegistry::RegisterSyntheticFieldTrial( const SyntheticTrialGroup& trial) { for (auto& entry : synthetic_trial_groups_) { - if (entry.id.name == trial.id.name) { + if (entry.id().name == trial.id().name) { // Don't necessarily need to notify observers when setting // |annotation_mode| as it is only used when producing metrics reports // and does not affect variations service. - entry.annotation_mode = trial.annotation_mode; - if (entry.id.group != trial.id.group) { - entry.id.group = trial.id.group; - entry.start_time = base::TimeTicks::Now(); + entry.SetAnnotationMode(trial.annotation_mode()); + if (entry.id().group != trial.id().group) { + entry.SetGroupName(trial.group_name()); + entry.SetStartTime(base::TimeTicks::Now()); NotifySyntheticTrialObservers(); } return; @@ -130,7 +130,7 @@ } SyntheticTrialGroup trial_group = trial; - trial_group.start_time = base::TimeTicks::Now(); + trial_group.SetStartTime(base::TimeTicks::Now()); synthetic_trial_groups_.push_back(trial_group); NotifySyntheticTrialObservers(); } @@ -169,9 +169,9 @@ DCHECK(synthetic_trials); synthetic_trials->clear(); for (const auto& entry : synthetic_trial_groups_) { - if (entry.start_time <= time || - entry.annotation_mode == SyntheticTrialAnnotationMode::kCurrentLog) - synthetic_trials->push_back(entry.id); + if (entry.start_time() <= time || + entry.annotation_mode() == SyntheticTrialAnnotationMode::kCurrentLog) + synthetic_trials->push_back(entry.id()); } }
diff --git a/components/variations/synthetic_trial_registry_unittest.cc b/components/variations/synthetic_trial_registry_unittest.cc index caf6779..129a213 100644 --- a/components/variations/synthetic_trial_registry_unittest.cc +++ b/components/variations/synthetic_trial_registry_unittest.cc
@@ -69,11 +69,11 @@ SyntheticTrialRegistry registry; // Add two synthetic trials and confirm that they show up in the list. - SyntheticTrialGroup trial1_group1(HashName("TestTrial1"), HashName("Group1"), + SyntheticTrialGroup trial1_group1("TestTrial1", "Group1", SyntheticTrialAnnotationMode::kNextLog); registry.RegisterSyntheticFieldTrial(trial1_group1); - SyntheticTrialGroup trial2_group2(HashName("TestTrial2"), HashName("Group2"), + SyntheticTrialGroup trial2_group2("TestTrial2", "Group2", SyntheticTrialAnnotationMode::kNextLog); registry.RegisterSyntheticFieldTrial(trial2_group2); // Ensure that time has advanced by at least a tick before proceeding. @@ -95,7 +95,7 @@ WaitUntilTimeChanges(begin_log_time); // Change the group for the first trial after the log started. - SyntheticTrialGroup trial1_group2(HashName("TestTrial1"), HashName("Group2"), + SyntheticTrialGroup trial1_group2("TestTrial1", "Group2", SyntheticTrialAnnotationMode::kNextLog); registry.RegisterSyntheticFieldTrial(trial1_group2); registry.GetSyntheticFieldTrialsOlderThan(begin_log_time, &synthetic_trials); @@ -103,7 +103,7 @@ EXPECT_TRUE(HasSyntheticTrial(synthetic_trials, "TestTrial2", "Group2")); // Add a new trial after the log started and confirm that it doesn't show up. - SyntheticTrialGroup trial3_group3(HashName("TestTrial3"), HashName("Group3"), + SyntheticTrialGroup trial3_group3("TestTrial3", "Group3", SyntheticTrialAnnotationMode::kNextLog); registry.RegisterSyntheticFieldTrial(trial3_group3); registry.GetSyntheticFieldTrialsOlderThan(begin_log_time, &synthetic_trials); @@ -114,11 +114,9 @@ // active immediately, and confirm they both show up despite being added after // the log started. SyntheticTrialGroup trial3_group3_current_log( - HashName("TestTrial3"), HashName("Group3"), - SyntheticTrialAnnotationMode::kCurrentLog); + "TestTrial3", "Group3", SyntheticTrialAnnotationMode::kCurrentLog); SyntheticTrialGroup trial4_group4_current_log( - HashName("TestTrial4"), HashName("Group4"), - SyntheticTrialAnnotationMode::kCurrentLog); + "TestTrial4", "Group4", SyntheticTrialAnnotationMode::kCurrentLog); registry.RegisterSyntheticFieldTrial(trial3_group3_current_log); registry.RegisterSyntheticFieldTrial(trial4_group4_current_log); registry.GetSyntheticFieldTrialsOlderThan(begin_log_time, &synthetic_trials); @@ -222,11 +220,11 @@ SyntheticTrialsActiveGroupIdProvider::GetInstance()); // Add two synthetic trials and confirm that they show up in the list. - SyntheticTrialGroup trial1(HashName("TestTrial1"), HashName("Group1"), + SyntheticTrialGroup trial1("TestTrial1", "Group1", SyntheticTrialAnnotationMode::kNextLog); registry.RegisterSyntheticFieldTrial(trial1); - SyntheticTrialGroup trial2(HashName("TestTrial2"), HashName("Group2"), + SyntheticTrialGroup trial2("TestTrial2", "Group2", SyntheticTrialAnnotationMode::kNextLog); registry.RegisterSyntheticFieldTrial(trial2); @@ -238,12 +236,14 @@ GetSyntheticTrialGroupIdsAsString(&output); EXPECT_EQ(2U, output.size()); + ActiveGroupId trial1_id = trial1.id(); std::string trial1_hash = - base::StringPrintf("%x-%x", trial1.id.name, trial1.id.group); + base::StringPrintf("%x-%x", trial1_id.name, trial1_id.group); EXPECT_TRUE(base::Contains(output, trial1_hash)); + ActiveGroupId trial2_id = trial2.id(); std::string trial2_hash = - base::StringPrintf("%x-%x", trial2.id.name, trial2.id.group); + base::StringPrintf("%x-%x", trial2_id.name, trial2.id().group); EXPECT_TRUE(base::Contains(output, trial2_hash)); }
diff --git a/components/variations/synthetic_trials.cc b/components/variations/synthetic_trials.cc index 1f93c58..0eacdc1 100644 --- a/components/variations/synthetic_trials.cc +++ b/components/variations/synthetic_trials.cc
@@ -3,18 +3,29 @@ // found in the LICENSE file. #include "components/variations/synthetic_trials.h" +#include "components/variations/hashing.h" namespace variations { SyntheticTrialGroup::SyntheticTrialGroup( - uint32_t trial, - uint32_t group, + base::StringPiece trial_name, + base::StringPiece group_name, SyntheticTrialAnnotationMode annotation_mode) - : annotation_mode(annotation_mode) { - id.name = trial; - id.group = group; + : annotation_mode_(annotation_mode) { + SetTrialName(trial_name); + SetGroupName(group_name); } -SyntheticTrialGroup::~SyntheticTrialGroup() {} +SyntheticTrialGroup::SyntheticTrialGroup(const SyntheticTrialGroup&) = default; + +void SyntheticTrialGroup::SetTrialName(base::StringPiece trial_name) { + trial_name_ = std::string(trial_name); + id_.name = variations::HashName(trial_name); +} + +void SyntheticTrialGroup::SetGroupName(base::StringPiece group_name) { + group_name_ = std::string(group_name); + id_.group = variations::HashName(group_name); +} } // namespace variations
diff --git a/components/variations/synthetic_trials.h b/components/variations/synthetic_trials.h index b555760c..a1accab 100644 --- a/components/variations/synthetic_trials.h +++ b/components/variations/synthetic_trials.h
@@ -30,24 +30,52 @@ }; // A Field Trial and its selected group, which represent a particular -// Chrome configuration state. For example, the trial name could map to -// a preference name, and the group name could map to a preference value. -struct COMPONENT_EXPORT(VARIATIONS) SyntheticTrialGroup { +// Chrome configuration state. In other words, synthetic trials allow reporting +// some client state as if it were a field trial. For example, the trial name +// could map to a preference name, and the group name could map to a preference +// value. +class COMPONENT_EXPORT(VARIATIONS) SyntheticTrialGroup { public: - SyntheticTrialGroup(uint32_t trial, - uint32_t group, + SyntheticTrialGroup(base::StringPiece trial_name, + base::StringPiece group_name, SyntheticTrialAnnotationMode annotation_mode); - ~SyntheticTrialGroup(); - ActiveGroupId id; - base::TimeTicks start_time; + SyntheticTrialGroup(const SyntheticTrialGroup&); + + ~SyntheticTrialGroup() = default; + + base::StringPiece trial_name() const { return trial_name_; } + base::StringPiece group_name() const { return group_name_; } + ActiveGroupId id() const { return id_; } + base::TimeTicks start_time() const { return start_time_; } + SyntheticTrialAnnotationMode annotation_mode() const { + return annotation_mode_; + } + bool is_external() const { return is_external_; } + + void SetTrialName(base::StringPiece trial_name); + void SetGroupName(base::StringPiece group_name); + void SetStartTime(base::TimeTicks start_time) { start_time_ = start_time; } + void SetAnnotationMode(SyntheticTrialAnnotationMode annotation_mode) { + annotation_mode_ = annotation_mode; + } + void SetIsExternal(bool is_external) { is_external_ = is_external; } + + private: + std::string trial_name_; + std::string group_name_; + ActiveGroupId id_; + base::TimeTicks start_time_; // Determines when UMA reports should start being annotated with this trial // group. - SyntheticTrialAnnotationMode annotation_mode; + SyntheticTrialAnnotationMode annotation_mode_; - // If this is an external experiment. - bool is_external = false; + // Whether this is an external experiment. I.e., if this synthetic trial was + // registered through SyntheticTrialRegistry::RegisterExternalExperiments(). + // An example of an external experiment would be the Chrome updater randomly + // assigning which binary to update to. + bool is_external_ = false; }; // Interface class to observe changes to synthetic trials in MetricsService.
diff --git a/components/variations/synthetic_trials_active_group_id_provider.cc b/components/variations/synthetic_trials_active_group_id_provider.cc index 3a51591..5d3e473 100644 --- a/components/variations/synthetic_trials_active_group_id_provider.cc +++ b/components/variations/synthetic_trials_active_group_id_provider.cc
@@ -37,7 +37,7 @@ base::AutoLock scoped_lock(lock_); synthetic_trials_.clear(); for (const auto& group : groups) - synthetic_trials_.push_back(group.id); + synthetic_trials_.push_back(group.id()); } // Update the experiments list for crash reports.
diff --git a/components/variations/variations_crash_keys.cc b/components/variations/variations_crash_keys.cc index 268c597..93e2bca 100644 --- a/components/variations/variations_crash_keys.cc +++ b/components/variations/variations_crash_keys.cc
@@ -206,7 +206,7 @@ // not be too many synthetic trials, this is not too big of an issue. synthetic_trials_string_.clear(); for (const auto& synthetic_trial : synthetic_trials) { - synthetic_trials_string_ += ActiveGroupToString(synthetic_trial.id); + synthetic_trials_string_ += ActiveGroupToString(synthetic_trial.id()); } num_synthetic_trials_ = synthetic_trials.size();
diff --git a/components/variations/variations_crash_keys.h b/components/variations/variations_crash_keys.h index 908c1d3..3fe762ef 100644 --- a/components/variations/variations_crash_keys.h +++ b/components/variations/variations_crash_keys.h
@@ -12,7 +12,7 @@ namespace variations { -struct SyntheticTrialGroup; +class SyntheticTrialGroup; // The key used in crash reports to indicate the number of active experiments. // Should match the number of entries in kExperimentListKey.
diff --git a/components/variations/variations_crash_keys_unittest.cc b/components/variations/variations_crash_keys_unittest.cc index 598920f..5a61234 100644 --- a/components/variations/variations_crash_keys_unittest.cc +++ b/components/variations/variations_crash_keys_unittest.cc
@@ -80,8 +80,7 @@ // Add two synthetic trials and confirm that they show up in the list. SyntheticTrialGroup synth_trial( - HashName("Trial3"), HashName("Group3"), - variations::SyntheticTrialAnnotationMode::kNextLog); + "Trial3", "Group3", variations::SyntheticTrialAnnotationMode::kNextLog); registry.RegisterSyntheticFieldTrial(synth_trial); EXPECT_EQ("3", GetNumExperimentsCrashKey()); @@ -109,12 +108,10 @@ // Replace synthetic trial group and add one more. SyntheticTrialGroup synth_trial2( - HashName("Trial3"), HashName("Group3_A"), - variations::SyntheticTrialAnnotationMode::kNextLog); + "Trial3", "Group3_A", variations::SyntheticTrialAnnotationMode::kNextLog); registry.RegisterSyntheticFieldTrial(synth_trial2); SyntheticTrialGroup synth_trial3( - HashName("Trial4"), HashName("Group4"), - variations::SyntheticTrialAnnotationMode::kNextLog); + "Trial4", "Group4", variations::SyntheticTrialAnnotationMode::kNextLog); registry.RegisterSyntheticFieldTrial(synth_trial3); EXPECT_EQ("5", GetNumExperimentsCrashKey());
diff --git a/components/variations/variations_ids_provider.cc b/components/variations/variations_ids_provider.cc index c786037..28dfeb65 100644 --- a/components/variations/variations_ids_provider.cc +++ b/components/variations/variations_ids_provider.cc
@@ -251,13 +251,13 @@ synthetic_variation_ids_set_.clear(); for (const SyntheticTrialGroup& group : groups) { VariationID id = GetGoogleVariationIDFromHashes( - GOOGLE_WEB_PROPERTIES_ANY_CONTEXT, group.id); + GOOGLE_WEB_PROPERTIES_ANY_CONTEXT, group.id()); if (id != EMPTY_ID) { synthetic_variation_ids_set_.insert( VariationIDEntry(id, GOOGLE_WEB_PROPERTIES_ANY_CONTEXT)); } id = GetGoogleVariationIDFromHashes(GOOGLE_WEB_PROPERTIES_SIGNED_IN, - group.id); + group.id()); if (id != EMPTY_ID) { synthetic_variation_ids_set_.insert( VariationIDEntry(id, GOOGLE_WEB_PROPERTIES_SIGNED_IN));
diff --git a/content/browser/first_party_sets/first_party_sets_handler_impl.cc b/content/browser/first_party_sets/first_party_sets_handler_impl.cc index 6a1117f5..22103add 100644 --- a/content/browser/first_party_sets/first_party_sets_handler_impl.cc +++ b/content/browser/first_party_sets/first_party_sets_handler_impl.cc
@@ -168,6 +168,9 @@ DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); if (user_data_dir.empty()) { VLOG(1) << "Empty path. Failed loading serialized First-Party Sets file."; + // We have to continue, in case the embedder has enabled FPS but has not + // provided a directory to store persisted sets. + OnReadPersistedSetsFile(""); return; } persisted_sets_path_ = user_data_dir.Append(kPersistedFirstPartySetsFileName); @@ -186,7 +189,6 @@ void FirstPartySetsHandlerImpl::OnReadPersistedSetsFile( const std::string& raw_persisted_sets) { DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); - DCHECK(!persisted_sets_path_.empty()); raw_persisted_sets_ = raw_persisted_sets; UmaHistogramTimes( "Cookie.FirstPartySets.InitializationDuration.ReadPersistedSets2", @@ -246,11 +248,13 @@ if (!on_sets_ready_.is_null() && IsEnabledAndReady()) std::move(on_sets_ready_).Run(sets_.value()); - base::ThreadPool::PostTask( - FROM_HERE, {base::MayBlock(), base::TaskPriority::BEST_EFFORT}, - base::BindOnce( - &MaybeWriteSetsToDisk, persisted_sets_path_, - FirstPartySetParser::SerializeFirstPartySets(sets_.value()))); + if (!persisted_sets_path_.empty()) { + base::ThreadPool::PostTask( + FROM_HERE, {base::MayBlock(), base::TaskPriority::BEST_EFFORT}, + base::BindOnce( + &MaybeWriteSetsToDisk, persisted_sets_path_, + FirstPartySetParser::SerializeFirstPartySets(sets_.value()))); + } } bool FirstPartySetsHandlerImpl::IsEnabledAndReady() const {
diff --git a/content/browser/first_party_sets/first_party_sets_handler_impl_unittest.cc b/content/browser/first_party_sets/first_party_sets_handler_impl_unittest.cc index 3e92801e..b34abca8 100644 --- a/content/browser/first_party_sets/first_party_sets_handler_impl_unittest.cc +++ b/content/browser/first_party_sets/first_party_sets_handler_impl_unittest.cc
@@ -401,17 +401,21 @@ : FirstPartySetsHandlerImplTest(true) {} }; -TEST_F(FirstPartySetsHandlerImplEnabledTest, PersistedSetsNotReady) { - // Empty `user_data_dir` will fail loading persisted sets. +TEST_F(FirstPartySetsHandlerImplEnabledTest, EmptyPersistedSetsDir) { + // Empty `user_data_dir` will fail to load persisted sets, but that will not + // prevent `on_sets_ready` from being invoked. + base::test::TestFuture<const FirstPartySetsHandlerImpl::FlattenedSets&> + future; FirstPartySetsHandlerImpl::GetInstance()->Init( /*user_data_dir=*/{}, /*flag_value=*/"https://example.test,https://member1.test", - base::BindLambdaForTesting( - [](const FirstPartySetsHandlerImpl::FlattenedSets& got) { - FAIL(); // Should not be called. - })); + future.GetCallback()); - env().RunUntilIdle(); + EXPECT_THAT(future.Get(), + UnorderedElementsAre(Pair(SerializesTo("https://example.test"), + SerializesTo("https://example.test")), + Pair(SerializesTo("https://member1.test"), + SerializesTo("https://example.test")))); } TEST_F(FirstPartySetsHandlerImplEnabledTest, PublicFirstPartySetsNotReady) {
diff --git a/content/browser/renderer_host/browser_compositor_view_mac.h b/content/browser/renderer_host/browser_compositor_view_mac.h index 84a6ed0..5ed3470 100644 --- a/content/browser/renderer_host/browser_compositor_view_mac.h +++ b/content/browser/renderer_host/browser_compositor_view_mac.h
@@ -20,6 +20,10 @@ #include "ui/display/screen_info.h" #include "ui/gfx/ca_layer_params.h" +namespace perfetto { +class StaticString; +} + namespace ui { class AcceleratedWidgetMacNSView; class RecyclableCompositorMac; @@ -160,6 +164,10 @@ void UpdateState(); void TransitionToState(State new_state); + static perfetto::StaticString EventNameForStateTransition(State old_state, + State new_state, + bool is_no_op); + // Weak pointer to the layer supplied and reset via SetParentUiLayer. |this| // is an observer of |parent_ui_layer_|, to ensure that |parent_ui_layer_| // always be valid when non-null. The UpdateState function will re-parent
diff --git a/content/browser/renderer_host/browser_compositor_view_mac.mm b/content/browser/renderer_host/browser_compositor_view_mac.mm index 6a721c8..4c9f3bdd 100644 --- a/content/browser/renderer_host/browser_compositor_view_mac.mm +++ b/content/browser/renderer_host/browser_compositor_view_mac.mm
@@ -8,18 +8,23 @@ #include <stdint.h> #include <memory> +#include <tuple> #include <utility> +#include "base/check.h" #include "base/command_line.h" #include "base/containers/circular_deque.h" +#include "base/containers/contains.h" +#include "base/containers/fixed_flat_map.h" #include "base/lazy_instance.h" -#include "base/trace_event/trace_event.h" +#include "base/trace_event/typed_macros.h" #include "components/viz/common/features.h" #include "components/viz/common/surfaces/local_surface_id.h" #include "content/browser/compositor/image_transport_factory.h" #include "content/public/browser/browser_thread.h" #include "content/public/browser/context_factory.h" #include "third_party/abseil-cpp/absl/types/optional.h" +#include "third_party/perfetto/include/perfetto/tracing/string_helpers.h" #include "ui/accelerated_widget_mac/accelerated_widget_mac.h" #include "ui/accelerated_widget_mac/window_resize_helper_mac.h" #include "ui/base/layout.h" @@ -225,6 +230,13 @@ else is_no_op = true; } + // Record a trace event whose name encodes the old and new states. The states + // can be used to trace this function to see if WasShown / WasHidden were + // called. When a tab switch is occurring these traces will nest in trace + // events recoded by RenderWidgetHostViewMac. + // TODO(https://crbug.com/1164477): Remove these when the investigation is + // done. + TRACE_EVENT("cc", EventNameForStateTransition(state_, new_state, is_no_op)); if (is_no_op) return; @@ -282,6 +294,42 @@ } // static +perfetto::StaticString BrowserCompositorMac::EventNameForStateTransition( + State old_state, + State new_state, + bool is_no_op) { + static const auto kEventNames = + base::MakeFixedFlatMap<std::tuple<State, State, bool>, + perfetto::StaticString>({ + {{HasNoCompositor, HasNoCompositor, true}, + "BrowserCompositorMac.StateTransition.No.No.NoOp"}, + {{HasNoCompositor, HasOwnCompositor, false}, + "BrowserCompositorMac.StateTransition.No.Own"}, + {{HasNoCompositor, UseParentLayerCompositor, false}, + "BrowserCompositorMac.StateTransition.No.Parent"}, + {{HasOwnCompositor, HasNoCompositor, false}, + "BrowserCompositorMac.StateTransition.Own.No"}, + {{HasOwnCompositor, HasOwnCompositor, true}, + "BrowserCompositorMac.StateTransition.Own.Own.NoOp"}, + {{HasOwnCompositor, UseParentLayerCompositor, false}, + "BrowserCompositorMac.StateTransition.Own.Parent"}, + {{UseParentLayerCompositor, HasNoCompositor, false}, + "BrowserCompositorMac.StateTransition.Parent.No"}, + {{UseParentLayerCompositor, HasOwnCompositor, false}, + "BrowserCompositorMac.StateTransition.Parent.Own"}, + // UseParentLayerCompositer -> UseParentLayerCompositer may or may not + // be a no-op. + {{UseParentLayerCompositor, UseParentLayerCompositor, false}, + "BrowserCompositorMac.StateTransition.Parent.Parent"}, + {{UseParentLayerCompositor, UseParentLayerCompositor, true}, + "BrowserCompositorMac.StateTransition.Parent.Parent.NoOp"}, + }); + const auto key = std::make_tuple(old_state, new_state, is_no_op); + DCHECK(base::Contains(kEventNames, key)); + return kEventNames.at(key); +} + +// static void BrowserCompositorMac::DisableRecyclingForShutdown() { // Ensure that the client has destroyed its BrowserCompositorViewMac before // it dependencies are destroyed.
diff --git a/content/browser/renderer_host/render_widget_host_view_mac.mm b/content/browser/renderer_host/render_widget_host_view_mac.mm index b72b5404..3fbe8be 100644 --- a/content/browser/renderer_host/render_widget_host_view_mac.mm +++ b/content/browser/renderer_host/render_widget_host_view_mac.mm
@@ -21,6 +21,7 @@ #include "base/strings/sys_string_conversions.h" #include "base/strings/utf_string_conversions.h" #include "base/time/time.h" +#include "base/trace_event/typed_macros.h" #include "components/remote_cocoa/browser/ns_view_ids.h" #include "components/remote_cocoa/common/application.mojom.h" #include "components/viz/common/features.h" @@ -473,12 +474,18 @@ browser_compositor_->GetDelegatedFrameHost(); DCHECK(delegated_frame_host); const bool record_presentation_time = has_saved_frame; + // TODO(https://crbug.com/1164477): Remove these trace events when the + // investigation is done. + if (record_presentation_time) + TRACE_EVENT_BEGIN("cc", "RWHVMac::WasShown with saved frame"); delegated_frame_host->WasShown( browser_compositor_->GetRendererLocalSurfaceId(), browser_compositor_->GetRendererSize(), record_presentation_time ? std::move(tab_switch_start_state) : blink::mojom::RecordContentToVisibleTimeRequestPtr()); + if (record_presentation_time) + TRACE_EVENT_END("cc"); } void RenderWidgetHostViewMac::RequestPresentationTimeFromHostOrDelegate( @@ -491,6 +498,7 @@ if (browser_compositor_->GetDelegatedFrameHost()->HasSavedFrame()) { // If the frame for the renderer is already available, then the // tab-switching time is the presentation time for the browser-compositor. + TRACE_EVENT("cc", "RHWVMac::RequestPresentationTime with saved frame"); browser_compositor_->GetDelegatedFrameHost() ->RequestPresentationTimeForNextFrame(std::move(visible_time_request)); } else { @@ -503,7 +511,13 @@ CancelPresentationTimeRequestForHostAndDelegate() { DCHECK(!host_->is_hidden()); host()->CancelPresentationTimeRequest(); + const bool has_saved_frame = + browser_compositor_->GetDelegatedFrameHost()->HasSavedFrame(); + if (has_saved_frame) + TRACE_EVENT_BEGIN("cc", "RWHVMac::CancelPresentationTime with saved frame"); browser_compositor_->GetDelegatedFrameHost()->CancelPresentationTimeRequest(); + if (has_saved_frame) + TRACE_EVENT_END("cc"); } void RenderWidgetHostViewMac::WasOccluded() { @@ -511,7 +525,13 @@ return; host()->WasHidden(); + const bool has_saved_frame = + browser_compositor_->GetDelegatedFrameHost()->HasSavedFrame(); + if (has_saved_frame) + TRACE_EVENT_BEGIN("cc", "RWHVMac::WasOccluded with saved frame"); browser_compositor_->SetRenderWidgetHostIsHidden(true); + if (has_saved_frame) + TRACE_EVENT_END("cc"); } void RenderWidgetHostViewMac::SetSize(const gfx::Size& size) {
diff --git a/content/test/gpu/unexpected_pass_finder.py b/content/test/gpu/unexpected_pass_finder.py index 48150b3..8ac6367 100755 --- a/content/test/gpu/unexpected_pass_finder.py +++ b/content/test/gpu/unexpected_pass_finder.py
@@ -122,14 +122,15 @@ def main(): args = ParseArgs() - builders_instance = gpu_builders.GpuBuilders(args.include_internal_builders) + builders_instance = gpu_builders.GpuBuilders( + SUITE_TO_TELEMETRY_SUITE_MAP.get(args.suite, args.suite), + args.include_internal_builders) builders.RegisterInstance(builders_instance) expectations_instance = gpu_expectations.GpuExpectations() test_expectation_map = expectations_instance.CreateTestExpectationMap( args.expectation_file, args.tests, args.expectation_grace_period) - ci_builders = builders_instance.GetCiBuilders( - SUITE_TO_TELEMETRY_SUITE_MAP.get(args.suite, args.suite)) + ci_builders = builders_instance.GetCiBuilders() querier = gpu_queries.GpuBigQueryQuerier(args.suite, args.project, args.num_samples,
diff --git a/content/test/gpu/unexpected_passes/gpu_builders.py b/content/test/gpu/unexpected_passes/gpu_builders.py index 83e9d47..5bb7749a 100644 --- a/content/test/gpu/unexpected_passes/gpu_builders.py +++ b/content/test/gpu/unexpected_passes/gpu_builders.py
@@ -11,18 +11,18 @@ class GpuBuilders(builders.Builders): - def __init__(self, include_internal_builders): - super().__init__(include_internal_builders) + def __init__(self, suite, include_internal_builders): + super().__init__(suite, include_internal_builders) self._isolate_names = None self._fake_ci_builders = None self._non_chromium_builders = None - def _BuilderRunsTestOfInterest(self, test_map, suite): + def _BuilderRunsTestOfInterest(self, test_map): tests = test_map.get('isolated_scripts', []) for t in tests: if t.get('isolate_name') not in self.GetIsolateNames(): continue - if suite in t.get('args', []): + if self._suite in t.get('args', []): return True return False @@ -55,10 +55,6 @@ 'ANGLE GPU Linux Release (Intel HD 630)', 'ANGLE GPU Linux Release (NVIDIA)', ], - 'linux_optional_gpu_tests_rel': [ - 'Optional Linux Release (Intel HD 630)', - 'Optional Linux Release (NVIDIA)', - ], 'mac_optional_gpu_tests_rel': [ 'Optional Mac Release (Intel)', 'Optional Mac Retina Release (AMD)',
diff --git a/content/test/gpu/unexpected_passes/gpu_builders_unittest.py b/content/test/gpu/unexpected_passes/gpu_builders_unittest.py index a4ea0d7..18009bc 100755 --- a/content/test/gpu/unexpected_passes/gpu_builders_unittest.py +++ b/content/test/gpu/unexpected_passes/gpu_builders_unittest.py
@@ -14,7 +14,7 @@ class BuilderRunsTestOfInterestUnittest(unittest.TestCase): def setUp(self): - self.instance = gpu_builders.GpuBuilders(False) + self.instance = gpu_builders.GpuBuilders('webgl_conformance', False) def testMatch(self): """Tests that a match can be successfully found.""" @@ -28,8 +28,7 @@ }, ], } - self.assertTrue( - self.instance._BuilderRunsTestOfInterest(test_map, 'webgl_conformance')) + self.assertTrue(self.instance._BuilderRunsTestOfInterest(test_map)) def testNoMatchIsolate(self): """Tests that a match is not found if the isolate name is not valid.""" @@ -43,8 +42,7 @@ }, ], } - self.assertFalse( - self.instance._BuilderRunsTestOfInterest(test_map, 'webgl_conformance')) + self.assertFalse(self.instance._BuilderRunsTestOfInterest(test_map)) def testNoMatchSuite(self): """Tests that a match is not found if the suite name is not valid.""" @@ -58,8 +56,7 @@ }, ], } - self.assertFalse( - self.instance._BuilderRunsTestOfInterest(test_map, 'webgl_conformance')) + self.assertFalse(self.instance._BuilderRunsTestOfInterest(test_map)) def testAndroidSuffixes(self): """Tests that Android-specific isolates are added.""" @@ -73,17 +70,16 @@ class GetFakeCiBuildersUnittest(unittest.TestCase): def testStringsConvertedToBuilderEntries(self): """Tests that the easier-to-read strings get converted to BuilderEntry.""" - instance = gpu_builders.GpuBuilders(False) + instance = gpu_builders.GpuBuilders('webgl_conformance', False) fake_builders = instance.GetFakeCiBuilders() - ci_builder = data_types.BuilderEntry( - 'Optional Linux Release (Intel HD 630)', constants.BuilderTypes.CI, - False) + ci_builder = data_types.BuilderEntry('Optional Android Release (Pixel 4)', + constants.BuilderTypes.CI, False) expected_try = set([ - data_types.BuilderEntry('linux_optional_gpu_tests_rel', + data_types.BuilderEntry('android_optional_gpu_tests_rel', constants.BuilderTypes.TRY, False) ]) self.assertEqual(fake_builders[ci_builder], expected_try) - ci_builder = data_types.BuilderEntry('Optional Linux Release (NVIDIA)', + ci_builder = data_types.BuilderEntry('Optional Android Release (Nexus 5X)', constants.BuilderTypes.CI, False) self.assertEqual(fake_builders[ci_builder], expected_try) @@ -91,7 +87,7 @@ class GetNonChromiumBuildersUnittest(unittest.TestCase): def testStringsConvertedToBuilderEntries(self): """Tests that the easier-to-read strings get converted to BuilderEntry.""" - instance = gpu_builders.GpuBuilders(False) + instance = gpu_builders.GpuBuilders('webgl_conformance', False) builder = data_types.BuilderEntry('Win V8 FYI Release (NVIDIA)', constants.BuilderTypes.CI, False) self.assertIn(builder, instance.GetNonChromiumBuilders())
diff --git a/content/test/gpu/unexpected_passes/gpu_queries_unittest.py b/content/test/gpu/unexpected_passes/gpu_queries_unittest.py index 95a646f..175312537 100755 --- a/content/test/gpu/unexpected_passes/gpu_queries_unittest.py +++ b/content/test/gpu/unexpected_passes/gpu_queries_unittest.py
@@ -137,16 +137,19 @@ def testNoLargeQueryMode(self): """Tests that the expected clause is returned in normal mode.""" - test_filter = self._querier._GetQueryGeneratorForBuilder( - data_types.BuilderEntry('builder', 'builder_type', False)) - self.assertEqual(len(test_filter.GetClauses()), 1) + query_generator = self._querier._GetQueryGeneratorForBuilder( + data_types.BuilderEntry('builder', constants.BuilderTypes.CI, False)) + self.assertEqual(len(query_generator.GetClauses()), 1) self.assertEqual( - test_filter.GetClauses()[0], """\ + query_generator.GetClauses()[0], """\ AND REGEXP_CONTAINS( test_id, r"gpu_tests\\.pixel_integration_test\\.")""") - self.assertIsInstance(test_filter, gpu_queries.GpuFixedQueryGenerator) + self.assertIsInstance(query_generator, gpu_queries.GpuFixedQueryGenerator) self._query_mock.assert_not_called() + # Make sure that there aren't any issues with getting the queries. + q = query_generator.GetQueries() + self.assertEqual(len(q), 1) def testLargeQueryModeNoTests(self): """Tests that a special value is returned if no tests are found.""" @@ -154,9 +157,9 @@ with mock.patch.object(querier, '_RunBigQueryCommandsForJsonOutput', return_value=[]) as query_mock: - test_filter = querier._GetQueryGeneratorForBuilder( + query_generator = querier._GetQueryGeneratorForBuilder( data_types.BuilderEntry('builder', constants.BuilderTypes.CI, False)) - self.assertIsNone(test_filter) + self.assertIsNone(query_generator) query_mock.assert_called_once() def testLargeQueryModeFoundTests(self): @@ -169,11 +172,14 @@ }, { 'test_id': 'bar_test' }] - test_filter = querier._GetQueryGeneratorForBuilder( + query_generator = querier._GetQueryGeneratorForBuilder( data_types.BuilderEntry('builder', constants.BuilderTypes.CI, False)) - self.assertEqual(test_filter.GetClauses(), + self.assertEqual(query_generator.GetClauses(), ['AND test_id IN UNNEST(["foo_test", "bar_test"])']) - self.assertIsInstance(test_filter, gpu_queries.GpuSplitQueryGenerator) + self.assertIsInstance(query_generator, gpu_queries.GpuSplitQueryGenerator) + # Make sure that there aren't any issues with getting the queries. + q = query_generator.GetQueries() + self.assertEqual(len(q), 1) class GetActiveBuilderQueryUnittest(unittest.TestCase):
diff --git a/gpu/BUILD.gn b/gpu/BUILD.gn index ab55814c..32a21d22 100644 --- a/gpu/BUILD.gn +++ b/gpu/BUILD.gn
@@ -310,7 +310,6 @@ "command_buffer/tests/gl_chromium_framebuffer_mixed_samples_unittest.cc", "command_buffer/tests/gl_chromium_framebuffer_multisample_unittest.cc", "command_buffer/tests/gl_clear_framebuffer_unittest.cc", - "command_buffer/tests/gl_copy_tex_image_2d_workaround_unittest.cc", "command_buffer/tests/gl_copy_texture_CHROMIUM_unittest.cc", "command_buffer/tests/gl_cube_map_texture_unittest.cc", "command_buffer/tests/gl_depth_texture_unittest.cc", @@ -323,7 +322,6 @@ "command_buffer/tests/gl_ext_window_rectangles_unittest.cc", "command_buffer/tests/gl_gpu_memory_buffer_unittest.cc", "command_buffer/tests/gl_helper_unittest.cc", - "command_buffer/tests/gl_iosurface_readback_workaround_unittest.cc", "command_buffer/tests/gl_lose_context_chromium_unittest.cc", "command_buffer/tests/gl_manager.cc", "command_buffer/tests/gl_manager.h",
diff --git a/gpu/command_buffer/service/gles2_cmd_decoder_unittest_textures.cc b/gpu/command_buffer/service/gles2_cmd_decoder_unittest_textures.cc index 564478c..51bc65f 100644 --- a/gpu/command_buffer/service/gles2_cmd_decoder_unittest_textures.cc +++ b/gpu/command_buffer/service/gles2_cmd_decoder_unittest_textures.cc
@@ -3349,230 +3349,6 @@ EXPECT_EQ(GL_INVALID_OPERATION, GetGLError()); } -TEST_P(GLES2DecoderTest, BindTexImage2DCHROMIUM) { - DoBindTexture(GL_TEXTURE_2D, client_texture_id_, kServiceTextureId); - DoTexImage2D( - GL_TEXTURE_2D, 0, GL_RGBA, 3, 1, 0, GL_RGBA, GL_UNSIGNED_BYTE, 0, 0); - TextureRef* texture_ref = - group().texture_manager()->GetTexture(client_texture_id_); - ASSERT_TRUE(texture_ref != nullptr); - Texture* texture = texture_ref->texture(); - EXPECT_EQ(kServiceTextureId, texture->service_id()); - - scoped_refptr<gl::GLImage> image(new gl::GLImageStub); - GetImageManagerForTest()->AddImage(image.get(), 1); - EXPECT_FALSE(GetImageManagerForTest()->LookupImage(1) == nullptr); - - GLsizei width; - GLsizei height; - GLenum type; - GLenum internal_format; - - EXPECT_TRUE( - texture->GetLevelSize(GL_TEXTURE_2D, 0, &width, &height, nullptr)); - EXPECT_EQ(3, width); - EXPECT_EQ(1, height); - EXPECT_TRUE(texture->GetLevelType(GL_TEXTURE_2D, 0, &type, &internal_format)); - EXPECT_EQ(static_cast<GLenum>(GL_RGBA), internal_format); - EXPECT_EQ(static_cast<GLenum>(GL_UNSIGNED_BYTE), type); - EXPECT_TRUE(texture->GetLevelImage(GL_TEXTURE_2D, 0) == nullptr); - - // Bind image to texture. - // ScopedGLErrorSuppressor calls GetError on its constructor and destructor. - DoBindTexImage2DCHROMIUM(GL_TEXTURE_2D, 1); - EXPECT_TRUE( - texture->GetLevelSize(GL_TEXTURE_2D, 0, &width, &height, nullptr)); - // Image should now be set. - EXPECT_FALSE(texture->GetLevelImage(GL_TEXTURE_2D, 0) == nullptr); - - // Define new texture image. - DoTexImage2D( - GL_TEXTURE_2D, 0, GL_RGBA, 3, 1, 0, GL_RGBA, GL_UNSIGNED_BYTE, 0, 0); - EXPECT_TRUE( - texture->GetLevelSize(GL_TEXTURE_2D, 0, &width, &height, nullptr)); - // Image should no longer be set. - EXPECT_TRUE(texture->GetLevelImage(GL_TEXTURE_2D, 0) == nullptr); -} - -TEST_P(GLES2DecoderTest, BindTexImage2DCHROMIUMCubeMapNotAllowed) { - scoped_refptr<gl::GLImage> image(new gl::GLImageStub); - GetImageManagerForTest()->AddImage(image.get(), 1); - DoBindTexture(GL_TEXTURE_CUBE_MAP, client_texture_id_, kServiceTextureId); - - cmds::BindTexImage2DCHROMIUM bind_tex_image_2d_cmd; - bind_tex_image_2d_cmd.Init(GL_TEXTURE_CUBE_MAP, 1); - EXPECT_EQ(error::kNoError, ExecuteCmd(bind_tex_image_2d_cmd)); - EXPECT_EQ(GL_INVALID_ENUM, GetGLError()); -} - -TEST_P(GLES2DecoderTest, - BindTexImage2DWithInternalformatCHROMIUMBadInternalFormat) { - scoped_refptr<gl::GLImage> image(new gl::GLImageStub); - GetImageManagerForTest()->AddImage(image.get(), 1); - DoBindTexture(GL_TEXTURE_CUBE_MAP, client_texture_id_, kServiceTextureId); - - cmds::BindTexImage2DWithInternalformatCHROMIUM bind_tex_image_2d_cmd; - bind_tex_image_2d_cmd.Init(GL_TEXTURE_2D, GL_BACK, 1); // Invalid enum - EXPECT_EQ(error::kNoError, ExecuteCmd(bind_tex_image_2d_cmd)); - EXPECT_EQ(GL_INVALID_ENUM, GetGLError()); -} - -TEST_P(GLES2DecoderTest, OrphanGLImageWithTexImage2D) { - scoped_refptr<gl::GLImage> image(new gl::GLImageStub); - GetImageManagerForTest()->AddImage(image.get(), 1); - DoBindTexture(GL_TEXTURE_2D, client_texture_id_, kServiceTextureId); - - DoBindTexImage2DCHROMIUM(GL_TEXTURE_2D, 1); - - TextureRef* texture_ref = - group().texture_manager()->GetTexture(client_texture_id_); - ASSERT_TRUE(texture_ref != nullptr); - Texture* texture = texture_ref->texture(); - - EXPECT_TRUE(texture->GetLevelImage(GL_TEXTURE_2D, 0) == image.get()); - DoTexImage2D( - GL_TEXTURE_2D, 0, GL_RGBA, 3, 1, 0, GL_RGBA, GL_UNSIGNED_BYTE, 0, 0); - EXPECT_TRUE(texture->GetLevelImage(GL_TEXTURE_2D, 0) == nullptr); -} - -TEST_P(GLES2DecoderTest, GLImageAttachedAfterSubTexImage2D) { - // Specifically tests that TexSubImage2D is not optimized to TexImage2D - // in the presence of image attachments. - scoped_refptr<gl::GLImage> image(new gl::GLImageStub); - GetImageManagerForTest()->AddImage(image.get(), 1); - DoBindTexture(GL_TEXTURE_2D, client_texture_id_, kServiceTextureId); - - GLenum target = GL_TEXTURE_2D; - GLint level = 0; - GLint xoffset = 0; - GLint yoffset = 0; - GLsizei width = 1; - GLsizei height = 1; - GLint border = 0; - GLenum format = GL_RGBA; - GLenum type = GL_UNSIGNED_BYTE; - uint32_t pixels_shm_id = shared_memory_id_; - uint32_t pixels_shm_offset = kSharedMemoryOffset; - GLboolean internal = 0; - - // Define texture first. - DoTexImage2D(target, level, format, width, height, border, format, type, - pixels_shm_id, pixels_shm_offset); - - // Bind texture to GLImage. - DoBindTexImage2DCHROMIUM(GL_TEXTURE_2D, 1); - - // Check binding. - TextureRef* texture_ref = - group().texture_manager()->GetTexture(client_texture_id_); - ASSERT_TRUE(texture_ref != nullptr); - Texture* texture = texture_ref->texture(); - EXPECT_TRUE(texture->GetLevelImage(GL_TEXTURE_2D, 0) == image.get()); - - // TexSubImage2D should not unbind GLImage. - EXPECT_CALL(*gl_, TexSubImage2D(target, level, xoffset, yoffset, width, - height, format, type, _)) - .Times(1) - .RetiresOnSaturation(); - cmds::TexSubImage2D tex_sub_image_2d_cmd; - tex_sub_image_2d_cmd.Init(target, level, xoffset, yoffset, width, height, - format, type, pixels_shm_id, pixels_shm_offset, - internal); - EXPECT_EQ(error::kNoError, ExecuteCmd(tex_sub_image_2d_cmd)); - EXPECT_TRUE(texture->GetLevelImage(GL_TEXTURE_2D, 0) == image.get()); -} - -TEST_P(GLES2DecoderTest, GLImageAttachedAfterClearLevel) { - scoped_refptr<gl::GLImage> image(new gl::GLImageStub); - GetImageManagerForTest()->AddImage(image.get(), 1); - DoBindTexture(GL_TEXTURE_2D, client_texture_id_, kServiceTextureId); - - GLenum target = GL_TEXTURE_2D; - GLint level = 0; - GLint xoffset = 0; - GLint yoffset = 0; - GLsizei width = 1; - GLsizei height = 1; - GLint border = 0; - GLenum format = GL_RGBA; - GLenum type = GL_UNSIGNED_BYTE; - uint32_t pixels_shm_id = shared_memory_id_; - uint32_t pixels_shm_offset = kSharedMemoryOffset; - - // Define texture first. - DoTexImage2D(target, level, format, width, height, border, format, type, - pixels_shm_id, pixels_shm_offset); - - // Bind texture to GLImage. - DoBindTexImage2DCHROMIUM(GL_TEXTURE_2D, 1); - - // Check binding. - TextureRef* texture_ref = - group().texture_manager()->GetTexture(client_texture_id_); - ASSERT_TRUE(texture_ref != nullptr); - Texture* texture = texture_ref->texture(); - EXPECT_TRUE(texture->GetLevelImage(GL_TEXTURE_2D, 0) == image.get()); - - // ClearLevel should use glTexSubImage2D to avoid unbinding GLImage. - SetupClearTextureExpectations(kServiceTextureId, kServiceTextureId, - GL_TEXTURE_2D, GL_TEXTURE_2D, level, format, - type, xoffset, yoffset, width, height, 0); - GetDecoder()->ClearLevel(texture, target, level, format, type, 0, 0, width, - height); - EXPECT_TRUE(texture->GetLevelImage(GL_TEXTURE_2D, 0) == image.get()); -} - -TEST_P(GLES2DecoderTest, ReleaseTexImage2DCHROMIUM) { - DoBindTexture(GL_TEXTURE_2D, client_texture_id_, kServiceTextureId); - DoTexImage2D( - GL_TEXTURE_2D, 0, GL_RGBA, 3, 1, 0, GL_RGBA, GL_UNSIGNED_BYTE, 0, 0); - TextureRef* texture_ref = - group().texture_manager()->GetTexture(client_texture_id_); - ASSERT_TRUE(texture_ref != nullptr); - Texture* texture = texture_ref->texture(); - EXPECT_EQ(kServiceTextureId, texture->service_id()); - - scoped_refptr<gl::GLImage> image(new gl::GLImageStub); - GetImageManagerForTest()->AddImage(image.get(), 1); - EXPECT_FALSE(GetImageManagerForTest()->LookupImage(1) == nullptr); - - GLsizei width; - GLsizei height; - GLenum type; - GLenum internal_format; - - EXPECT_TRUE( - texture->GetLevelSize(GL_TEXTURE_2D, 0, &width, &height, nullptr)); - EXPECT_EQ(3, width); - EXPECT_EQ(1, height); - EXPECT_TRUE(texture->GetLevelType(GL_TEXTURE_2D, 0, &type, &internal_format)); - EXPECT_EQ(static_cast<GLenum>(GL_RGBA), internal_format); - EXPECT_EQ(static_cast<GLenum>(GL_UNSIGNED_BYTE), type); - EXPECT_TRUE(texture->GetLevelImage(GL_TEXTURE_2D, 0) == nullptr); - - // Bind image to texture. - // ScopedGLErrorSuppressor calls GetError on its constructor and destructor. - DoBindTexImage2DCHROMIUM(GL_TEXTURE_2D, 1); - EXPECT_TRUE( - texture->GetLevelSize(GL_TEXTURE_2D, 0, &width, &height, nullptr)); - // Image should now be set. - EXPECT_FALSE(texture->GetLevelImage(GL_TEXTURE_2D, 0) == nullptr); - - // Release image from texture. - // ScopedGLErrorSuppressor calls GetError on its constructor and destructor. - EXPECT_CALL(*gl_, GetError()) - .WillOnce(Return(GL_NO_ERROR)) - .WillOnce(Return(GL_NO_ERROR)) - .RetiresOnSaturation(); - cmds::ReleaseTexImage2DCHROMIUM release_tex_image_2d_cmd; - release_tex_image_2d_cmd.Init(GL_TEXTURE_2D, 1); - EXPECT_EQ(error::kNoError, ExecuteCmd(release_tex_image_2d_cmd)); - EXPECT_TRUE( - texture->GetLevelSize(GL_TEXTURE_2D, 0, &width, &height, nullptr)); - // Image should no longer be set. - EXPECT_TRUE(texture->GetLevelImage(GL_TEXTURE_2D, 0) == nullptr); -} - class MockGLImage : public gl::GLImage { public: MockGLImage() = default; @@ -3599,155 +3375,6 @@ ~MockGLImage() override = default; }; -TEST_P(GLES2DecoderWithShaderTest, CopyTexImage) { - DoBindTexture(GL_TEXTURE_2D, client_texture_id_, kServiceTextureId); - DoTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA, 1, 1, 0, GL_RGBA, GL_UNSIGNED_BYTE, - shared_memory_id_, kSharedMemoryOffset); - - TextureRef* texture_ref = - group().texture_manager()->GetTexture(client_texture_id_); - ASSERT_TRUE(texture_ref != nullptr); - Texture* texture = texture_ref->texture(); - EXPECT_EQ(kServiceTextureId, texture->service_id()); - - const int32_t kImageId = 1; - scoped_refptr<MockGLImage> image(new MockGLImage); - GetImageManagerForTest()->AddImage(image.get(), kImageId); - - // Bind image to texture. - EXPECT_CALL(*image.get(), ShouldBindOrCopy()) - .WillRepeatedly(Return(gl::GLImage::COPY)); - EXPECT_CALL(*image.get(), BindTexImage(GL_TEXTURE_2D)) - .Times(0) - .RetiresOnSaturation(); - EXPECT_CALL(*image.get(), GetSize()) - .Times(1) - .WillOnce(Return(gfx::Size(1, 1))) - .RetiresOnSaturation(); - EXPECT_CALL(*image.get(), GetInternalFormat()) - .Times(1) - .WillOnce(Return(GL_RGBA)) - .RetiresOnSaturation(); - EXPECT_CALL(*image.get(), GetDataFormat()) - .Times(1) - .WillOnce(Return(GL_RGBA)) - .RetiresOnSaturation(); - EXPECT_CALL(*image.get(), GetDataType()) - .Times(1) - .WillOnce(Return(GL_UNSIGNED_BYTE)) - .RetiresOnSaturation(); - // ScopedGLErrorSuppressor calls GetError on its constructor and destructor. - DoBindTexImage2DCHROMIUM(GL_TEXTURE_2D, kImageId); - Mock::VerifyAndClearExpectations(gl_.get()); - - EXPECT_CALL(*gl_, ActiveTexture(GL_TEXTURE1)).Times(1).RetiresOnSaturation(); - cmds::ActiveTexture texture_cmd; - texture_cmd.Init(GL_TEXTURE1); - EXPECT_EQ(error::kNoError, ExecuteCmd(texture_cmd)); - Mock::VerifyAndClearExpectations(gl_.get()); - - AddExpectationsForSimulatedAttrib0(kNumVertices, 0); - SetupExpectationsForApplyingDefaultDirtyState(); - - // ScopedGLErrorSuppressor calls GetError on its constructor and destructor. - EXPECT_CALL(*gl_, GetError()) - .WillOnce(Return(GL_NO_ERROR)) - .WillOnce(Return(GL_NO_ERROR)) - .RetiresOnSaturation(); - EXPECT_CALL(*gl_, BindTexture(GL_TEXTURE_2D, kServiceTextureId)) - .Times(1) - .RetiresOnSaturation(); - { - InSequence seq; - EXPECT_CALL(*gl_, ActiveTexture(GL_TEXTURE0)) - .Times(1) - .RetiresOnSaturation(); - EXPECT_CALL(*image.get(), BindTexImage(GL_TEXTURE_2D)) - .Times(0) - .RetiresOnSaturation(); - EXPECT_CALL(*image.get(), CopyTexImage(GL_TEXTURE_2D)) - .Times(1) - .WillOnce(Return(true)) - .RetiresOnSaturation(); - EXPECT_CALL(*gl_, DrawArrays(GL_TRIANGLES, 0, kNumVertices)) - .Times(1) - .RetiresOnSaturation(); - EXPECT_CALL(*gl_, ActiveTexture(GL_TEXTURE1)) - .Times(1) - .RetiresOnSaturation(); - } - - cmds::DrawArrays cmd; - cmd.Init(GL_TRIANGLES, 0, kNumVertices); - EXPECT_EQ(error::kNoError, ExecuteCmd(cmd)); - EXPECT_EQ(GL_NO_ERROR, GetGLError()); - - DoBindTexture(GL_TEXTURE_2D, client_texture_id_, kServiceTextureId); - - Mock::VerifyAndClearExpectations(gl_.get()); - // Re-bind image to texture. - cmds::ReleaseTexImage2DCHROMIUM release_tex_image_2d_cmd; - release_tex_image_2d_cmd.Init(GL_TEXTURE_2D, kImageId); - EXPECT_EQ(error::kNoError, ExecuteCmd(release_tex_image_2d_cmd)); - EXPECT_CALL(*image.get(), BindTexImage(GL_TEXTURE_2D)) - .Times(0) - .RetiresOnSaturation(); - EXPECT_CALL(*image.get(), GetSize()) - .Times(1) - .WillOnce(Return(gfx::Size(1, 1))) - .RetiresOnSaturation(); - EXPECT_CALL(*image.get(), GetInternalFormat()) - .Times(1) - .WillOnce(Return(GL_RGBA)) - .RetiresOnSaturation(); - EXPECT_CALL(*image.get(), GetDataFormat()) - .Times(1) - .WillOnce(Return(GL_RGBA)) - .RetiresOnSaturation(); - EXPECT_CALL(*image.get(), GetDataType()) - .Times(1) - .WillOnce(Return(GL_UNSIGNED_BYTE)) - .RetiresOnSaturation(); - DoBindTexImage2DCHROMIUM(GL_TEXTURE_2D, kImageId); - - DoBindFramebuffer( - GL_FRAMEBUFFER, client_framebuffer_id_, kServiceFramebufferId); - // ScopedGLErrorSuppressor calls GetError on its constructor and destructor. - EXPECT_CALL(*gl_, GetError()) - .WillOnce(Return(GL_NO_ERROR)) - .WillOnce(Return(GL_NO_ERROR)) - .RetiresOnSaturation(); - EXPECT_CALL(*gl_, BindTexture(GL_TEXTURE_2D, kServiceTextureId)) - .Times(2) - .RetiresOnSaturation(); - EXPECT_CALL(*image.get(), CopyTexImage(GL_TEXTURE_2D)) - .Times(1) - .WillOnce(Return(true)) - .RetiresOnSaturation(); - EXPECT_CALL(*gl_, - FramebufferTexture2DEXT(GL_FRAMEBUFFER, - GL_COLOR_ATTACHMENT0, - GL_TEXTURE_2D, - kServiceTextureId, - 0)) - .Times(1) - .RetiresOnSaturation(); - EXPECT_CALL(*gl_, GetError()) - .WillOnce(Return(GL_NO_ERROR)) - .WillOnce(Return(GL_NO_ERROR)) - .RetiresOnSaturation(); - cmds::FramebufferTexture2D fbtex_cmd; - fbtex_cmd.Init(GL_FRAMEBUFFER, - GL_COLOR_ATTACHMENT0, - GL_TEXTURE_2D, - client_texture_id_, - 0); - EXPECT_EQ(error::kNoError, ExecuteCmd(fbtex_cmd)); - EXPECT_EQ(GL_NO_ERROR, GetGLError()); - - image = nullptr; -} - TEST_P(GLES2DecoderManualInitTest, DrawWithGLImageExternal) { InitState init; init.extensions = "GL_OES_EGL_image_external"; @@ -4413,80 +4040,6 @@ EXPECT_EQ(GL_INVALID_VALUE, GetGLError()); } -// Test that copyTexImage2D uses the emulated internal format, rather than the -// real internal format. -TEST_P(GLES2DecoderWithShaderTest, CHROMIUMImageEmulatingRGB) { - const GLuint kFBOClientTextureId = 4100; - const GLuint kFBOServiceTextureId = 4101; - GLenum target = GL_TEXTURE_2D; - GLint level = 0; - GLsizei width = 1; - GLsizei height = 1; - - // Generate the source framebuffer. - EXPECT_CALL(*gl_, GenTextures(_, _)) - .WillOnce(SetArgPointee<1>(kFBOServiceTextureId)) - .RetiresOnSaturation(); - GenHelper<cmds::GenTexturesImmediate>(kFBOClientTextureId); - DoBindFramebuffer(GL_FRAMEBUFFER, client_framebuffer_id_, - kServiceFramebufferId); - - GLenum destination_texture_formats[] = {GL_RGBA, GL_RGB}; - for (int use_rgb_emulation = 0; use_rgb_emulation < 2; ++ use_rgb_emulation) { - for (size_t destination_texture_index = 0; destination_texture_index < 2; - ++destination_texture_index) { - // Generate and bind the source image. Making a new image for each set of - // parameters is easier than trying to reuse images. Obviously there's no - // performance penalty. - int image_id = use_rgb_emulation * 2 + destination_texture_index; - scoped_refptr<gl::GLImage> image; - if (use_rgb_emulation) - image = new EmulatingRGBImageStub; - else - image = new gl::GLImageStub; - GetImageManagerForTest()->AddImage(image.get(), image_id); - EXPECT_FALSE(GetImageManagerForTest()->LookupImage(image_id) == nullptr); - DoBindTexture(GL_TEXTURE_2D, kFBOClientTextureId, kFBOServiceTextureId); - - DoBindTexImage2DCHROMIUM(GL_TEXTURE_2D, image_id); - DoFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, target, - kFBOClientTextureId, kFBOServiceTextureId, level, - GL_NO_ERROR); - - GLenum destination_texture_format = - destination_texture_formats[destination_texture_index]; - bool should_succeed = - !use_rgb_emulation || (destination_texture_format == GL_RGB); - if (should_succeed) { - EXPECT_CALL(*gl_, GetError()) - .WillOnce(Return(GL_NO_ERROR)) - .RetiresOnSaturation(); - EXPECT_CALL(*gl_, - CopyTexImage2D(GL_TEXTURE_2D, 0, destination_texture_format, - 0, 0, 1, 1, 0)) - .Times(1) - .RetiresOnSaturation(); - EXPECT_CALL(*gl_, GetError()) - .WillOnce(Return(GL_NO_ERROR)) - .RetiresOnSaturation(); - } - - if (destination_texture_index == 0 || !framebuffer_completeness_cache()) { - EXPECT_CALL(*gl_, CheckFramebufferStatusEXT(GL_FRAMEBUFFER)) - .WillOnce(Return(GL_FRAMEBUFFER_COMPLETE)) - .RetiresOnSaturation(); - } - - DoBindTexture(GL_TEXTURE_2D, client_texture_id_, kServiceTextureId); - cmds::CopyTexImage2D cmd; - cmd.Init(target, level, destination_texture_format, 0, 0, width, height); - EXPECT_EQ(error::kNoError, ExecuteCmd(cmd)); - GLenum expectation = should_succeed ? GL_NO_ERROR : GL_INVALID_OPERATION; - EXPECT_EQ(expectation, static_cast<GLenum>(GetGLError())); - } - } -} - TEST_P(GLES2DecoderTest, BindTextureValidArgs) { EXPECT_CALL(*gl_, BindTexture(GL_TEXTURE_2D, kServiceTextureId)) .Times(1)
diff --git a/gpu/command_buffer/tests/gl_copy_tex_image_2d_workaround_unittest.cc b/gpu/command_buffer/tests/gl_copy_tex_image_2d_workaround_unittest.cc deleted file mode 100644 index 010dfc5..0000000 --- a/gpu/command_buffer/tests/gl_copy_tex_image_2d_workaround_unittest.cc +++ /dev/null
@@ -1,181 +0,0 @@ -// Copyright 2016 The Chromium Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#ifndef GL_GLEXT_PROTOTYPES -#define GL_GLEXT_PROTOTYPES -#endif - -#include <GLES2/gl2.h> -#include <GLES2/gl2ext.h> -#include <GLES2/gl2extchromium.h> - -#include "base/strings/stringize_macros.h" -#include "base/strings/stringprintf.h" -#include "build/build_config.h" -#include "gpu/command_buffer/tests/gl_manager.h" -#include "gpu/command_buffer/tests/gl_test_utils.h" -#include "testing/gtest/include/gtest/gtest.h" - -namespace gpu { - -#if BUILDFLAG(IS_MAC) -namespace { - -// clang-format off -static const char* kSimpleVertexShader = STRINGIZE( - attribute vec2 a_position; - varying vec2 v_texCoord; - void main() { - gl_Position = vec4(a_position.x, a_position.y, 0.0, 1.0); - v_texCoord = (a_position + vec2(1.0, 1.0)) * 0.5; - } -); -// clang-format on - -// Generate fragment shader source for sampling out of a texture of |size| -// bound to |target|. -std::string GetFragmentShaderSource(unsigned target, const gfx::Size& size) { - // clang-format off - const char kFragmentShader[] = STRINGIZE( - uniform SamplerType u_texture; - varying vec2 v_texCoord; - void main() { - gl_FragColor = TextureLookup(u_texture, v_texCoord * TextureScale); - } - ); - const char kShaderFloatPrecision[] = STRINGIZE( - precision mediump float; - ); - // clang-format on - - switch (target) { - case GL_TEXTURE_2D: - return base::StringPrintf( - "%s\n" - "#define SamplerType sampler2D\n" - "#define TextureLookup texture2D\n" - "#define TextureScale vec2(1.0, 1.0)\n" - "%s", - kShaderFloatPrecision, kFragmentShader); - case GL_TEXTURE_RECTANGLE_ARB: - return base::StringPrintf( - "%s\n" - "#extension GL_ARB_texture_rectangle : require\n" - "#define SamplerType sampler2DRect\n" - "#define TextureLookup texture2DRect\n" - "#define TextureScale vec2(%f, %f)\n" - "%s", - kShaderFloatPrecision, static_cast<double>(size.width()), - static_cast<double>(size.height()), kFragmentShader); - default: - NOTREACHED(); - return std::string(); - } -} - -} // namespace - -// A collection of tests that exercise the glCopyTexImage2D workaround. The -// parameter expresses different formats of the destination texture. -class GLCopyTexImage2DWorkaroundTest : public testing::TestWithParam<GLenum> { - public: - GLCopyTexImage2DWorkaroundTest() {} - - protected: - void SetUp() override { - GpuDriverBugWorkarounds workarounds; - workarounds.use_intermediary_for_copy_texture_image = true; - gl_.InitializeWithWorkarounds(GLManager::Options(), workarounds); - gl_.set_use_iosurface_memory_buffers(true); - DCHECK(gl_.workarounds().use_intermediary_for_copy_texture_image); - } - - void TearDown() override { - GLTestHelper::CheckGLError("no errors", __LINE__); - gl_.Destroy(); - } - - GLManager gl_; -}; - -INSTANTIATE_TEST_SUITE_P(GLCopyTexImage2DWorkaroundTestWithParam, - GLCopyTexImage2DWorkaroundTest, - ::testing::Values(GL_RGBA)); - -TEST_P(GLCopyTexImage2DWorkaroundTest, UseIntermediaryTexture) { - int width = 1; - int height = 1; - GLuint source_texture = 0; - GLenum source_target = GL_TEXTURE_RECTANGLE_ARB; - glGenTextures(1, &source_texture); - glBindTexture(source_target, source_texture); - glTexParameteri(source_target, GL_TEXTURE_MIN_FILTER, GL_LINEAR); - glTexParameteri(source_target, GL_TEXTURE_MAG_FILTER, GL_LINEAR); - std::unique_ptr<gfx::GpuMemoryBuffer> buffer(gl_.CreateGpuMemoryBuffer( - gfx::Size(width, height), gfx::BufferFormat::RGBA_8888)); - GLuint image_id = - glCreateImageCHROMIUM(buffer->AsClientBuffer(), width, height, GL_RGBA); - ASSERT_NE(0u, image_id); - glBindTexImage2DCHROMIUM(source_target, image_id); - - GLuint framebuffer = 0; - glGenFramebuffers(1, &framebuffer); - glBindFramebuffer(GL_FRAMEBUFFER, framebuffer); - glFramebufferTexture2D( - GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, source_target, source_texture, 0); - EXPECT_EQ(static_cast<GLenum>(GL_FRAMEBUFFER_COMPLETE), - glCheckFramebufferStatus(GL_FRAMEBUFFER)); - - - GLenum dest_formats[] = {GL_RGBA, GL_RGB, GL_ALPHA, GL_LUMINANCE}; - const uint8_t expectations[4][4] = { - {33, 44, 55, 66}, {33, 44, 55, 255}, {0, 0, 0, 66}, {33, 33, 33, 255}}; - for (size_t i = 0; i < sizeof(dest_formats) / sizeof(GLenum); ++i) { - glClearColor(33.0 / 255.0, 44.0 / 255.0, 55.0 / 255.0, 66.0 / 255.0); - glClear(GL_COLOR_BUFFER_BIT); - EXPECT_EQ(glGetError(), GLenum(GL_NO_ERROR)); - - GLuint dest_texture = 0; - GLenum dest_target = GL_TEXTURE_2D; - GLenum dest_format = dest_formats[i]; - glGenTextures(1, &dest_texture); - glBindTexture(dest_target, dest_texture); - glTexParameteri(dest_target, GL_TEXTURE_MIN_FILTER, GL_LINEAR); - glTexParameteri(dest_target, GL_TEXTURE_MAG_FILTER, GL_LINEAR); - - glCopyTexImage2D(dest_target, 0, dest_format, 0, 0, width, height, 0); - EXPECT_EQ(glGetError(), GLenum(GL_NO_ERROR)); - - // Check that bound textures haven't changed. - GLint boundTexture = -1; - glGetIntegerv(GL_TEXTURE_BINDING_RECTANGLE_ARB, &boundTexture); - EXPECT_EQ(glGetError(), GLenum(GL_NO_ERROR)); - EXPECT_EQ(static_cast<GLint>(source_texture), boundTexture); - - boundTexture = -1; - glGetIntegerv(GL_TEXTURE_BINDING_2D, &boundTexture); - EXPECT_EQ(glGetError(), GLenum(GL_NO_ERROR)); - EXPECT_EQ(static_cast<GLint>(dest_texture), boundTexture); - - glClearColor(1.0 / 255.0, 2.0 / 255.0, 3.0 / 255.0, 4.0 / 255.0); - glClear(GL_COLOR_BUFFER_BIT); - EXPECT_EQ(glGetError(), GLenum(GL_NO_ERROR)); - - glViewport(0, 0, width, height); - std::string fragment_shader_source = - GetFragmentShaderSource(dest_target, gfx::Size(width, height)); - GLTestHelper::DrawTextureQuad(dest_target, kSimpleVertexShader, - fragment_shader_source.c_str(), "a_position", - "u_texture", nullptr); - - // Verify. - const uint8_t* expected = expectations[i]; - EXPECT_TRUE(GLTestHelper::CheckPixels(0, 0, 1, 1, 1 /* tolerance */, - expected, nullptr)); - } -} - -#endif // BUILDFLAG(IS_MAC) - -} // namespace gpu
diff --git a/gpu/command_buffer/tests/gl_copy_texture_CHROMIUM_unittest.cc b/gpu/command_buffer/tests/gl_copy_texture_CHROMIUM_unittest.cc index 6333588..dfacc13 100644 --- a/gpu/command_buffer/tests/gl_copy_texture_CHROMIUM_unittest.cc +++ b/gpu/command_buffer/tests/gl_copy_texture_CHROMIUM_unittest.cc
@@ -406,26 +406,14 @@ void TearDown() override { gl_.Destroy(); } - void CreateBackingForTexture(GLenum target, GLsizei width, GLsizei height) { - if (target == GL_TEXTURE_RECTANGLE_ARB) { - std::unique_ptr<gfx::GpuMemoryBuffer> buffer(gl_.CreateGpuMemoryBuffer( - gfx::Size(width, height), gfx::BufferFormat::RGBA_8888)); - GLuint image_id = glCreateImageCHROMIUM(buffer->AsClientBuffer(), width, - height, GL_RGBA); - glBindTexImage2DCHROMIUM(target, image_id); - } else { - glTexImage2D(target, 0, GL_RGBA, width, height, 0, GL_RGBA, - GL_UNSIGNED_BYTE, nullptr); - } - } - GLuint CreateDrawingTexture(GLenum target, GLsizei width, GLsizei height) { GLuint texture = 0; glGenTextures(1, &texture); glBindTexture(target, texture); glTexParameteri(target, GL_TEXTURE_MIN_FILTER, GL_NEAREST); glTexParameteri(target, GL_TEXTURE_MAG_FILTER, GL_NEAREST); - CreateBackingForTexture(target, width, height); + glTexImage2D(target, 0, GL_RGBA, width, height, 0, GL_RGBA, + GL_UNSIGNED_BYTE, nullptr); return texture; } @@ -1780,97 +1768,4 @@ glDeleteFramebuffers(1, &framebuffer_id_); } -TEST_F(GLCopyTextureCHROMIUMTest, CopyTextureBetweenTexture2DAndRectangleArb) { - if (!GLTestHelper::HasExtension("GL_ARB_texture_rectangle")) { - LOG(INFO) << - "GL_ARB_texture_rectangle not supported. Skipping test..."; - return; - } - - GLenum src_targets[] = {GL_TEXTURE_RECTANGLE_ARB, GL_TEXTURE_2D}; - GLenum dest_targets[] = {GL_TEXTURE_RECTANGLE_ARB, GL_TEXTURE_2D}; - GLsizei src_width = 30; - GLsizei src_height = 14; - GLsizei dest_width = 15; - GLsizei dest_height = 13; - GLsizei copy_region_x = 1; - GLsizei copy_region_y = 1; - GLsizei copy_region_width = 5; - GLsizei copy_region_height = 3; - uint8_t red[1 * 4] = {255u, 0u, 0u, 255u}; - uint8_t blue[1 * 4] = {0u, 0u, 255u, 255u}; - uint8_t green[1 * 4] = {0u, 255u, 0, 255u}; - uint8_t white[1 * 4] = {255u, 255u, 255u, 255u}; - uint8_t grey[1 * 4] = {199u, 199u, 199u, 255u}; - - for (size_t src_index = 0; src_index < std::size(src_targets); src_index++) { - GLenum src_target = src_targets[src_index]; - for (size_t dest_index = 0; dest_index < std::size(dest_targets); - dest_index++) { - GLenum dest_target = dest_targets[dest_index]; - - CreateAndBindDestinationTextureAndFBO(dest_target); - - // Allocate source and destination textures. - glBindTexture(src_target, textures_[0]); - CreateBackingForTexture(src_target, src_width, src_height); - - glBindTexture(dest_target, textures_[1]); - CreateBackingForTexture(dest_target, dest_width, dest_height); - - // The bottom left is red, bottom right is blue, top left is green, top - // right is white. - glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, src_target, - textures_[0], 0); - glBindTexture(src_target, textures_[0]); - for (GLint x = 0; x < src_width; ++x) { - for (GLint y = 0; y < src_height; ++y) { - uint8_t* data; - if (x < src_width / 2) { - data = y < src_height / 2 ? red : green; - } else { - data = y < src_height / 2 ? blue : white; - } - glTexSubImage2D(src_target, 0, x, y, 1, 1, GL_RGBA, GL_UNSIGNED_BYTE, - data); - } - } - - glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, dest_target, - textures_[1], 0); - glBindTexture(dest_target, textures_[1]); - - // Copy the subtexture x=[13,18) y=[6,9) to the destination. - glClearColor(grey[0] / 255.f, grey[1] / 255.f, grey[2] / 255.f, 1.0); - glClear(GL_COLOR_BUFFER_BIT); - glCopySubTextureCHROMIUM(textures_[0], 0, dest_target, textures_[1], 0, - copy_region_x, copy_region_y, 13, 6, - copy_region_width, copy_region_height, false, - false, false); - EXPECT_TRUE(GL_NO_ERROR == glGetError()); - - for (GLint x = 0; x < dest_width; ++x) { - for (GLint y = 0; y < dest_height; ++y) { - if (x < copy_region_x || x >= copy_region_x + copy_region_width || - y < copy_region_y || y >= copy_region_y + copy_region_height) { - GLTestHelper::CheckPixels(x, y, 1, 1, 0, grey, nullptr); - continue; - } - - uint8_t* expected_color; - if (x < copy_region_x + 2) { - expected_color = y < copy_region_y + 1 ? red : green; - } else { - expected_color = y < copy_region_y + 1 ? blue : white; - } - GLTestHelper::CheckPixels(x, y, 1, 1, 0, expected_color, nullptr); - } - } - - glDeleteTextures(2, textures_); - glDeleteFramebuffers(1, &framebuffer_id_); - } - } -} - } // namespace gpu
diff --git a/gpu/command_buffer/tests/gl_gpu_memory_buffer_unittest.cc b/gpu/command_buffer/tests/gl_gpu_memory_buffer_unittest.cc index dfc5965..27594417 100644 --- a/gpu/command_buffer/tests/gl_gpu_memory_buffer_unittest.cc +++ b/gpu/command_buffer/tests/gl_gpu_memory_buffer_unittest.cc
@@ -96,62 +96,6 @@ #define SHADER(Src) #Src -// clang-format off -const char kVertexShader[] = -SHADER( - attribute vec4 a_position; - varying vec2 v_texCoord; - void main() { - gl_Position = a_position; - v_texCoord = vec2((a_position.x + 1.0) * 0.5, (a_position.y + 1.0) * 0.5); - } -); - -const char* kFragmentShader = -SHADER( - precision mediump float; - uniform sampler2D a_texture; - varying vec2 v_texCoord; - void main() { - gl_FragColor = texture2D(a_texture, v_texCoord); - } -); -// clang-format on - -GLenum InternalFormat(gfx::BufferFormat format) { - switch (format) { - case gfx::BufferFormat::R_8: - return GL_RED; - case gfx::BufferFormat::R_16: - return GL_R16_EXT; - case gfx::BufferFormat::RG_88: - return GL_RG; - case gfx::BufferFormat::RG_1616: - return GL_RG16_EXT; - case gfx::BufferFormat::BGR_565: - case gfx::BufferFormat::RGBA_1010102: - return GL_RGB; - case gfx::BufferFormat::RGBA_4444: - case gfx::BufferFormat::RGBA_8888: - return GL_RGBA; - case gfx::BufferFormat::BGRA_8888: - case gfx::BufferFormat::BGRA_1010102: - return GL_BGRA_EXT; - case gfx::BufferFormat::RGBA_F16: - return GL_RGBA; - case gfx::BufferFormat::BGRX_8888: - case gfx::BufferFormat::RGBX_8888: - case gfx::BufferFormat::YVU_420: - case gfx::BufferFormat::YUV_420_BIPLANAR: - case gfx::BufferFormat::P010: - NOTREACHED() << gfx::BufferFormatToString(format); - return 0; - } - - NOTREACHED(); - return 0; -} - uint32_t BufferFormatToFourCC(gfx::BufferFormat format) { switch (format) { case gfx::BufferFormat::BGR_565: @@ -248,238 +192,6 @@ buffer->Unmap(); } -// An end to end test that tests the whole GpuMemoryBuffer lifecycle. -TEST_P(GpuMemoryBufferTest, Lifecycle) { - // TODO(jonahr): Test fails on Mac with ANGLE/passthrough - // (crbug.com/1100970) - gpu::GPUTestBotConfig bot_config; - if (bot_config.LoadCurrentConfig(nullptr) && - bot_config.Matches("mac passthrough")) { - return; - } - - const gfx::BufferFormat buffer_format = GetParam(); - - if (buffer_format == gfx::BufferFormat::R_8 && - !gl_.GetCapabilities().texture_rg) { - LOG(WARNING) << "texture_rg not supported. Skipping test."; - return; - } - - if (buffer_format == gfx::BufferFormat::RGBA_F16 && - !gl_.GetCapabilities().texture_half_float_linear) { - LOG(WARNING) << "texture_half_float_linear not supported. Skipping test."; - return; - } - - if (buffer_format == gfx::BufferFormat::RGBA_1010102 && - !gl_.GetCapabilities().image_ab30) { - LOG(WARNING) << "image_ab30 not supported. Skipping test."; - return; - } - - if (buffer_format == gfx::BufferFormat::BGRA_1010102 && - !gl_.GetCapabilities().image_ar30) { - LOG(WARNING) << "image_ar30 not supported. Skipping test."; - return; - } - - if (buffer_format == gfx::BufferFormat::YVU_420 || - buffer_format == gfx::BufferFormat::YUV_420_BIPLANAR) { - LOG(WARNING) << "GLImageMemory doesn't support YUV formats, skipping test."; - return; - } - - GLuint texture_id = 0; - glGenTextures(1, &texture_id); - ASSERT_NE(0u, texture_id); - glBindTexture(GL_TEXTURE_2D, texture_id); - glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE); - glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE); - glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST); - glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST); - - // Create the gpu memory buffer. - std::unique_ptr<gfx::GpuMemoryBuffer> buffer(gl_.CreateGpuMemoryBuffer( - gfx::Size(kImageWidth, kImageHeight), buffer_format)); - - // Map buffer for writing. - ASSERT_TRUE(buffer->Map()); - ASSERT_NE(nullptr, buffer->memory(0)); - ASSERT_NE(0, buffer->stride(0)); - constexpr uint8_t pixel[] = {255u, 0u, 0u, 255u}; - - const size_t num_planes = NumberOfPlanesForLinearBufferFormat(buffer_format); - for (size_t plane = 0; plane < num_planes; ++plane) { - gl::GLImageTestSupport::SetBufferDataToColor( - kImageWidth, kImageHeight, buffer->stride(plane), plane, buffer_format, - pixel, static_cast<uint8_t*>(buffer->memory(0))); - } - buffer->Unmap(); - - // Create the image. This should add the image ID to the ImageManager. - GLuint image_id = - glCreateImageCHROMIUM(buffer->AsClientBuffer(), kImageWidth, kImageHeight, - InternalFormat(buffer_format)); - ASSERT_NE(0u, image_id); - ASSERT_TRUE(gl_.decoder()->GetImageManagerForTest()->LookupImage(image_id) != - nullptr); - - // Bind the image. - glBindTexImage2DCHROMIUM(GL_TEXTURE_2D, image_id); - - // Build program, buffers and draw the texture. - GLuint vertex_shader = - GLTestHelper::LoadShader(GL_VERTEX_SHADER, kVertexShader); - GLuint fragment_shader = - GLTestHelper::LoadShader(GL_FRAGMENT_SHADER, kFragmentShader); - GLuint program = GLTestHelper::SetupProgram(vertex_shader, fragment_shader); - ASSERT_NE(0u, program); - glUseProgram(program); - - GLint sampler_location = glGetUniformLocation(program, "a_texture"); - ASSERT_NE(-1, sampler_location); - glUniform1i(sampler_location, 0); - - GLuint vbo = - GLTestHelper::SetupUnitQuad(glGetAttribLocation(program, "a_position")); - ASSERT_NE(0u, vbo); - glViewport(0, 0, kImageWidth, kImageHeight); - glDrawArrays(GL_TRIANGLES, 0, 6); - ASSERT_TRUE(glGetError() == GL_NO_ERROR); - - // Check if pixels match the values that were assigned to the mapped buffer. - GLTestHelper::CheckPixels(0, 0, kImageWidth, kImageHeight, 0, pixel, nullptr); - EXPECT_TRUE(GL_NO_ERROR == glGetError()); - - // Release the image. - glReleaseTexImage2DCHROMIUM(GL_TEXTURE_2D, image_id); - - // Clean up. - glDeleteProgram(program); - glDeleteShader(vertex_shader); - glDeleteShader(fragment_shader); - glDeleteBuffers(1, &vbo); - glDestroyImageCHROMIUM(image_id); - glDeleteTextures(1, &texture_id); -} - -#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) -// Test glCreateImageCHROMIUM with gfx::NATIVE_PIXMAP. Basically the test -// reproduces the situation where some dmabuf fds are available outside the -// gpu process and the user wants to import them using glCreateImageCHROMIUM. -// It can be the case when vaapi is setup in a media service hosted in a -// dedicated process, i.e. not the gpu process. -TEST_F(GpuMemoryBufferTestEGL, GLCreateImageCHROMIUMFromNativePixmap) { - SKIP_TEST_IF(!egl_initialized_); - - // This extension is required for glCreateImageCHROMIUM on Linux. - SKIP_TEST_IF(!HasEGLExtension("EGL_EXT_image_dma_buf_import")); - - // This extension is required for the test to work but not for the real - // world, see CreateNativePixmapHandle. - SKIP_TEST_IF(!HasEGLExtension("EGL_MESA_image_dma_buf_export")); - - // This extension is required for glCreateImageCHROMIUM on Linux. - SKIP_TEST_IF(!HasGLExtension("GL_OES_EGL_image")); - - gfx::BufferFormat format = gfx::BufferFormat::RGBX_8888; - gfx::Size size(kImageWidth, kImageHeight); - size_t buffer_size = gfx::BufferSizeForBufferFormat(size, format); - uint8_t pixel[] = {255u, 0u, 0u, 255u}; - size_t plane = 0; - uint32_t stride = gfx::RowSizeForBufferFormat(size.width(), format, plane); - - std::unique_ptr<uint8_t[]> pixels(new uint8_t[buffer_size]); - - gl::GLImageTestSupport::SetBufferDataToColor(kImageWidth, kImageHeight, - stride, 0 /* plane */, format, - pixel, pixels.get()); - - // A real use case would be to export a VAAPI surface as dmabuf fds. But for - // simplicity the test gets them from a GL texture. - gfx::NativePixmapHandle native_pixmap_handle = - CreateNativePixmapHandle(format, size, pixels.get()); - EXPECT_EQ(1u, native_pixmap_handle.planes.size()); - - // Initialize a GpuMemoryBufferHandle to wrap a native pixmap. - gfx::GpuMemoryBufferHandle handle; - handle.type = gfx::NATIVE_PIXMAP; - handle.native_pixmap_handle = std::move(native_pixmap_handle); - EXPECT_TRUE(handle.id.is_valid()); - - // Create a GMB to pass to glCreateImageCHROMIUM. - std::unique_ptr<gfx::GpuMemoryBuffer> buffer = - gpu::GpuMemoryBufferImplNativePixmap::CreateFromHandle( - native_pixmap_factory_.get(), std::move(handle), size, format, - gfx::BufferUsage::SCANOUT, - base::RepeatingCallback<void(const gpu::SyncToken&)>()); - EXPECT_NE(nullptr, buffer.get()); - EXPECT_TRUE(buffer->GetId().is_valid()); - - // Create the image. This should add the image ID to the ImageManager. - GLuint image_id = glCreateImageCHROMIUM(buffer->AsClientBuffer(), - size.width(), size.height(), GL_RGB); - EXPECT_NE(0u, image_id); - // In the tests the gl::GLImage is added into the ImageManager when calling - // GLManager::CreateImage. In real cases the GpuControl would not own the - // ImageManager. I.e. for the tests the ImageManager lives in the client side - // so there is no need to call glShallowFinishCHROMIUM(). - EXPECT_TRUE(gl_.decoder()->GetImageManagerForTest()->LookupImage(image_id) != - nullptr); - ASSERT_TRUE(glGetError() == GL_NO_ERROR); - - // Need a texture to bind the image. - GLuint texture_id = 0; - glGenTextures(1, &texture_id); - ASSERT_NE(0u, texture_id); - glActiveTexture(GL_TEXTURE0); - glBindTexture(GL_TEXTURE_2D, texture_id); - glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE); - glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE); - glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST); - glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST); - - // Bind the image. - glBindTexImage2DCHROMIUM(GL_TEXTURE_2D, image_id); - - // Build program, buffers and draw the texture. - GLuint vertex_shader = - GLTestHelper::LoadShader(GL_VERTEX_SHADER, kVertexShader); - GLuint fragment_shader = - GLTestHelper::LoadShader(GL_FRAGMENT_SHADER, kFragmentShader); - GLuint program = GLTestHelper::SetupProgram(vertex_shader, fragment_shader); - ASSERT_NE(0u, program); - glUseProgram(program); - - GLint sampler_location = glGetUniformLocation(program, "a_texture"); - ASSERT_NE(-1, sampler_location); - glUniform1i(sampler_location, 0); - - GLuint vbo = - GLTestHelper::SetupUnitQuad(glGetAttribLocation(program, "a_position")); - ASSERT_NE(0u, vbo); - glViewport(0, 0, kImageWidth, kImageHeight); - glDrawArrays(GL_TRIANGLES, 0, 6); - ASSERT_TRUE(glGetError() == GL_NO_ERROR); - - // Check if pixels match the values that were assigned to the mapped buffer. - GLTestHelper::CheckPixels(0, 0, kImageWidth, kImageHeight, 0, pixel, nullptr); - EXPECT_TRUE(GL_NO_ERROR == glGetError()); - - // Release the image. - glReleaseTexImage2DCHROMIUM(GL_TEXTURE_2D, image_id); - - // Clean up. - glDeleteProgram(program); - glDeleteShader(vertex_shader); - glDeleteShader(fragment_shader); - glDeleteBuffers(1, &vbo); - glDestroyImageCHROMIUM(image_id); - glDeleteTextures(1, &texture_id); -} -#endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) - INSTANTIATE_TEST_SUITE_P( GpuMemoryBufferTests, GpuMemoryBufferTest,
diff --git a/gpu/command_buffer/tests/gl_iosurface_readback_workaround_unittest.cc b/gpu/command_buffer/tests/gl_iosurface_readback_workaround_unittest.cc deleted file mode 100644 index 10e3436..0000000 --- a/gpu/command_buffer/tests/gl_iosurface_readback_workaround_unittest.cc +++ /dev/null
@@ -1,85 +0,0 @@ -// Copyright 2016 The Chromium Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#ifndef GL_GLEXT_PROTOTYPES -#define GL_GLEXT_PROTOTYPES -#endif - -#include <GLES2/gl2.h> -#include <GLES2/gl2ext.h> -#include <GLES2/gl2extchromium.h> - -#include "build/build_config.h" -#include "gpu/command_buffer/tests/gl_manager.h" -#include "gpu/command_buffer/tests/gl_test_utils.h" -#include "testing/gtest/include/gtest/gtest.h" - -namespace gpu { - -#if BUILDFLAG(IS_MAC) -// A test that exercises the glReadPixels workaround for IOSurface backed -// textures. -class GLIOSurfaceReadbackWorkaroundTest : public testing::Test { - public: - GLIOSurfaceReadbackWorkaroundTest() {} - - protected: - void SetUp() override { - gl_.Initialize(GLManager::Options()); - gl_.set_use_iosurface_memory_buffers(true); - } - - void TearDown() override { - GLTestHelper::CheckGLError("no errors", __LINE__); - gl_.Destroy(); - } - - GLManager gl_; -}; - -TEST_F(GLIOSurfaceReadbackWorkaroundTest, ReadPixels) { - int width = 1; - int height = 1; - GLuint source_texture = 0; - GLenum source_target = GL_TEXTURE_RECTANGLE_ARB; - glGenTextures(1, &source_texture); - glBindTexture(source_target, source_texture); - glTexParameteri(source_target, GL_TEXTURE_MIN_FILTER, GL_LINEAR); - glTexParameteri(source_target, GL_TEXTURE_MAG_FILTER, GL_LINEAR); - std::unique_ptr<gfx::GpuMemoryBuffer> buffer(gl_.CreateGpuMemoryBuffer( - gfx::Size(width, height), gfx::BufferFormat::RGBA_8888)); - GLuint image_id = - glCreateImageCHROMIUM(buffer->AsClientBuffer(), width, height, GL_RGBA); - ASSERT_NE(0u, image_id); - glBindTexImage2DCHROMIUM(source_target, image_id); - - GLuint framebuffer = 0; - glGenFramebuffers(1, &framebuffer); - glBindFramebuffer(GL_FRAMEBUFFER, framebuffer); - glFramebufferTexture2D( - GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, source_target, source_texture, 0); - EXPECT_EQ(static_cast<GLenum>(GL_FRAMEBUFFER_COMPLETE), - glCheckFramebufferStatus(GL_FRAMEBUFFER)); - - glClearColor(33.0 / 255.0, 44.0 / 255.0, 55.0 / 255.0, 66.0 / 255.0); - glClear(GL_COLOR_BUFFER_BIT); - const uint8_t expected[4] = {33, 44, 55, 66}; - EXPECT_TRUE(GLTestHelper::CheckPixels(0, 0, 1, 1, 1 /* tolerance */, expected, - nullptr)); - - glClearColor(14.0 / 255.0, 15.0 / 255.0, 16.0 / 255.0, 17.0 / 255.0); - glClear(GL_COLOR_BUFFER_BIT); - const uint8_t expected2[4] = {14, 15, 16, 17}; - EXPECT_TRUE(GLTestHelper::CheckPixels(0, 0, 1, 1, 1 /* tolerance */, - expected2, nullptr)); - - glReleaseTexImage2DCHROMIUM(source_target, image_id); - glDestroyImageCHROMIUM(image_id); - glDeleteTextures(1, &source_texture); - glDeleteFramebuffers(1, &framebuffer); -} - -#endif // BUILDFLAG(IS_MAC) - -} // namespace gpu
diff --git a/gpu/ipc/client/gpu_in_process_context_tests.cc b/gpu/ipc/client/gpu_in_process_context_tests.cc index ffa9b1a..c73e92c 100644 --- a/gpu/ipc/client/gpu_in_process_context_tests.cc +++ b/gpu/ipc/client/gpu_in_process_context_tests.cc
@@ -77,38 +77,3 @@ // Include the actual tests. #define CONTEXT_TEST_F TEST_F #include "gpu/ipc/client/gpu_context_tests.h" - -using GLInProcessCommandBufferTest = ContextTestBase; - -TEST_F(GLInProcessCommandBufferTest, CreateImage) { - constexpr gfx::BufferFormat kBufferFormat = gfx::BufferFormat::RGBA_8888; - constexpr gfx::BufferUsage kBufferUsage = gfx::BufferUsage::SCANOUT; - constexpr gfx::Size kBufferSize(100, 100); - - // Calling CreateImageCHROMIUM() should allocate an image id starting at 1. - std::unique_ptr<gfx::GpuMemoryBuffer> gpu_memory_buffer1 = - gpu_memory_buffer_manager_->CreateGpuMemoryBuffer( - kBufferSize, kBufferFormat, kBufferUsage, gpu::kNullSurfaceHandle, - nullptr); - GLuint image_id1 = gl_->CreateImageCHROMIUM( - gpu_memory_buffer1->AsClientBuffer(), kBufferSize.width(), - kBufferSize.height(), GL_RGBA); - - EXPECT_GT(image_id1, 0u); - - // Create a second GLInProcessContext that is backed by a different - // InProcessCommandBuffer. Calling CreateImageCHROMIUM() should return a - // different id than the first call. - std::unique_ptr<gpu::GLInProcessContext> context2 = - CreateGLInProcessContext(); - std::unique_ptr<gfx::GpuMemoryBuffer> buffer2 = - gpu_memory_buffer_manager_->CreateGpuMemoryBuffer( - kBufferSize, kBufferFormat, kBufferUsage, gpu::kNullSurfaceHandle, - nullptr); - GLuint image_id2 = context2->GetImplementation()->CreateImageCHROMIUM( - buffer2->AsClientBuffer(), kBufferSize.width(), kBufferSize.height(), - GL_RGBA); - - EXPECT_GT(image_id2, 0u); - EXPECT_NE(image_id1, image_id2); -}
diff --git a/infra/config/generated/builders/ci/lacros-arm-generic-rel/properties.json b/infra/config/generated/builders/ci/lacros-arm-generic-rel/properties.json index a2dcb4f..20179b4 100644 --- a/infra/config/generated/builders/ci/lacros-arm-generic-rel/properties.json +++ b/infra/config/generated/builders/ci/lacros-arm-generic-rel/properties.json
@@ -1,9 +1,8 @@ { - "$build/goma": { - "enable_ats": true, - "rpc_extra_params": "?prod", - "server_host": "goma.chromium.org", - "use_luci_auth": true + "$build/reclient": { + "instance": "rbe-chromium-trusted", + "jobs": 500, + "metrics_project": "chromium-reclient-metrics" }, "$recipe_engine/resultdb/test_presentation": { "column_keys": [],
diff --git a/infra/config/generated/builders/ci/win-official/properties.json b/infra/config/generated/builders/ci/win-official/properties.json index 1f6cb46..65ac830 100644 --- a/infra/config/generated/builders/ci/win-official/properties.json +++ b/infra/config/generated/builders/ci/win-official/properties.json
@@ -1,4 +1,49 @@ { + "$build/chromium_tests_builder_config": { + "builder_config": { + "builder_db": { + "entries": [ + { + "builder_id": { + "bucket": "ci", + "builder": "win-official", + "project": "chromium" + }, + "builder_spec": { + "builder_group": "chromium", + "execution_mode": "COMPILE_AND_TEST", + "legacy_chromium_config": { + "apply_configs": [ + "mb" + ], + "config": "chromium", + "target_bits": 64 + }, + "legacy_gclient_config": { + "apply_configs": [ + "checkout_pgo_profiles" + ], + "config": "chromium" + } + } + } + ] + }, + "builder_ids": [ + { + "bucket": "ci", + "builder": "win-official", + "project": "chromium" + } + ], + "mirroring_builder_group_and_names": [ + { + "builder": "win-official", + "group": "tryserver.chromium" + } + ] + } + }, "$build/goma": { "enable_ats": true, "rpc_extra_params": "?prod",
diff --git a/infra/config/generated/builders/ci/win32-archive-rel/properties.json b/infra/config/generated/builders/ci/win32-archive-rel/properties.json index 5796433..7351f9160 100644 --- a/infra/config/generated/builders/ci/win32-archive-rel/properties.json +++ b/infra/config/generated/builders/ci/win32-archive-rel/properties.json
@@ -7,6 +7,50 @@ "win32-archive-rel.json" ] }, + "$build/chromium_tests_builder_config": { + "builder_config": { + "builder_db": { + "entries": [ + { + "builder_id": { + "bucket": "ci", + "builder": "win32-archive-rel", + "project": "chromium" + }, + "builder_spec": { + "builder_group": "chromium", + "execution_mode": "COMPILE_AND_TEST", + "legacy_chromium_config": { + "apply_configs": [ + "clobber", + "mb" + ], + "build_config": "Release", + "config": "chromium", + "target_bits": 32 + }, + "legacy_gclient_config": { + "config": "chromium" + } + } + } + ] + }, + "builder_ids": [ + { + "bucket": "ci", + "builder": "win32-archive-rel", + "project": "chromium" + } + ], + "mirroring_builder_group_and_names": [ + { + "builder": "win_archive", + "group": "tryserver.chromium.win" + } + ] + } + }, "$build/reclient": { "instance": "rbe-chromium-trusted", "jobs": 250,
diff --git "a/infra/config/generated/builders/ci/win7\05032\051-updater-tester-dbg/properties.json" "b/infra/config/generated/builders/ci/win7\05032\051-updater-tester-dbg/properties.json" deleted file mode 100644 index 0d6f98c..0000000 --- "a/infra/config/generated/builders/ci/win7\05032\051-updater-tester-dbg/properties.json" +++ /dev/null
@@ -1,11 +0,0 @@ -{ - "$recipe_engine/resultdb/test_presentation": { - "column_keys": [], - "grouping_keys": [ - "status", - "v.test_suite" - ] - }, - "builder_group": "chromium.updater", - "recipe": "chromium" -} \ No newline at end of file
diff --git a/infra/config/generated/builders/ci/win7-updater-tester-dbg-uac/properties.json b/infra/config/generated/builders/ci/win7-updater-tester-dbg-uac/properties.json deleted file mode 100644 index 0d6f98c..0000000 --- a/infra/config/generated/builders/ci/win7-updater-tester-dbg-uac/properties.json +++ /dev/null
@@ -1,11 +0,0 @@ -{ - "$recipe_engine/resultdb/test_presentation": { - "column_keys": [], - "grouping_keys": [ - "status", - "v.test_suite" - ] - }, - "builder_group": "chromium.updater", - "recipe": "chromium" -} \ No newline at end of file
diff --git a/infra/config/generated/builders/try/win-official/properties.json b/infra/config/generated/builders/try/win-official/properties.json index 848decd..b4e5c7a 100644 --- a/infra/config/generated/builders/try/win-official/properties.json +++ b/infra/config/generated/builders/try/win-official/properties.json
@@ -1,4 +1,43 @@ { + "$build/chromium_tests_builder_config": { + "builder_config": { + "builder_db": { + "entries": [ + { + "builder_id": { + "bucket": "ci", + "builder": "win-official", + "project": "chromium" + }, + "builder_spec": { + "builder_group": "chromium", + "execution_mode": "COMPILE_AND_TEST", + "legacy_chromium_config": { + "apply_configs": [ + "mb" + ], + "config": "chromium", + "target_bits": 64 + }, + "legacy_gclient_config": { + "apply_configs": [ + "checkout_pgo_profiles" + ], + "config": "chromium" + } + } + } + ] + }, + "builder_ids": [ + { + "bucket": "ci", + "builder": "win-official", + "project": "chromium" + } + ] + } + }, "$build/goma": { "enable_ats": false, "rpc_extra_params": "?prod",
diff --git a/infra/config/generated/builders/try/win_archive/properties.json b/infra/config/generated/builders/try/win_archive/properties.json index d4fde02b..45e95dc 100644 --- a/infra/config/generated/builders/try/win_archive/properties.json +++ b/infra/config/generated/builders/try/win_archive/properties.json
@@ -1,4 +1,42 @@ { + "$build/chromium_tests_builder_config": { + "builder_config": { + "builder_db": { + "entries": [ + { + "builder_id": { + "bucket": "ci", + "builder": "win32-archive-rel", + "project": "chromium" + }, + "builder_spec": { + "builder_group": "chromium", + "execution_mode": "COMPILE_AND_TEST", + "legacy_chromium_config": { + "apply_configs": [ + "clobber", + "mb" + ], + "build_config": "Release", + "config": "chromium", + "target_bits": 32 + }, + "legacy_gclient_config": { + "config": "chromium" + } + } + } + ] + }, + "builder_ids": [ + { + "bucket": "ci", + "builder": "win32-archive-rel", + "project": "chromium" + } + ] + } + }, "$build/goma": { "enable_ats": false, "rpc_extra_params": "?prod",
diff --git a/infra/config/generated/builders/webrtc.fyi/WebRTC Chromium FYI Win7 Tester/properties.json b/infra/config/generated/builders/webrtc.fyi/WebRTC Chromium FYI Win7 Tester/properties.json deleted file mode 100644 index 7883bfd..0000000 --- a/infra/config/generated/builders/webrtc.fyi/WebRTC Chromium FYI Win7 Tester/properties.json +++ /dev/null
@@ -1,11 +0,0 @@ -{ - "$recipe_engine/resultdb/test_presentation": { - "column_keys": [], - "grouping_keys": [ - "status", - "v.test_suite" - ] - }, - "builder_group": "chromium.webrtc.fyi", - "recipe": "chromium" -} \ No newline at end of file
diff --git a/infra/config/generated/builders/webrtc/WebRTC Chromium Win7 Tester/properties.json b/infra/config/generated/builders/webrtc/WebRTC Chromium Win7 Tester/properties.json deleted file mode 100644 index 2cf90e9..0000000 --- a/infra/config/generated/builders/webrtc/WebRTC Chromium Win7 Tester/properties.json +++ /dev/null
@@ -1,12 +0,0 @@ -{ - "$recipe_engine/resultdb/test_presentation": { - "column_keys": [], - "grouping_keys": [ - "status", - "v.test_suite" - ] - }, - "builder_group": "chromium.webrtc", - "perf_dashboard_machine_group": "ChromiumWebRTC", - "recipe": "chromium" -} \ No newline at end of file
diff --git a/infra/config/generated/luci/cr-buildbucket.cfg b/infra/config/generated/luci/cr-buildbucket.cfg index 77e4c44..2e4631bd 100644 --- a/infra/config/generated/luci/cr-buildbucket.cfg +++ b/infra/config/generated/luci/cr-buildbucket.cfg
@@ -43241,85 +43241,6 @@ } } builders { - name: "win7(32)-updater-tester-dbg" - swarming_host: "chromium-swarm.appspot.com" - dimensions: "builderless:1" - dimensions: "cores:8" - dimensions: "cpu:x86-64" - dimensions: "os:Ubuntu-18.04" - dimensions: "pool:luci.chromium.ci" - dimensions: "ssd:0" - exe { - cipd_package: "infra/chromium/bootstrapper/${platform}" - cipd_version: "latest" - cmd: "bootstrapper" - } - properties: - '{' - ' "$bootstrap/exe": {' - ' "exe": {' - ' "cipd_package": "infra/recipe_bundles/chromium.googlesource.com/chromium/tools/build",' - ' "cipd_version": "refs/heads/main",' - ' "cmd": [' - ' "luciexe"' - ' ]' - ' }' - ' },' - ' "$bootstrap/properties": {' - ' "properties_file": "infra/config/generated/builders/ci/win7(32)-updater-tester-dbg/properties.json",' - ' "top_level_project": {' - ' "ref": "refs/heads/main",' - ' "repo": {' - ' "host": "chromium.googlesource.com",' - ' "project": "chromium/src"' - ' }' - ' }' - ' },' - ' "builder_group": "chromium.updater",' - ' "led_builder_is_bootstrapped": true,' - ' "recipe": "chromium"' - '}' - execution_timeout_secs: 10800 - build_numbers: YES - service_account: "chromium-ci-builder@chops-service-accounts.iam.gserviceaccount.com" - experiments { - key: "luci.recipes.use_python3" - value: 100 - } - resultdb { - enable: true - bq_exports { - project: "chrome-luci-data" - dataset: "chromium" - table: "ci_test_results" - test_results {} - } - bq_exports { - project: "chrome-luci-data" - dataset: "chromium" - table: "gpu_ci_test_results" - test_results { - predicate { - test_id_regexp: "ninja://chrome/test:telemetry_gpu_integration_test[^/]*/.+" - } - } - } - bq_exports { - project: "chrome-luci-data" - dataset: "chromium" - table: "blink_web_tests_ci_test_results" - test_results { - predicate { - test_id_regexp: "ninja://[^/]*blink_web_tests/.+" - } - } - } - history_options { - use_invocation_timestamp: true - } - } - } - builders { name: "win7(32)-updater-tester-rel" swarming_host: "chromium-swarm.appspot.com" dimensions: "builderless:1" @@ -43533,85 +43454,6 @@ } } builders { - name: "win7-updater-tester-dbg-uac" - swarming_host: "chromium-swarm.appspot.com" - dimensions: "builderless:1" - dimensions: "cores:8" - dimensions: "cpu:x86-64" - dimensions: "os:Ubuntu-18.04" - dimensions: "pool:luci.chromium.ci" - dimensions: "ssd:0" - exe { - cipd_package: "infra/chromium/bootstrapper/${platform}" - cipd_version: "latest" - cmd: "bootstrapper" - } - properties: - '{' - ' "$bootstrap/exe": {' - ' "exe": {' - ' "cipd_package": "infra/recipe_bundles/chromium.googlesource.com/chromium/tools/build",' - ' "cipd_version": "refs/heads/main",' - ' "cmd": [' - ' "luciexe"' - ' ]' - ' }' - ' },' - ' "$bootstrap/properties": {' - ' "properties_file": "infra/config/generated/builders/ci/win7-updater-tester-dbg-uac/properties.json",' - ' "top_level_project": {' - ' "ref": "refs/heads/main",' - ' "repo": {' - ' "host": "chromium.googlesource.com",' - ' "project": "chromium/src"' - ' }' - ' }' - ' },' - ' "builder_group": "chromium.updater",' - ' "led_builder_is_bootstrapped": true,' - ' "recipe": "chromium"' - '}' - execution_timeout_secs: 10800 - build_numbers: YES - service_account: "chromium-ci-builder@chops-service-accounts.iam.gserviceaccount.com" - experiments { - key: "luci.recipes.use_python3" - value: 100 - } - resultdb { - enable: true - bq_exports { - project: "chrome-luci-data" - dataset: "chromium" - table: "ci_test_results" - test_results {} - } - bq_exports { - project: "chrome-luci-data" - dataset: "chromium" - table: "gpu_ci_test_results" - test_results { - predicate { - test_id_regexp: "ninja://chrome/test:telemetry_gpu_integration_test[^/]*/.+" - } - } - } - bq_exports { - project: "chrome-luci-data" - dataset: "chromium" - table: "blink_web_tests_ci_test_results" - test_results { - predicate { - test_id_regexp: "ninja://[^/]*blink_web_tests/.+" - } - } - } - history_options { - use_invocation_timestamp: true - } - } - } - builders { name: "win7-updater-tester-rel" swarming_host: "chromium-swarm.appspot.com" dimensions: "builderless:1" @@ -79194,53 +79036,6 @@ enable: true } } - builders { - name: "WebRTC Chromium Win7 Tester" - swarming_host: "chromium-swarm.appspot.com" - dimensions: "builder:WebRTC Chromium Win7 Tester" - dimensions: "cpu:x86-64" - dimensions: "os:Windows" - exe { - cipd_package: "infra/chromium/bootstrapper/${platform}" - cipd_version: "latest" - cmd: "bootstrapper" - } - properties: - '{' - ' "$bootstrap/exe": {' - ' "exe": {' - ' "cipd_package": "infra/recipe_bundles/chromium.googlesource.com/chromium/tools/build",' - ' "cipd_version": "refs/heads/main",' - ' "cmd": [' - ' "luciexe"' - ' ]' - ' }' - ' },' - ' "$bootstrap/properties": {' - ' "properties_file": "infra/config/generated/builders/webrtc/WebRTC Chromium Win7 Tester/properties.json",' - ' "top_level_project": {' - ' "ref": "refs/heads/main",' - ' "repo": {' - ' "host": "chromium.googlesource.com",' - ' "project": "chromium/src"' - ' }' - ' }' - ' },' - ' "builder_group": "chromium.webrtc",' - ' "led_builder_is_bootstrapped": true,' - ' "recipe": "chromium"' - '}' - execution_timeout_secs: 7200 - build_numbers: YES - service_account: "chromium-ci-builder@chops-service-accounts.iam.gserviceaccount.com" - experiments { - key: "luci.recipes.use_python3" - value: 100 - } - resultdb { - enable: true - } - } } } buckets { @@ -79916,53 +79711,6 @@ } } builders { - name: "WebRTC Chromium FYI Win7 Tester" - swarming_host: "chromium-swarm.appspot.com" - dimensions: "cpu:x86-64" - dimensions: "os:Windows-10" - dimensions: "pool:luci.chromium.webrtc.fyi" - exe { - cipd_package: "infra/chromium/bootstrapper/${platform}" - cipd_version: "latest" - cmd: "bootstrapper" - } - properties: - '{' - ' "$bootstrap/exe": {' - ' "exe": {' - ' "cipd_package": "infra/recipe_bundles/chromium.googlesource.com/chromium/tools/build",' - ' "cipd_version": "refs/heads/main",' - ' "cmd": [' - ' "luciexe"' - ' ]' - ' }' - ' },' - ' "$bootstrap/properties": {' - ' "properties_file": "infra/config/generated/builders/webrtc.fyi/WebRTC Chromium FYI Win7 Tester/properties.json",' - ' "top_level_project": {' - ' "ref": "refs/heads/main",' - ' "repo": {' - ' "host": "chromium.googlesource.com",' - ' "project": "chromium/src"' - ' }' - ' }' - ' },' - ' "builder_group": "chromium.webrtc.fyi",' - ' "led_builder_is_bootstrapped": true,' - ' "recipe": "chromium"' - '}' - execution_timeout_secs: 7200 - build_numbers: YES - service_account: "chromium-ci-builder@chops-service-accounts.iam.gserviceaccount.com" - experiments { - key: "luci.recipes.use_python3" - value: 100 - } - resultdb { - enable: true - } - } - builders { name: "WebRTC Chromium FYI ios-device" swarming_host: "chromium-swarm.appspot.com" dimensions: "cpu:x86-64"
diff --git a/infra/config/generated/luci/luci-milo.cfg b/infra/config/generated/luci/luci-milo.cfg index 2bd0391..abe35f7 100644 --- a/infra/config/generated/luci/luci-milo.cfg +++ b/infra/config/generated/luci/luci-milo.cfg
@@ -12001,11 +12001,6 @@ short_name: "bld" } builders { - name: "buildbucket/luci.chromium.ci/win7(32)-updater-tester-dbg" - category: "debug|win (32)" - short_name: "7" - } - builders { name: "buildbucket/luci.chromium.ci/win32-updater-builder-dbg" category: "debug|win (32)" short_name: "bld" @@ -12021,11 +12016,6 @@ short_name: "UAC10" } builders { - name: "buildbucket/luci.chromium.ci/win7-updater-tester-dbg-uac" - category: "debug|win (64)" - short_name: "UAC7" - } - builders { name: "buildbucket/luci.chromium.ci/win-updater-builder-dbg" category: "debug|win (64)" short_name: "bld" @@ -12469,11 +12459,6 @@ category: "win" short_name: "10" } - builders { - name: "buildbucket/luci.chromium.webrtc/WebRTC Chromium Win7 Tester" - category: "win" - short_name: "7" - } header { oncalls { name: "Chromium" @@ -12855,11 +12840,6 @@ short_name: "10" } builders { - name: "buildbucket/luci.chromium.webrtc.fyi/WebRTC Chromium FYI Win7 Tester" - category: "win|release|tester" - short_name: "7" - } - builders { name: "buildbucket/luci.chromium.webrtc.fyi/WebRTC Chromium FYI ios-device" category: "ios" short_name: "dev"
diff --git a/infra/config/generated/luci/luci-scheduler.cfg b/infra/config/generated/luci/luci-scheduler.cfg index fb0820f..0b542e2 100644 --- a/infra/config/generated/luci/luci-scheduler.cfg +++ b/infra/config/generated/luci/luci-scheduler.cfg
@@ -3315,20 +3315,6 @@ } } job { - id: "WebRTC Chromium FYI Win7 Tester" - realm: "webrtc.fyi" - acls { - role: TRIGGERER - granted_to: "chromium-ci-builder@chops-service-accounts.iam.gserviceaccount.com" - } - acl_sets: "webrtc.fyi" - buildbucket { - server: "cr-buildbucket.appspot.com" - bucket: "webrtc.fyi" - builder: "WebRTC Chromium FYI Win7 Tester" - } -} -job { id: "WebRTC Chromium FYI ios-device" realm: "webrtc.fyi" acl_sets: "webrtc.fyi" @@ -3421,20 +3407,6 @@ } } job { - id: "WebRTC Chromium Win7 Tester" - realm: "webrtc" - acls { - role: TRIGGERER - granted_to: "chromium-ci-builder@chops-service-accounts.iam.gserviceaccount.com" - } - acl_sets: "webrtc" - buildbucket { - server: "cr-buildbucket.appspot.com" - bucket: "webrtc" - builder: "WebRTC Chromium Win7 Tester" - } -} -job { id: "Win 10 Fast Ring" realm: "ci" acl_sets: "ci" @@ -7058,20 +7030,6 @@ } } job { - id: "win7(32)-updater-tester-dbg" - realm: "ci" - acls { - role: TRIGGERER - granted_to: "chromium-ci-builder@chops-service-accounts.iam.gserviceaccount.com" - } - acl_sets: "ci" - buildbucket { - server: "cr-buildbucket.appspot.com" - bucket: "ci" - builder: "win7(32)-updater-tester-dbg" - } -} -job { id: "win7(32)-updater-tester-rel" realm: "ci" acls { @@ -7114,20 +7072,6 @@ } } job { - id: "win7-updater-tester-dbg-uac" - realm: "ci" - acls { - role: TRIGGERER - granted_to: "chromium-ci-builder@chops-service-accounts.iam.gserviceaccount.com" - } - acl_sets: "ci" - buildbucket { - server: "cr-buildbucket.appspot.com" - bucket: "ci" - builder: "win7-updater-tester-dbg-uac" - } -} -job { id: "win7-updater-tester-rel" realm: "ci" acls {
diff --git a/infra/config/generated/luci/realms.cfg b/infra/config/generated/luci/realms.cfg index 7a7ba69..7ea4318 100644 --- a/infra/config/generated/luci/realms.cfg +++ b/infra/config/generated/luci/realms.cfg
@@ -174,9 +174,7 @@ values: "win10-updater-tester-dbg" values: "win10-updater-tester-dbg-uac" values: "win10-updater-tester-rel" - values: "win7(32)-updater-tester-dbg" values: "win7(32)-updater-tester-rel" - values: "win7-updater-tester-dbg-uac" values: "win7-updater-tester-rel" } } @@ -543,7 +541,6 @@ values: "WebRTC Chromium Linux Tester" values: "WebRTC Chromium Mac Tester" values: "WebRTC Chromium Win10 Tester" - values: "WebRTC Chromium Win7 Tester" } } } @@ -585,7 +582,6 @@ values: "WebRTC Chromium FYI Linux Tester" values: "WebRTC Chromium FYI Mac Tester" values: "WebRTC Chromium FYI Win10 Tester" - values: "WebRTC Chromium FYI Win7 Tester" } } }
diff --git a/infra/config/subprojects/chromium/ci/chromium.chromiumos.star b/infra/config/subprojects/chromium/ci/chromium.chromiumos.star index f41e312a..c044e73 100644 --- a/infra/config/subprojects/chromium/ci/chromium.chromiumos.star +++ b/infra/config/subprojects/chromium/ci/chromium.chromiumos.star
@@ -582,6 +582,9 @@ tree_closing = False, cq_mirrors_console_view = "mirrors", main_console_view = "main", + goma_backend = None, + reclient_jobs = rbe_jobs.HIGH_JOBS_FOR_CI, + reclient_instance = rbe_instance.DEFAULT, ) ci.builder(
diff --git a/infra/config/subprojects/chromium/ci/chromium.star b/infra/config/subprojects/chromium/ci/chromium.star index 7e733f0..6f6de85 100644 --- a/infra/config/subprojects/chromium/ci/chromium.star +++ b/infra/config/subprojects/chromium/ci/chromium.star
@@ -494,6 +494,21 @@ ci.builder( name = "win-official", branch_selector = branches.DESKTOP_EXTENDED_STABLE_MILESTONE, + builder_spec = builder_config.builder_spec( + gclient_config = builder_config.gclient_config( + config = "chromium", + apply_configs = [ + "checkout_pgo_profiles", + ], + ), + chromium_config = builder_config.chromium_config( + config = "chromium", + apply_configs = [ + "mb", + ], + target_bits = 64, + ), + ), console_view_entry = consoles.console_view_entry( category = "win|off", short_name = "64", @@ -520,6 +535,20 @@ ci.builder( name = "win32-archive-rel", + builder_spec = builder_config.builder_spec( + gclient_config = builder_config.gclient_config( + config = "chromium", + ), + chromium_config = builder_config.chromium_config( + config = "chromium", + apply_configs = [ + "clobber", + "mb", + ], + build_config = builder_config.build_config.RELEASE, + target_bits = 32, + ), + ), console_view_entry = consoles.console_view_entry( category = "win|rel", short_name = "32",
diff --git a/infra/config/subprojects/chromium/ci/chromium.updater.star b/infra/config/subprojects/chromium/ci/chromium.updater.star index 522bf9b..29ef64b 100644 --- a/infra/config/subprojects/chromium/ci/chromium.updater.star +++ b/infra/config/subprojects/chromium/ci/chromium.updater.star
@@ -238,24 +238,6 @@ ) ci.thin_tester( - name = "win7-updater-tester-dbg-uac", - console_view_entry = consoles.console_view_entry( - category = "debug|win (64)", - short_name = "UAC7", - ), - triggered_by = ["win-updater-builder-dbg"], -) - -ci.thin_tester( - name = "win7(32)-updater-tester-dbg", - console_view_entry = consoles.console_view_entry( - category = "debug|win (32)", - short_name = "7", - ), - triggered_by = ["win32-updater-builder-dbg"], -) - -ci.thin_tester( name = "win7-updater-tester-rel", console_view_entry = consoles.console_view_entry( category = "release|win (64)",
diff --git a/infra/config/subprojects/chromium/try/tryserver.chromium.star b/infra/config/subprojects/chromium/try/tryserver.chromium.star index 9e7038b..b09215e 100644 --- a/infra/config/subprojects/chromium/try/tryserver.chromium.star +++ b/infra/config/subprojects/chromium/try/tryserver.chromium.star
@@ -56,6 +56,9 @@ try_.builder( name = "win-official", branch_selector = branches.DESKTOP_EXTENDED_STABLE_MILESTONE, + mirrors = [ + "ci/win-official", + ], os = os.WINDOWS_DEFAULT, execution_timeout = 6 * time.hour, )
diff --git a/infra/config/subprojects/chromium/try/tryserver.chromium.win.star b/infra/config/subprojects/chromium/try/tryserver.chromium.win.star index 263044c..ae7898c7 100644 --- a/infra/config/subprojects/chromium/try/tryserver.chromium.win.star +++ b/infra/config/subprojects/chromium/try/tryserver.chromium.win.star
@@ -68,6 +68,9 @@ try_.builder( name = "win_archive", + mirrors = [ + "ci/win32-archive-rel", + ], ) try_.builder(
diff --git a/infra/config/subprojects/webrtc/consoles/chromium.webrtc.fyi.star b/infra/config/subprojects/webrtc/consoles/chromium.webrtc.fyi.star index c4eb6a32..7b4c001a 100644 --- a/infra/config/subprojects/webrtc/consoles/chromium.webrtc.fyi.star +++ b/infra/config/subprojects/webrtc/consoles/chromium.webrtc.fyi.star
@@ -81,11 +81,6 @@ short_name = "10", ), luci.console_view_entry( - builder = "webrtc.fyi/WebRTC Chromium FYI Win7 Tester", - category = "win|release|tester", - short_name = "7", - ), - luci.console_view_entry( builder = "webrtc.fyi/WebRTC Chromium FYI ios-device", category = "ios", short_name = "dev",
diff --git a/infra/config/subprojects/webrtc/consoles/chromium.webrtc.star b/infra/config/subprojects/webrtc/consoles/chromium.webrtc.star index 892032ef4..41c0419 100644 --- a/infra/config/subprojects/webrtc/consoles/chromium.webrtc.star +++ b/infra/config/subprojects/webrtc/consoles/chromium.webrtc.star
@@ -49,10 +49,5 @@ category = "win", short_name = "10", ), - luci.console_view_entry( - builder = "webrtc/WebRTC Chromium Win7 Tester", - category = "win", - short_name = "7", - ), ], )
diff --git a/infra/config/subprojects/webrtc/webrtc.fyi.star b/infra/config/subprojects/webrtc/webrtc.fyi.star index b9f23b5..d988405 100644 --- a/infra/config/subprojects/webrtc/webrtc.fyi.star +++ b/infra/config/subprojects/webrtc/webrtc.fyi.star
@@ -130,12 +130,6 @@ # to swarming bots with appropriate OS using swarming # dimensions. builder( - name = "WebRTC Chromium FYI Win7 Tester", - os = os.WINDOWS_DEFAULT, - triggered_by = ["WebRTC Chromium FYI Win Builder"], -) - -builder( name = "WebRTC Chromium FYI ios-device", goma_backend = goma.backend.RBE_PROD, os = os.MAC_ANY,
diff --git a/infra/config/subprojects/webrtc/webrtc.star b/infra/config/subprojects/webrtc/webrtc.star index d264b34..3fe908f 100644 --- a/infra/config/subprojects/webrtc/webrtc.star +++ b/infra/config/subprojects/webrtc/webrtc.star
@@ -87,9 +87,3 @@ os = os.WINDOWS_ANY, triggered_by = ["WebRTC Chromium Win Builder"], ) - -builder( - name = "WebRTC Chromium Win7 Tester", - os = os.WINDOWS_ANY, - triggered_by = ["WebRTC Chromium Win Builder"], -)
diff --git a/ios/chrome/browser/https_upgrades/https_only_mode_upgrade_tab_helper.h b/ios/chrome/browser/https_upgrades/https_only_mode_upgrade_tab_helper.h index 88e9525..43205ac 100644 --- a/ios/chrome/browser/https_upgrades/https_only_mode_upgrade_tab_helper.h +++ b/ios/chrome/browser/https_upgrades/https_only_mode_upgrade_tab_helper.h
@@ -55,6 +55,8 @@ void UseFakeHTTPSForTesting(bool use_fake_https_for_testing); // Sets the fallback delay for tests. void SetFallbackDelayForTesting(base::TimeDelta delay); + // Returns true if the upgrade timer is running. + bool IsTimerRunningForTesting() const; private: explicit HttpsOnlyModeUpgradeTabHelper(web::WebState* web_state,
diff --git a/ios/chrome/browser/https_upgrades/https_only_mode_upgrade_tab_helper.mm b/ios/chrome/browser/https_upgrades/https_only_mode_upgrade_tab_helper.mm index 3ac1bd97..239327e 100644 --- a/ios/chrome/browser/https_upgrades/https_only_mode_upgrade_tab_helper.mm +++ b/ios/chrome/browser/https_upgrades/https_only_mode_upgrade_tab_helper.mm
@@ -95,6 +95,10 @@ fallback_delay_ = delay; } +bool HttpsOnlyModeUpgradeTabHelper::IsTimerRunningForTesting() const { + return timer_.IsRunning(); +} + bool HttpsOnlyModeUpgradeTabHelper::IsFakeHTTPSForTesting( const GURL& url) const { return url.IntPort() == https_port_for_testing_; @@ -251,6 +255,10 @@ web::WebStatePolicyDecider::PolicyDecision::Allow()); return; } + // This is a fallback navigation, no need to keep the slow upgrade timer + // running. + timer_.Stop(); + // If the URL is in the allowlist, don't show any warning. This can happen // if another tab allowlists the host before we initiate the fallback // navigation. @@ -332,11 +340,13 @@ // ShouldAllowRequest(), but we don't have enough information there to ensure // whether the HTTP URL is part of the redirect chain or a completely new // navigation. - // This is divergence from the desktop implementation of this feature which + // This is a divergence from the desktop implementation of this feature which // relies on a redirect loop triggering a net error. RecordUMA(Event::kUpgradeFailed); DCHECK(was_upgraded_); + DCHECK(timer_.IsRunning()); was_upgraded_ = false; + timer_.Stop(); HttpsOnlyModeContainer* container = HttpsOnlyModeContainer::FromWebState(web_state()); container->SetHttpUrl(url);
diff --git a/ios/chrome/browser/web/https_only_mode_app_interface.h b/ios/chrome/browser/web/https_only_mode_app_interface.h index 8b1632b..bc2ef0b 100644 --- a/ios/chrome/browser/web/https_only_mode_app_interface.h +++ b/ios/chrome/browser/web/https_only_mode_app_interface.h
@@ -14,6 +14,7 @@ + (void)setHTTPPortForTesting:(int)HTTPPortForTesting; + (void)useFakeHTTPSForTesting:(bool)useFakeHTTPSForTesting; + (void)setFallbackDelayForTesting:(int)fallbackDelayInMilliseconds; ++ (BOOL)isTimerRunning; @end
diff --git a/ios/chrome/browser/web/https_only_mode_app_interface.mm b/ios/chrome/browser/web/https_only_mode_app_interface.mm index 21879c1..c9c8840 100644 --- a/ios/chrome/browser/web/https_only_mode_app_interface.mm +++ b/ios/chrome/browser/web/https_only_mode_app_interface.mm
@@ -41,4 +41,10 @@ base::Milliseconds(fallbackDelayInMilliseconds)); } ++ (BOOL)isTimerRunning { + web::WebState* web_state = chrome_test_util::GetCurrentWebState(); + return HttpsOnlyModeUpgradeTabHelper::FromWebState(web_state) + ->IsTimerRunningForTesting(); +} + @end
diff --git a/ios/chrome/browser/web/https_only_mode_egtest.mm b/ios/chrome/browser/web/https_only_mode_egtest.mm index 85ed975..8923b2af 100644 --- a/ios/chrome/browser/web/https_only_mode_egtest.mm +++ b/ios/chrome/browser/web/https_only_mode_egtest.mm
@@ -213,6 +213,9 @@ forHistogram:@(security_interstitials::https_only_mode:: kEventHistogram)], @"Failed to record upgrade attempt"); + + GREYAssert(![HttpsOnlyModeAppInterface isTimerRunning], + @"Timer is still running"); } // Asserts that the metrics are properly recorded for a failed upgrade. @@ -240,6 +243,8 @@ forHistogram:@(security_interstitials::https_only_mode:: kEventHistogram)], @"Failed to record fail event"); + GREYAssert(![HttpsOnlyModeAppInterface isTimerRunning], + @"Timer is still running"); } // Asserts that the metrics are properly recorded for a timed-out upgrade. @@ -267,6 +272,8 @@ forHistogram:@(security_interstitials::https_only_mode:: kEventHistogram)], @"Failed to record fail event"); + GREYAssert(![HttpsOnlyModeAppInterface isTimerRunning], + @"Timer is still running"); } #pragma mark - Tests @@ -290,6 +297,8 @@ forHistogram:@(security_interstitials::https_only_mode:: kEventHistogram)], @"Shouldn't record event histogram"); + GREYAssert(![HttpsOnlyModeAppInterface isTimerRunning], + @"Timer is still running"); } // Navigate to an HTTP URL directly. The upgraded HTTPS version serves good SSL. @@ -356,6 +365,8 @@ // Click through the interstitial. This should load the HTTP page. [ChromeEarlGrey tapWebStateElementWithID:@"proceed-button"]; [ChromeEarlGrey waitForWebStateContainingText:"HTTP_RESPONSE"]; + GREYAssert(![HttpsOnlyModeAppInterface isTimerRunning], + @"Timer is still running"); // Going back should go to chrome://version. [ChromeEarlGrey goBack]; @@ -383,6 +394,8 @@ // Click through the interstitial. This should load the HTTP page. [ChromeEarlGrey tapWebStateElementWithID:@"proceed-button"]; [ChromeEarlGrey waitForWebStateContainingText:"HTTP_RESPONSE"]; + GREYAssert(![HttpsOnlyModeAppInterface isTimerRunning], + @"Timer is still running"); // Reload. Since the URL is now allowlisted, this should immediately load // HTTP without trying to upgrade. @@ -393,6 +406,8 @@ forHistogram:@(security_interstitials::https_only_mode:: kEventHistogram)], @"Unexpected histogram event recorded."); + GREYAssert(![HttpsOnlyModeAppInterface isTimerRunning], + @"Timer is still running"); } // Same as testUpgrade_BadHTTPS_ProceedInterstitial_Allowlisted but uses @@ -420,6 +435,8 @@ // Click through the interstitial. This should load the HTTP page. [ChromeEarlGrey tapWebStateElementWithID:@"proceed-button"]; [ChromeEarlGrey waitForWebStateContainingText:"HTTP_RESPONSE"]; + GREYAssert(![HttpsOnlyModeAppInterface isTimerRunning], + @"Timer is still running"); // Reload. Since the URL is now allowlisted, this should immediately load // HTTP without trying to upgrade. @@ -430,6 +447,8 @@ forHistogram:@(security_interstitials::https_only_mode:: kEventHistogram)], @"Unexpected histogram event recorded."); + GREYAssert(![HttpsOnlyModeAppInterface isTimerRunning], + @"Timer is still running"); } // Navigate to an HTTP URL directly. The upgraded HTTPS version serves bad SSL. @@ -563,6 +582,8 @@ // Click through the interstitial. This should load the HTTP page. [ChromeEarlGrey tapWebStateElementWithID:@"proceed-button"]; [ChromeEarlGrey waitForWebStateContainingText:"HTTP_RESPONSE"]; + GREYAssert(![HttpsOnlyModeAppInterface isTimerRunning], + @"Timer is still running"); // Go to a new page. [ChromeEarlGrey loadURL:GURL("chrome://version")];
diff --git a/ios/web_view/BUILD.gn b/ios/web_view/BUILD.gn index 87c0cc4..441665b 100644 --- a/ios/web_view/BUILD.gn +++ b/ios/web_view/BUILD.gn
@@ -190,6 +190,8 @@ "internal/passwords/web_view_password_reuse_manager_factory.mm", "internal/passwords/web_view_password_store_factory.h", "internal/passwords/web_view_password_store_factory.mm", + "internal/safe_browsing/cwv_unsafe_url_handler.mm", + "internal/safe_browsing/cwv_unsafe_url_handler_internal.h", "internal/safe_browsing/web_view_safe_browsing_client.h", "internal/safe_browsing/web_view_safe_browsing_client.mm", "internal/safe_browsing/web_view_safe_browsing_client_factory.h", @@ -313,6 +315,8 @@ "//components/profile_metrics", "//components/proxy_config", "//components/safe_browsing/core/common:safe_browsing_prefs", + "//components/safe_browsing/ios/browser:allow_list", + "//components/security_interstitials/core:unsafe_resource", "//components/security_state/ios", "//components/services/patch:in_process", "//components/services/unzip:in_process", @@ -344,6 +348,7 @@ "//ios/components/io_thread", "//ios/components/security_interstitials/lookalikes", "//ios/components/security_interstitials/safe_browsing", + "//ios/components/security_interstitials/safe_browsing:util", "//ios/components/webui:provider", "//ios/components/webui:url_constants", "//ios/components/webui/sync_internals", @@ -469,6 +474,7 @@ "internal/passwords/cwv_credential_provider_extension_utils_unittest.mm", "internal/passwords/cwv_password_unittest.mm", "internal/passwords/web_view_password_manager_client_unittest.mm", + "internal/safe_browsing/cwv_unsafe_url_handler_unittest.mm", "internal/signin/cwv_identity_unittest.mm", "internal/signin/web_view_device_accounts_provider_impl_unittest.mm", "internal/signin/web_view_gaia_auth_fetcher_unittest.mm",
diff --git a/ios/web_view/internal/DEPS b/ios/web_view/internal/DEPS index 6d95045..3d26b42b 100644 --- a/ios/web_view/internal/DEPS +++ b/ios/web_view/internal/DEPS
@@ -27,6 +27,8 @@ "+components/prefs", "+components/proxy_config", "+components/safe_browsing/core/common", + "+components/safe_browsing/ios", + "+components/security_interstitials/core", "+components/security_state/ios", "+components/signin/core/browser", "+components/signin/ios",
diff --git a/ios/web_view/internal/safe_browsing/cwv_unsafe_url_handler.mm b/ios/web_view/internal/safe_browsing/cwv_unsafe_url_handler.mm new file mode 100644 index 0000000..7ec24e14 --- /dev/null +++ b/ios/web_view/internal/safe_browsing/cwv_unsafe_url_handler.mm
@@ -0,0 +1,103 @@ +// Copyright 2022 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#import "ios/web_view/internal/safe_browsing/cwv_unsafe_url_handler_internal.h" + +#import "base/callback.h" +#import "base/memory/weak_ptr.h" +#import "base/notreached.h" +#import "components/safe_browsing/ios/browser/safe_browsing_url_allow_list.h" +#import "components/security_interstitials/core/unsafe_resource.h" +#import "ios/components/security_interstitials/safe_browsing/unsafe_resource_util.h" +#import "ios/web/public/navigation/navigation_manager.h" +#import "ios/web/public/web_state.h" +#import "net/base/mac/url_conversions.h" + +#if !defined(__has_feature) || !__has_feature(objc_arc) +#error "This file requires ARC support." +#endif + +CWVUnsafeURLThreatType CWVUnsafeURLThreatTypeFromSBThreatType( + safe_browsing::SBThreatType threatType) { + switch (threatType) { + case safe_browsing::SB_THREAT_TYPE_BILLING: + return CWVUnsafeURLThreatTypeBilling; + case safe_browsing::SB_THREAT_TYPE_URL_MALWARE: + return CWVUnsafeURLThreatTypeMalware; + case safe_browsing::SB_THREAT_TYPE_URL_UNWANTED: + return CWVUnsafeURLThreatTypeUnwanted; + case safe_browsing::SB_THREAT_TYPE_URL_PHISHING: + return CWVUnsafeURLThreatTypePhishing; + default: + NOTREACHED() << "Update CWVUnsafeURLThreatType for new threat type."; + return CWVUnsafeURLThreatTypeUnknown; + } +} + +@implementation CWVUnsafeURLHandler { + base::WeakPtr<web::WebState> _webState; + security_interstitials::UnsafeResource _unsafeResource; + base::OnceCallback<void(NSString*)> _htmlCallback; + GURL _decisionURL; +} + +- (instancetype)initWithWebState:(web::WebState*)webState + unsafeResource:(const security_interstitials::UnsafeResource&) + unsafeResource + htmlCallback: + (base::OnceCallback<void(NSString*)>)htmlCallback { + self = [super init]; + if (self) { + _webState = webState->GetWeakPtr(); + _unsafeResource = unsafeResource; + _htmlCallback = std::move(htmlCallback); + + _decisionURL = SafeBrowsingUrlAllowList::GetDecisionUrl(_unsafeResource); + } + return self; +} + +- (void)dealloc { + if (_webState) { + SafeBrowsingUrlAllowList::FromWebState(_webState.get()) + ->RemovePendingUnsafeNavigationDecisions(_decisionURL); + } +} + +- (NSURL*)mainFrameURL { + return net::NSURLWithGURL(GetMainFrameUrl(_unsafeResource)); +} + +- (NSURL*)requestURL { + return net::NSURLWithGURL(_unsafeResource.url); +} + +- (CWVUnsafeURLThreatType)threatType { + return CWVUnsafeURLThreatTypeFromSBThreatType(_unsafeResource.threat_type); +} + +- (void)displayInterstitialPageWithHTML:(NSString*)HTML { + if (_htmlCallback) { + std::move(_htmlCallback).Run(HTML); + } +} + +- (void)proceed { + SafeBrowsingUrlAllowList::FromWebState(_webState.get()) + ->AllowUnsafeNavigations(_decisionURL, _unsafeResource.threat_type); + _webState->GetNavigationManager()->Reload(web::ReloadType::NORMAL, + /*check_for_repost=*/true); +} + +- (void)goBack { + SafeBrowsingUrlAllowList::FromWebState(_webState.get()) + ->RemovePendingUnsafeNavigationDecisions(_decisionURL); + if (_webState->GetNavigationManager()->CanGoBack()) { + _webState->GetNavigationManager()->GoBack(); + } else { + _webState->CloseWebState(); + } +} + +@end
diff --git a/ios/web_view/internal/safe_browsing/cwv_unsafe_url_handler_internal.h b/ios/web_view/internal/safe_browsing/cwv_unsafe_url_handler_internal.h new file mode 100644 index 0000000..d7591ab --- /dev/null +++ b/ios/web_view/internal/safe_browsing/cwv_unsafe_url_handler_internal.h
@@ -0,0 +1,24 @@ +// Copyright 2022 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#ifndef IOS_WEB_VIEW_INTERNAL_SAFE_BROWSING_CWV_UNSAFE_URL_HANDLER_INTERNAL_H_ +#define IOS_WEB_VIEW_INTERNAL_SAFE_BROWSING_CWV_UNSAFE_URL_HANDLER_INTERNAL_H_ + +#import "base/callback.h" +#import "components/security_interstitials/core/unsafe_resource.h" +#import "ios/web/public/web_state.h" +#import "ios/web_view/public/cwv_unsafe_url_handler.h" + +@interface CWVUnsafeURLHandler () + +- (instancetype)initWithWebState:(web::WebState*)webState + unsafeResource:(const security_interstitials::UnsafeResource&) + unsafeResource + htmlCallback: + (base::OnceCallback<void(NSString*)>)htmlCallback + NS_DESIGNATED_INITIALIZER; + +@end + +#endif // IOS_WEB_VIEW_INTERNAL_SAFE_BROWSING_CWV_UNSAFE_URL_HANDLER_INTERNAL_H_
diff --git a/ios/web_view/internal/safe_browsing/cwv_unsafe_url_handler_unittest.mm b/ios/web_view/internal/safe_browsing/cwv_unsafe_url_handler_unittest.mm new file mode 100644 index 0000000..5d3e55e --- /dev/null +++ b/ios/web_view/internal/safe_browsing/cwv_unsafe_url_handler_unittest.mm
@@ -0,0 +1,194 @@ +// Copyright 2022 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +#import "ios/web_view/internal/safe_browsing/cwv_unsafe_url_handler_internal.h" + +#import "base/bind.h" +#import "base/callback.h" +#import "base/callback_helpers.h" +#import "components/safe_browsing/ios/browser/safe_browsing_url_allow_list.h" +#import "components/security_interstitials/core/unsafe_resource.h" +#import "ios/web/public/test/fakes/fake_navigation_manager.h" +#import "ios/web/public/test/fakes/fake_web_state.h" +#import "net/base/mac/url_conversions.h" +#import "services/network/public/mojom/fetch_api.mojom.h" +#import "testing/gtest/include/gtest/gtest.h" +#import "testing/gtest_mac.h" +#import "testing/platform_test.h" + +#if !defined(__has_feature) || !__has_feature(objc_arc) +#error "This file requires ARC support." +#endif + +namespace ios_web_view { + +class CWVUnsafeURLHandlerTest : public PlatformTest { + public: + CWVUnsafeURLHandlerTest(const CWVUnsafeURLHandlerTest&) = delete; + CWVUnsafeURLHandlerTest& operator=(const CWVUnsafeURLHandlerTest&) = delete; + + protected: + CWVUnsafeURLHandlerTest() { + auto navigation_manager = std::make_unique<web::FakeNavigationManager>(); + web_state_.SetNavigationManager(std::move(navigation_manager)); + + SafeBrowsingUrlAllowList::CreateForWebState(&web_state_); + } + + CWVUnsafeURLHandler* CreateHandler( + const GURL& main_frame_url, + const GURL& request_url, + safe_browsing::SBThreatType threat_type, + base::OnceCallback<void(NSString*)> callback) { + security_interstitials::UnsafeResource unsafe_resource; + if (main_frame_url == request_url) { + unsafe_resource.url = main_frame_url; + unsafe_resource.request_destination = + network::mojom::RequestDestination::kDocument; + } else { + unsafe_resource.url = request_url; + unsafe_resource.request_destination = + network::mojom::RequestDestination::kIframe; + web_state_.SetCurrentURL(main_frame_url); + } + unsafe_resource.threat_type = threat_type; + unsafe_resource.weak_web_state = web_state_.GetWeakPtr(); + return [[CWVUnsafeURLHandler alloc] initWithWebState:&web_state_ + unsafeResource:unsafe_resource + htmlCallback:std::move(callback)]; + } + + web::FakeNavigationManager* GetNavigationManager() { + return static_cast<web::FakeNavigationManager*>( + web_state_.GetNavigationManager()); + } + + web::FakeWebState web_state_; +}; + +// Checks that public API agrees with the internal UnsafeResource for unsafe +// mainframe loads. +TEST_F(CWVUnsafeURLHandlerTest, InitializationForUnsafeMainframe) { + auto main_frame_url = GURL("https://www.chromium.org"); + auto request_url = GURL("https://www.chromium.org"); + CWVUnsafeURLHandler* handler = CreateHandler( + main_frame_url, request_url, + safe_browsing::SBThreatType::SB_THREAT_TYPE_BILLING, base::DoNothing()); + EXPECT_EQ(main_frame_url, net::GURLWithNSURL(handler.mainFrameURL)); + EXPECT_EQ(request_url, net::GURLWithNSURL(handler.requestURL)); + EXPECT_EQ(CWVUnsafeURLThreatTypeBilling, handler.threatType); +} + +// Checks that public API agrees with the internal UnsafeResource for unsafe +// subframe loads. +TEST_F(CWVUnsafeURLHandlerTest, InitializationForUnsafeSubframe) { + auto main_frame_url = GURL("https://www.chromium.org"); + auto request_url = GURL("https://www.chromium.org/other"); + CWVUnsafeURLHandler* handler = + CreateHandler(main_frame_url, request_url, + safe_browsing::SBThreatType::SB_THREAT_TYPE_URL_PHISHING, + base::DoNothing()); + EXPECT_EQ(main_frame_url, net::GURLWithNSURL(handler.mainFrameURL)); + EXPECT_EQ(request_url, net::GURLWithNSURL(handler.requestURL)); + EXPECT_EQ(CWVUnsafeURLThreatTypePhishing, handler.threatType); +} + +// Tests that html callback is only invoked once. +TEST_F(CWVUnsafeURLHandlerTest, DisplayHTMLCallbackIsOnlyCalledOnce) { + __block NSString* callback_html = nil; + __block int callback_count = 0; + base::OnceCallback callback = base::BindOnce(^(NSString* html) { + ++callback_count; + callback_html = html; + }); + CWVUnsafeURLHandler* handler = CreateHandler( + GURL(), GURL(), safe_browsing::SBThreatType::SB_THREAT_TYPE_URL_PHISHING, + std::move(callback)); + + [handler displayInterstitialPageWithHTML:@"foo"]; + EXPECT_NSEQ(@"foo", callback_html); + EXPECT_EQ(1, callback_count); + + // Second call should be a no op. + [handler displayInterstitialPageWithHTML:@"bar"]; + EXPECT_NSEQ(@"foo", callback_html); + EXPECT_EQ(1, callback_count); +} + +// Tests that proceeding will update allow list and reload the web state. +TEST_F(CWVUnsafeURLHandlerTest, ProceedingUpdatesAllowListAndReloadsWebState) { + auto main_frame_url = GURL("https://www.chromium.org"); + auto request_url = GURL("https://www.chromium.org"); + auto threat_type = safe_browsing::SBThreatType::SB_THREAT_TYPE_BILLING; + CWVUnsafeURLHandler* handler = CreateHandler(main_frame_url, request_url, + threat_type, base::DoNothing()); + SafeBrowsingUrlAllowList* allow_list = + SafeBrowsingUrlAllowList::FromWebState(&web_state_); + allow_list->AddPendingUnsafeNavigationDecision(main_frame_url, threat_type); + + [handler proceed]; + EXPECT_TRUE(GetNavigationManager()->ReloadWasCalled()); + EXPECT_TRUE(allow_list->AreUnsafeNavigationsAllowed(main_frame_url)); + EXPECT_FALSE(allow_list->IsUnsafeNavigationDecisionPending(main_frame_url)); +} + +// Tests that going back will close the web state. +TEST_F(CWVUnsafeURLHandlerTest, GoingBackClosesWebState) { + auto main_frame_url = GURL("https://www.chromium.org"); + auto request_url = GURL("https://www.chromium.org"); + auto threat_type = safe_browsing::SBThreatType::SB_THREAT_TYPE_BILLING; + CWVUnsafeURLHandler* handler = CreateHandler(main_frame_url, request_url, + threat_type, base::DoNothing()); + SafeBrowsingUrlAllowList* allow_list = + SafeBrowsingUrlAllowList::FromWebState(&web_state_); + allow_list->AddPendingUnsafeNavigationDecision(main_frame_url, threat_type); + + [handler goBack]; + EXPECT_FALSE(allow_list->AreUnsafeNavigationsAllowed(main_frame_url)); + EXPECT_FALSE(allow_list->IsUnsafeNavigationDecisionPending(main_frame_url)); + EXPECT_TRUE(web_state_.IsClosed()); +} + +// Tests that going back will navigate backwards if possible. +TEST_F(CWVUnsafeURLHandlerTest, GoingBackNavigatesBack) { + GetNavigationManager()->AddItem(GURL("https://www.example.com"), + ui::PAGE_TRANSITION_TYPED); + GetNavigationManager()->AddItem(GURL("https://www.example2.com"), + ui::PAGE_TRANSITION_TYPED); + + auto main_frame_url = GURL("https://www.chromium.org"); + auto request_url = GURL("https://www.chromium.org"); + auto threat_type = safe_browsing::SBThreatType::SB_THREAT_TYPE_BILLING; + SafeBrowsingUrlAllowList* allow_list = + SafeBrowsingUrlAllowList::FromWebState(&web_state_); + allow_list->AddPendingUnsafeNavigationDecision(main_frame_url, threat_type); + CWVUnsafeURLHandler* handler = CreateHandler(main_frame_url, request_url, + threat_type, base::DoNothing()); + EXPECT_TRUE(GetNavigationManager()->CanGoBack()); + int item_index = GetNavigationManager()->GetLastCommittedItemIndex(); + [handler goBack]; + EXPECT_FALSE(allow_list->IsUnsafeNavigationDecisionPending(main_frame_url)); + EXPECT_EQ(item_index - 1, + GetNavigationManager()->GetLastCommittedItemIndex()); +} + +// Tests that deallocation will remove a pending decision. +TEST_F(CWVUnsafeURLHandlerTest, DeallocationRemovesPendingDecision) { + auto main_frame_url = GURL("https://www.chromium.org"); + auto request_url = GURL("https://www.chromium.org"); + auto threat_type = safe_browsing::SBThreatType::SB_THREAT_TYPE_BILLING; + SafeBrowsingUrlAllowList* allow_list = + SafeBrowsingUrlAllowList::FromWebState(&web_state_); + // Manually creating an autorelease pool will ensure handler is released + // before the end of the test. + @autoreleasepool { + __unused CWVUnsafeURLHandler* handler = CreateHandler( + main_frame_url, request_url, threat_type, base::DoNothing()); + allow_list->AddPendingUnsafeNavigationDecision(main_frame_url, threat_type); + EXPECT_TRUE(allow_list->IsUnsafeNavigationDecisionPending(main_frame_url)); + } + EXPECT_FALSE(allow_list->IsUnsafeNavigationDecisionPending(main_frame_url)); +} + +} // namespace ios_web_view
diff --git a/ios/web_view/public/cwv_unsafe_url_handler.h b/ios/web_view/public/cwv_unsafe_url_handler.h index e90465a..bd571fa 100644 --- a/ios/web_view/public/cwv_unsafe_url_handler.h +++ b/ios/web_view/public/cwv_unsafe_url_handler.h
@@ -13,8 +13,10 @@ // Threat types. typedef NS_ENUM(NSInteger, CWVUnsafeURLThreatType) { + // Unknown threat type. + CWVUnsafeURLThreatTypeUnknown = 0, // Potential billing that may not be obvious to the user. - CWVUnsafeURLThreatTypeBilling = 0, + CWVUnsafeURLThreatTypeBilling, // The URL hosts malware. CWVUnsafeURLThreatTypeMalware, // The URL hosts unwanted programs. @@ -40,6 +42,8 @@ // The threat type of the unsafe URL. @property(nonatomic, readonly) CWVUnsafeURLThreatType threatType; +- (instancetype)init NS_UNAVAILABLE; + // Display an interstitial page with |HTML|. // This will be a no-op after the first call. - (void)displayInterstitialPageWithHTML:(NSString*)HTML;
diff --git a/media/base/media_serializers.h b/media/base/media_serializers.h index 8b67bb5..a41080d 100644 --- a/media/base/media_serializers.h +++ b/media/base/media_serializers.h
@@ -360,8 +360,7 @@ base::Value result(base::Value::Type::DICTIONARY); FIELD_SERIALIZE("kind", value.kind()); FIELD_SERIALIZE("language", value.language()); - if (value.label().length() && - base::IsStringUTF8AllowingNoncharacters(value.label())) { + if (value.label().length()) { FIELD_SERIALIZE("label", value.label()); } return result;
diff --git a/media/base/media_serializers_base.h b/media/base/media_serializers_base.h index 8e1359b..bbc6ce3 100644 --- a/media/base/media_serializers_base.h +++ b/media/base/media_serializers_base.h
@@ -7,6 +7,7 @@ #include <vector> +#include "base/strings/string_util.h" #include "base/values.h" #include "media/base/media_export.h" @@ -22,6 +23,17 @@ static inline base::Value Serialize(T value) { return base::Value(value); } }; +// a special serializer for strings, because base::Value checks +// IsStringUTF8AllowingNoncharacters. +template <> +struct MediaSerializer<std::string> { + static inline base::Value Serialize(const std::string& string) { + if (base::IsStringUTF8AllowingNoncharacters(string)) + return base::Value(string); + return base::Value(""); + } +}; + } // namespace internal template <typename T>
diff --git a/media/mojo/services/gpu_mojo_media_client_cros.cc b/media/mojo/services/gpu_mojo_media_client_cros.cc index 5c987c3..c9c2652 100644 --- a/media/mojo/services/gpu_mojo_media_client_cros.cc +++ b/media/mojo/services/gpu_mojo_media_client_cros.cc
@@ -7,6 +7,7 @@ #include "base/metrics/histogram_functions.h" #include "build/build_config.h" #include "media/base/audio_decoder.h" +#include "media/base/audio_encoder.h" #include "media/base/media_switches.h" #include "media/gpu/chromeos/mailbox_video_frame_converter.h" #include "media/gpu/chromeos/platform_video_frame_pool.h"
diff --git a/net/BUILD.gn b/net/BUILD.gn index 7ef93f0..5801d28 100644 --- a/net/BUILD.gn +++ b/net/BUILD.gn
@@ -3429,14 +3429,9 @@ "data/verify_signed_data_unittest/rsa-pkcs1-sha256-using-ecdsa-algorithm.pem", "data/verify_signed_data_unittest/rsa-pkcs1-sha256-using-id-ea-rsa.pem", "data/verify_signed_data_unittest/rsa-pkcs1-sha256.pem", - "data/verify_signed_data_unittest/rsa-pss-sha1-salt20-using-pss-key-no-params.pem", - "data/verify_signed_data_unittest/rsa-pss-sha1-salt20-using-pss-key-with-null-params.pem", - "data/verify_signed_data_unittest/rsa-pss-sha1-salt20.pem", - "data/verify_signed_data_unittest/rsa-pss-sha1-wrong-salt.pem", - "data/verify_signed_data_unittest/rsa-pss-sha256-mgf1-sha512-salt33.pem", - "data/verify_signed_data_unittest/rsa-pss-sha256-salt10-using-pss-key-with-params.pem", - "data/verify_signed_data_unittest/rsa-pss-sha256-salt10-using-pss-key-with-wrong-params.pem", - "data/verify_signed_data_unittest/rsa-pss-sha256-salt10.pem", + "data/verify_signed_data_unittest/rsa-pss-sha256-using-pss-key-with-params.pem", + "data/verify_signed_data_unittest/rsa-pss-sha256-wrong-salt.pem", + "data/verify_signed_data_unittest/rsa-pss-sha256.pem", "data/verify_signed_data_unittest/rsa-using-ec-key.pem", "data/verify_signed_data_unittest/rsa2048-pkcs1-sha512.pem", "third_party/nist-pkits/certs/AllCertificatesNoPoliciesTest2EE.crt",
diff --git a/net/base/data_url.cc b/net/base/data_url.cc index 99be85f4..42b6939 100644 --- a/net/base/data_url.cc +++ b/net/base/data_url.cc
@@ -10,6 +10,8 @@ #include "base/base64.h" #include "base/containers/cxx20_erase.h" +#include "base/feature_list.h" +#include "base/features.h" #include "base/strings/escape.h" #include "base/strings/string_piece.h" #include "base/strings/string_split.h" @@ -20,6 +22,20 @@ #include "url/gurl.h" namespace net { +namespace { + +// A data URL is ready for decode if it: +// - Doesn't need any extra padding. +// - Does not have any escaped characters. +// - Does not have any whitespace. +bool IsDataURLReadyForDecode(base::StringPiece body) { + return (body.length() % 4) == 0 && base::ranges::find_if(body, [](char c) { + return c == '%' || + base::IsAsciiWhitespace(c); + }) == std::end(body); +} + +} // namespace bool DataURL::Parse(const GURL& url, std::string* mime_type, @@ -32,12 +48,20 @@ DCHECK(charset->empty()); DCHECK(!data || data->empty()); - std::string content = url.GetContent(); + base::StringPiece content; + std::string content_string; + if (base::FeatureList::IsEnabled(base::features::kOptimizeDataUrls)) { + // Avoid copying the URL content which can be expensive for large URLs. + content = url.GetContentPiece(); + } else { + content_string = url.GetContent(); + content = content_string; + } - std::string::const_iterator begin = content.begin(); - std::string::const_iterator end = content.end(); + base::StringPiece::const_iterator begin = content.begin(); + base::StringPiece::const_iterator end = content.end(); - std::string::const_iterator comma = std::find(begin, end, ','); + base::StringPiece::const_iterator comma = std::find(begin, end, ','); if (comma == end) return false; @@ -110,24 +134,31 @@ // of the data, and should be stripped. Otherwise, the escaped whitespace // could be part of the payload, so don't strip it. if (base64_encoded) { - std::string unescaped_body = base::UnescapeBinaryURLComponent(raw_body); + // If the data URL is well formed, we can decode it immediately. + if (base::FeatureList::IsEnabled(base::features::kOptimizeDataUrls) && + IsDataURLReadyForDecode(raw_body)) { + if (!base::Base64Decode(raw_body, data)) + return false; + } else { + std::string unescaped_body = base::UnescapeBinaryURLComponent(raw_body); - // Strip spaces, which aren't allowed in Base64 encoding. - base::EraseIf(unescaped_body, base::IsAsciiWhitespace<char>); + // Strip spaces, which aren't allowed in Base64 encoding. + base::EraseIf(unescaped_body, base::IsAsciiWhitespace<char>); - size_t length = unescaped_body.length(); - size_t padding_needed = 4 - (length % 4); - // If the input wasn't padded, then we pad it as necessary until we have a - // length that is a multiple of 4 as required by our decoder. We don't - // correct if the input was incorrectly padded. If |padding_needed| == 3, - // then the input isn't well formed and decoding will fail with or without - // padding. - if ((padding_needed == 1 || padding_needed == 2) && - unescaped_body[length - 1] != '=') { - unescaped_body.resize(length + padding_needed, '='); + size_t length = unescaped_body.length(); + size_t padding_needed = 4 - (length % 4); + // If the input wasn't padded, then we pad it as necessary until we have + // a length that is a multiple of 4 as required by our decoder. We don't + // correct if the input was incorrectly padded. If |padding_needed| == + // 3, then the input isn't well formed and decoding will fail with or + // without padding. + if ((padding_needed == 1 || padding_needed == 2) && + unescaped_body[length - 1] != '=') { + unescaped_body.resize(length + padding_needed, '='); + } + if (!base::Base64Decode(unescaped_body, data)) + return false; } - if (!base::Base64Decode(unescaped_body, data)) - return false; } else { // Strip whitespace for non-text MIME types. std::string temp;
diff --git a/net/base/data_url_unittest.cc b/net/base/data_url_unittest.cc index 7471393..6fe83aa 100644 --- a/net/base/data_url_unittest.cc +++ b/net/base/data_url_unittest.cc
@@ -105,6 +105,14 @@ {"data:;base64,aGVsbG8gd29ybGQ", true, "text/plain", "US-ASCII", "hello world"}, + // Not sufficiently padded with whitespace. + {"data:;base64,aGV sbG8g d29ybGQ", true, "text/plain", "US-ASCII", + "hello world"}, + + // Not sufficiently padded with escaped whitespace. + {"data:;base64,aGV%20sbG8g%20d29ybGQ", true, "text/plain", "US-ASCII", + "hello world"}, + // Bad encoding (truncated). {"data:;base64,aGVsbG8gd29yb", false, "", "", ""},
diff --git a/net/cert/internal/signature_algorithm.cc b/net/cert/internal/signature_algorithm.cc index cfb93804..c579ea6 100644 --- a/net/cert/internal/signature_algorithm.cc +++ b/net/cert/internal/signature_algorithm.cc
@@ -8,9 +8,6 @@ #include <utility> #include "base/memory/ptr_util.h" -#include "base/metrics/histogram_macros.h" -#include "base/notreached.h" -#include "base/numerics/safe_math.h" #include "net/cert/internal/cert_error_params.h" #include "net/cert/internal/cert_errors.h" #include "net/der/input.h" @@ -378,73 +375,6 @@ return ParseHashAlgorithm(params, mgf1_hash); } -// Consumes an optional, explicitly-tagged INTEGER from |parser|, using the -// indicated context-specific class number. Values greater than 32-bits will be -// rejected. -// -// Returns true on success. -[[nodiscard]] bool ReadOptionalContextSpecificUint32( - der::Parser* parser, - uint8_t class_number, - absl::optional<uint32_t>* out) { - absl::optional<der::Input> field; - - // Read the context specific value. - if (!parser->ReadOptionalTag(der::ContextSpecificConstructed(class_number), - &field)) { - return false; - } - - if (field.has_value()) { - // Parse the integer contained in it. - der::Parser number_parser(field.value()); - uint64_t uint64_value; - - if (!number_parser.ReadUint64(&uint64_value)) - return false; - if (number_parser.HasMore()) - return false; - - // Cast the number to a uint32_t - base::CheckedNumeric<uint32_t> casted(uint64_value); - if (!casted.IsValid()) - return false; - *out = casted.ValueOrDie(); - } - - return true; -} - -RsaPssClassification ClassifyRsaPssParams(DigestAlgorithm digest, - DigestAlgorithm mgf1_hash, - uint32_t salt_length) { - if (digest != mgf1_hash) { - return RsaPssClassification::kDigestMismatch; - } - switch (digest) { - case DigestAlgorithm::Sha1: - return salt_length == 20 ? RsaPssClassification::kSha1 - : RsaPssClassification::kSha1NonstandardSalt; - case DigestAlgorithm::Sha256: - return salt_length == 32 ? RsaPssClassification::kSha256 - : RsaPssClassification::kSha256NonstandardSalt; - case DigestAlgorithm::Sha384: - return salt_length == 48 ? RsaPssClassification::kSha384 - : RsaPssClassification::kSha384NonstandardSalt; - case DigestAlgorithm::Sha512: - return salt_length == 64 ? RsaPssClassification::kSha512 - : RsaPssClassification::kSha512NonstandardSalt; - case DigestAlgorithm::Md2: - case DigestAlgorithm::Md4: - case DigestAlgorithm::Md5: - // Assuming anything using RSA-PSS long postdates these digests. Note this - // is also unreachable because `ParseHashAlgorithm` does not output these. - return RsaPssClassification::kLegacyDigest; - } - NOTREACHED(); - return RsaPssClassification::kLegacyDigest; -} - // Parses the parameters for an RSASSA-PSS signature algorithm, as defined by // RFC 5912: // @@ -465,7 +395,8 @@ // } // // Which is to say the parameters MUST be present, and of type -// RSASSA-PSS-params. +// RSASSA-PSS-params. Additionally, we only support the RSA-PSS parameter +// combinations representable by TLS 1.3 (RFC 8446). // // Note also that DER encoding (ITU-T X.690 section 11.5) prohibits // specifying default values explicitly. The parameter should instead be @@ -481,60 +412,43 @@ if (parser.HasMore()) return nullptr; - absl::optional<der::Input> field; - - // Parse: - // hashAlgorithm [0] HashAlgorithm DEFAULT sha1Identifier, - DigestAlgorithm hash = DigestAlgorithm::Sha1; - if (!params_parser.ReadOptionalTag(der::ContextSpecificConstructed(0), - &field)) { - return nullptr; - } - if (field.has_value() && !ParseHashAlgorithm(field.value(), &hash)) - return nullptr; - // Default hash should be specified by omission. - if (field.has_value() && hash == DigestAlgorithm::Sha1) - return nullptr; - - // Parse: - // maskGenAlgorithm [1] MaskGenAlgorithm DEFAULT mgf1SHA1, - DigestAlgorithm mgf1_hash = DigestAlgorithm::Sha1; - if (!params_parser.ReadOptionalTag(der::ContextSpecificConstructed(1), - &field)) { - return nullptr; - } - if (field.has_value() && !ParseMaskGenAlgorithm(field.value(), &mgf1_hash)) - return nullptr; - // Default mask generation should be specified by omission. - if (field.has_value() && mgf1_hash == DigestAlgorithm::Sha1) - return nullptr; - - // Parse: - // saltLength [2] INTEGER DEFAULT 20, - absl::optional<uint32_t> opt_salt_length; - if (!ReadOptionalContextSpecificUint32(¶ms_parser, 2, &opt_salt_length)) { - return nullptr; - } - // Default salt length should be specified by omission. - if (opt_salt_length.has_value() && opt_salt_length.value() == 20u) - return nullptr; - uint32_t salt_length = opt_salt_length.value_or(20u); - - // There must not be any unconsumed data left. (RFC 5912 does not explicitly - // include an extensibility point for RSASSA-PSS-params) + // The default values for hashAlgorithm, maskGenAlgorithm, and saltLength + // correspond to SHA-1, which we do not support with RSA-PSS, so treat them as + // required fields. Explicitly-specified defaults will be rejected later, when + // we limit combinations. Additionally, as the trailerField is required to be + // the default, we simply ignore it and reject it as any other trailing data. // - // This check will also reject trailerField if present. We only support - // a value of 1, which is the default value and thus must be omitted. If - // trailerField is present, it is either an incorrect encoding of the - // default value, or a value we do not support. - if (params_parser.HasMore()) + // hashAlgorithm [0] HashAlgorithm DEFAULT sha1Identifier, + // maskGenAlgorithm [1] MaskGenAlgorithm DEFAULT mgf1SHA1, + // saltLength [2] INTEGER DEFAULT 20, + // trailerField [3] INTEGER DEFAULT 1 + der::Input field; + DigestAlgorithm hash, mgf1_hash; + der::Parser salt_length_parser; + uint64_t salt_length; + if (!params_parser.ReadTag(der::ContextSpecificConstructed(0), &field) || + !ParseHashAlgorithm(field, &hash) || + !params_parser.ReadTag(der::ContextSpecificConstructed(1), &field) || + !ParseMaskGenAlgorithm(field, &mgf1_hash) || + !params_parser.ReadConstructed(der::ContextSpecificConstructed(2), + &salt_length_parser) || + !salt_length_parser.ReadUint64(&salt_length) || + salt_length_parser.HasMore() || params_parser.HasMore()) { return nullptr; + } - // See https://crbug.com/1279975. - UMA_HISTOGRAM_ENUMERATION("Net.CertVerifier.RsaPssClassification", - ClassifyRsaPssParams(hash, mgf1_hash, salt_length)); + // Only combinations of RSASSA-PSS-params specified by TLS 1.3 (RFC 8446) are + // supported. + if ((hash == DigestAlgorithm::Sha256 && + mgf1_hash == DigestAlgorithm::Sha256 && salt_length == 32) || + (hash == DigestAlgorithm::Sha384 && + mgf1_hash == DigestAlgorithm::Sha384 && salt_length == 48) || + (hash == DigestAlgorithm::Sha512 && + mgf1_hash == DigestAlgorithm::Sha512 && salt_length == 64)) { + return SignatureAlgorithm::CreateRsaPss(hash, mgf1_hash, salt_length); + } - return SignatureAlgorithm::CreateRsaPss(hash, mgf1_hash, salt_length); + return nullptr; } DEFINE_CERT_ERROR_ID(kUnknownAlgorithmIdentifierOid,
diff --git a/net/cert/internal/signature_algorithm.h b/net/cert/internal/signature_algorithm.h index c984f58f..cf5d4cc 100644 --- a/net/cert/internal/signature_algorithm.h +++ b/net/cert/internal/signature_algorithm.h
@@ -39,37 +39,6 @@ Dsa, // DSA }; -// A classification of the RSA-PSS parameters. This is only used in histograms -// and is gathered with the hope to reduce RSA-PSS to a small set of enums in -// the future. See https://crbug.com/1279975. -// -// These values are logged to UMA. Entries should not be renumbered and -// numeric values should never be reused. Please keep in sync with -// "RsaPssClassification" in src/tools/metrics/histograms/enums.xml. -enum class RsaPssClassification { - // The MGF-1 digest and signing digest did not match. - kDigestMismatch = 0, - // The digest algorithm was MD5 or older. - kLegacyDigest = 1, - // SHA-1 with salt length of 20. - kSha1 = 2, - // SHA-1 with a non-standard salt length. - kSha1NonstandardSalt = 3, - // SHA-256 with a salt length of 32. - kSha256 = 4, - // SHA-256 with a non-standard salt length. - kSha256NonstandardSalt = 5, - // SHA-384 with a salt length of 48. - kSha384 = 6, - // SHA-384 with a non-standard salt length. - kSha384NonstandardSalt = 7, - // SHA-512 with a salt length of 64. - kSha512 = 8, - // SHA-512 with a non-standard salt length. - kSha512NonstandardSalt = 9, - kMaxValue = kSha512NonstandardSalt, -}; - // Parses a HashAlgorithm as defined by RFC 5912: // // HashAlgorithm ::= AlgorithmIdentifier{DIGEST-ALGORITHM, @@ -116,6 +85,8 @@ // SignatureAlgorithm describes a signature algorithm and its parameters. This // corresponds to "AlgorithmIdentifier" from RFC 5280. +// +// TODO(crbug.com/1321691): Replace this with a simple enum. class NET_EXPORT SignatureAlgorithm { public: SignatureAlgorithm(const SignatureAlgorithm&) = delete;
diff --git a/net/cert/internal/signature_algorithm_unittest.cc b/net/cert/internal/signature_algorithm_unittest.cc index 5d21096..c721eb34 100644 --- a/net/cert/internal/signature_algorithm_unittest.cc +++ b/net/cert/internal/signature_algorithm_unittest.cc
@@ -9,7 +9,6 @@ #include "base/containers/span.h" #include "base/files/file_util.h" #include "base/strings/string_number_conversions.h" -#include "base/test/metrics/histogram_tester.h" #include "net/cert/internal/cert_errors.h" #include "net/cert/pem.h" #include "net/der/input.h" @@ -600,8 +599,8 @@ EXPECT_EQ(32u, params->salt_length()); } -// Parses a rsaPss algorithm that has an empty parameters. It should use all the -// default values (SHA1 and salt length of 20). +// Parses a rsaPss algorithm that has an empty parameters. This encodes the +// default, SHA-1, which we do not support. // // SEQUENCE (2 elem) // OBJECT IDENTIFIER 1.2.840.113549.1.1.10 @@ -616,16 +615,7 @@ }; // clang-format on std::unique_ptr<SignatureAlgorithm> algorithm; - ASSERT_TRUE(ParseDer(kData, &algorithm)); - - ASSERT_EQ(SignatureAlgorithmId::RsaPss, algorithm->algorithm()); - EXPECT_EQ(DigestAlgorithm::Sha1, algorithm->digest()); - - const RsaPssParameters* params = algorithm->ParamsForRsaPss(); - - ASSERT_TRUE(params); - EXPECT_EQ(DigestAlgorithm::Sha1, params->mgf1_hash()); - EXPECT_EQ(20u, params->salt_length()); + EXPECT_FALSE(ParseDer(kData, &algorithm)); } // Parses a rsaPss algorithm that has NULL parameters. This fails. @@ -682,39 +672,6 @@ ASSERT_FALSE(ParseDer(kData, &algorithm)); } -// Parses a rsaPss algorithm that uses defaults (by ommitting the values) for -// everything except the salt length. -// -// SEQUENCE (2 elem) -// OBJECT IDENTIFIER 1.2.840.113549.1.1.10 -// SEQUENCE (1 elem) -// [2] (1 elem) -// INTEGER 23 -TEST(SignatureAlgorithmTest, ParseDerRsaPssDefaultsExceptForSaltLength) { - // clang-format off - const uint8_t kData[] = { - 0x30, 0x12, // SEQUENCE (62 bytes) - 0x06, 0x09, // OBJECT IDENTIFIER (9 bytes) - 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x0A, - 0x30, 0x05, // SEQUENCE (5 bytes) - 0xA2, 0x03, // [2] (3 bytes) - 0x02, 0x01, // INTEGER (1 byte) - 0x17, - }; - // clang-format on - std::unique_ptr<SignatureAlgorithm> algorithm; - ASSERT_TRUE(ParseDer(kData, &algorithm)); - - ASSERT_EQ(SignatureAlgorithmId::RsaPss, algorithm->algorithm()); - EXPECT_EQ(DigestAlgorithm::Sha1, algorithm->digest()); - - const RsaPssParameters* params = algorithm->ParamsForRsaPss(); - - ASSERT_TRUE(params); - EXPECT_EQ(DigestAlgorithm::Sha1, params->mgf1_hash()); - EXPECT_EQ(23u, params->salt_length()); -} - // Parses a rsaPss algorithm that has unrecognized data (NULL) within the // parameters sequence. // @@ -792,7 +749,8 @@ } // Parses a rsaPss algorithm that uses SHA384 for the hash, and leaves the rest -// as defaults (including the mask gen). +// as defaults, specifying a SHA-1 MGF-1 hash. This fails because we require +// the hashes match. // // SEQUENCE (2 elem) // OBJECT IDENTIFIER 1.2.840.113549.1.1.10 @@ -816,52 +774,7 @@ }; // clang-format on std::unique_ptr<SignatureAlgorithm> algorithm; - ASSERT_TRUE(ParseDer(kData, &algorithm)); - - ASSERT_EQ(SignatureAlgorithmId::RsaPss, algorithm->algorithm()); - EXPECT_EQ(DigestAlgorithm::Sha384, algorithm->digest()); - - const RsaPssParameters* params = algorithm->ParamsForRsaPss(); - - ASSERT_TRUE(params); - EXPECT_EQ(DigestAlgorithm::Sha1, params->mgf1_hash()); - EXPECT_EQ(20u, params->salt_length()); -} - -// Parses a rsaPss algorithm that uses SHA384 for the hash, however in the -// AlgorithmIdentifier for the hash function the parameters are omitted instead -// of NULL. -// -// SEQUENCE (2 elem) -// OBJECT IDENTIFIER 1.2.840.113549.1.1.10 -// SEQUENCE (1 elem) -// [0] (1 elem) -// SEQUENCE (1 elem) -// OBJECT IDENTIFIER 2.16.840.1.101.3.4.2.2 -TEST(SignatureAlgorithmTest, ParseDerRsaPssNonDefaultHashAbsentParams) { - // clang-format off - const uint8_t kData[] = { - 0x30, 0x1C, // SEQUENCE (28 bytes) - 0x06, 0x09, // OBJECT IDENTIFIER (9 bytes) - 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x0A, - 0x30, 0x0F, // SEQUENCE (15 bytes) - 0xA0, 0x0D, // [0] (13 bytes) - 0x30, 0x0B, // SEQUENCE (11 bytes) - 0x06, 0x09, // OBJECT IDENTIFIER (9 bytes) - 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x02, - }; - // clang-format on - std::unique_ptr<SignatureAlgorithm> algorithm; - ASSERT_TRUE(ParseDer(kData, &algorithm)); - - ASSERT_EQ(SignatureAlgorithmId::RsaPss, algorithm->algorithm()); - EXPECT_EQ(DigestAlgorithm::Sha384, algorithm->digest()); - - const RsaPssParameters* params = algorithm->ParamsForRsaPss(); - - ASSERT_TRUE(params); - EXPECT_EQ(DigestAlgorithm::Sha1, params->mgf1_hash()); - EXPECT_EQ(20u, params->salt_length()); + EXPECT_FALSE(ParseDer(kData, &algorithm)); } // Parses a rsaPss algorithm that uses an invalid hash algorithm (twiddled the @@ -891,7 +804,8 @@ } // Parses a rsaPss algorithm that uses SHA512 MGF1 for the mask gen, and -// defaults for the rest. +// defaults (SHA-1) for the rest. This fails because we require the hashes +// match. // // SEQUENCE (2 elem) // OBJECT IDENTIFIER 1.2.840.113549.1.1.10 @@ -920,16 +834,7 @@ }; // clang-format on std::unique_ptr<SignatureAlgorithm> algorithm; - ASSERT_TRUE(ParseDer(kData, &algorithm)); - - ASSERT_EQ(SignatureAlgorithmId::RsaPss, algorithm->algorithm()); - EXPECT_EQ(DigestAlgorithm::Sha1, algorithm->digest()); - - const RsaPssParameters* params = algorithm->ParamsForRsaPss(); - - ASSERT_TRUE(params); - EXPECT_EQ(DigestAlgorithm::Sha512, params->mgf1_hash()); - EXPECT_EQ(20u, params->salt_length()); + EXPECT_FALSE(ParseDer(kData, &algorithm)); } // Parses a rsaPss algorithm that uses a mask gen with an unrecognized OID @@ -966,7 +871,7 @@ } // Parses a rsaPss algorithm that uses SHA256 for the hash, and SHA512 for the -// MGF1. +// MGF1. This fails because we require the hashes match. // // SEQUENCE (2 elem) // OBJECT IDENTIFIER 1.2.840.113549.1.1.10 @@ -1004,20 +909,12 @@ }; // clang-format on std::unique_ptr<SignatureAlgorithm> algorithm; - ASSERT_TRUE(ParseDer(kData, &algorithm)); - - ASSERT_EQ(SignatureAlgorithmId::RsaPss, algorithm->algorithm()); - EXPECT_EQ(DigestAlgorithm::Sha256, algorithm->digest()); - - const RsaPssParameters* params = algorithm->ParamsForRsaPss(); - - ASSERT_TRUE(params); - EXPECT_EQ(DigestAlgorithm::Sha512, params->mgf1_hash()); - EXPECT_EQ(20u, params->salt_length()); + EXPECT_FALSE(ParseDer(kData, &algorithm)); } // Parses a rsaPss algorithm that uses SHA256 for the hash, and SHA256 for the -// MGF1, and a salt length of 10. +// MGF1, and a salt length of 10. This fails because we require a standard salt +// length. // // SEQUENCE (2 elem) // OBJECT IDENTIFIER 1.2.840.113549.1.1.10 @@ -1060,16 +957,7 @@ }; // clang-format on std::unique_ptr<SignatureAlgorithm> algorithm; - ASSERT_TRUE(ParseDer(kData, &algorithm)); - - ASSERT_EQ(SignatureAlgorithmId::RsaPss, algorithm->algorithm()); - EXPECT_EQ(DigestAlgorithm::Sha256, algorithm->digest()); - - const RsaPssParameters* params = algorithm->ParamsForRsaPss(); - - ASSERT_TRUE(params); - EXPECT_EQ(DigestAlgorithm::Sha256, params->mgf1_hash()); - EXPECT_EQ(10u, params->salt_length()); + EXPECT_FALSE(ParseDer(kData, &algorithm)); } // Parses a rsaPss algorithm that specifies default hash (SHA1). @@ -1097,8 +985,6 @@ }; // clang-format on std::unique_ptr<SignatureAlgorithm> algorithm; - base::HistogramTester histogram_tester; - ASSERT_FALSE(ParseDer(kData, &algorithm)); } @@ -1132,8 +1018,6 @@ }; // clang-format on std::unique_ptr<SignatureAlgorithm> algorithm; - base::HistogramTester histogram_tester; - ASSERT_FALSE(ParseDer(kData, &algorithm)); } @@ -1158,34 +1042,50 @@ }; // clang-format on std::unique_ptr<SignatureAlgorithm> algorithm; - base::HistogramTester histogram_tester; - ASSERT_FALSE(ParseDer(kData, &algorithm)); } // Parses a rsaPss algorithm that specifies default trailer field. // It is invalid to specify the default. -// -// SEQUENCE (2 elem) -// OBJECT IDENTIFIER 1.2.840.113549.1.1.10 -// SEQUENCE (1 elem) -// [3] (1 elem) -// INTEGER 1 TEST(SignatureAlgorithmTest, ParseDerRsaPssSpecifiedDefaultTrailerField) { - // clang-format off + // SEQUENCE { + // # rsassa-pss + // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.10 } + // SEQUENCE { + // [0] { + // SEQUENCE { + // # sha256 + // OBJECT_IDENTIFIER { 2.16.840.1.101.3.4.2.1 } + // NULL {} + // } + // } + // [1] { + // SEQUENCE { + // # mgf1 + // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.8 } + // SEQUENCE { + // # sha256 + // OBJECT_IDENTIFIER { 2.16.840.1.101.3.4.2.1 } + // NULL {} + // } + // } + // } + // [2] { + // INTEGER { 32 } + // } + // [3] { + // INTEGER { 1 } + // } + // } + // } const uint8_t kData[] = { - 0x30, 0x12, // SEQUENCE (18 bytes) - 0x06, 0x09, // OBJECT IDENTIFIER (9 bytes) - 0x2A, 0x86, 0x48, 0x86, 0xF7, 0x0D, 0x01, 0x01, 0x0A, - 0x30, 0x05, // SEQUENCE (5 bytes) - 0xA3, 0x03, // [3] (3 bytes) - 0x02, 0x01, // INTEGER (1 byte) - 0x01, - }; - // clang-format on + 0x30, 0x46, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, + 0x0a, 0x30, 0x39, 0xa0, 0x0f, 0x30, 0x0d, 0x06, 0x09, 0x60, 0x86, 0x48, + 0x01, 0x65, 0x03, 0x04, 0x02, 0x01, 0x05, 0x00, 0xa1, 0x1c, 0x30, 0x1a, + 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, 0x08, 0x30, + 0x0d, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x01, + 0x05, 0x00, 0xa2, 0x03, 0x02, 0x01, 0x20, 0xa3, 0x03, 0x02, 0x01, 0x01}; std::unique_ptr<SignatureAlgorithm> algorithm; - base::HistogramTester histogram_tester; - ASSERT_FALSE(ParseDer(kData, &algorithm)); } @@ -1238,103 +1138,17 @@ }; // clang-format on std::unique_ptr<SignatureAlgorithm> algorithm; - base::HistogramTester histogram_tester; - ASSERT_FALSE(ParseDer(kData, &algorithm)); } -TEST(SignatureAlgorithmTest, RsaPssClassification) { +TEST(SignatureAlgorithmTest, ParseRsaPss) { // Test data generated with https://github.com/google/der-ascii. struct { std::vector<uint8_t> data; - RsaPssClassification expected_classification; - } kTests[] = { - // SEQUENCE { - // # rsassa-pss - // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.10 } - // SEQUENCE { - // [0] { - // SEQUENCE { - // # sha256 - // OBJECT_IDENTIFIER { 2.16.840.1.101.3.4.2.1 } - // NULL {} - // } - // } - // [1] { - // SEQUENCE { - // # mgf1 - // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.8 } - // SEQUENCE { - // # sha384 - // OBJECT_IDENTIFIER { 2.16.840.1.101.3.4.2.2 } - // NULL {} - // } - // } - // } - // } - // } - {{0x30, 0x3c, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, - 0x01, 0x0a, 0x30, 0x2f, 0xa0, 0x0f, 0x30, 0x0d, 0x06, 0x09, 0x60, - 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x01, 0x05, 0x00, 0xa1, - 0x1c, 0x30, 0x1a, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, - 0x01, 0x01, 0x08, 0x30, 0x0d, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, - 0x65, 0x03, 0x04, 0x02, 0x02, 0x05, 0x00}, - RsaPssClassification::kDigestMismatch}, - // SEQUENCE { - // # rsassa-pss - // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.10 } - // SEQUENCE { - // [0] { - // SEQUENCE { - // # md5 - // OBJECT_IDENTIFIER { 1.2.840.113549.2.5 } - // NULL {} - // } - // } - // [1] { - // SEQUENCE { - // # mgf1 - // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.8 } - // SEQUENCE { - // # md5 - // OBJECT_IDENTIFIER { 1.2.840.113549.2.5 } - // NULL {} - // } - // } - // } - // [2] { - // INTEGER { 16 } - // } - // } - // } - {{0x30, 0x3f, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, - 0x01, 0x0a, 0x30, 0x32, 0xa0, 0x0e, 0x30, 0x0c, 0x06, 0x08, 0x2a, - 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x02, 0x05, 0x05, 0x00, 0xa1, 0x1b, - 0x30, 0x19, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, - 0x01, 0x08, 0x30, 0x0c, 0x06, 0x08, 0x2a, 0x86, 0x48, 0x86, 0xf7, - 0x0d, 0x02, 0x05, 0x05, 0x00, 0xa2, 0x03, 0x02, 0x01, 0x10}, - RsaPssClassification::kLegacyDigest}, - // SEQUENCE { - // # rsassa-pss - // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.10 } - // # SHA-1 with salt length 20 is the default. - // SEQUENCE {} - // } - {{0x30, 0x0d, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, - 0x0a, 0x30, 0x00}, - RsaPssClassification::kSha1}, - // SEQUENCE { - // # rsassa-pss - // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.10 } - // SEQUENCE { - // [2] { - // INTEGER { 21 } - // } - // } - // } - {{0x30, 0x12, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, - 0x01, 0x01, 0x0a, 0x30, 0x05, 0xa2, 0x03, 0x02, 0x01, 0x15}, - RsaPssClassification::kSha1NonstandardSalt}, + DigestAlgorithm expected_digest; + DigestAlgorithm expected_mgf1_hash; + uint32_t expected_salt_length; + } kValidTests[] = { // SEQUENCE { // # rsassa-pss // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.10 } @@ -1368,41 +1182,9 @@ 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, 0x08, 0x30, 0x0d, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x01, 0x05, 0x00, 0xa2, 0x03, 0x02, 0x01, 0x20}, - RsaPssClassification::kSha256}, - // SEQUENCE { - // # rsassa-pss - // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.10 } - // SEQUENCE { - // [0] { - // SEQUENCE { - // # sha256 - // OBJECT_IDENTIFIER { 2.16.840.1.101.3.4.2.1 } - // NULL {} - // } - // } - // [1] { - // SEQUENCE { - // # mgf1 - // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.8 } - // SEQUENCE { - // # sha256 - // OBJECT_IDENTIFIER { 2.16.840.1.101.3.4.2.1 } - // NULL {} - // } - // } - // } - // [2] { - // INTEGER { 33 } - // } - // } - // } - {{0x30, 0x41, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, - 0x0a, 0x30, 0x34, 0xa0, 0x0f, 0x30, 0x0d, 0x06, 0x09, 0x60, 0x86, 0x48, - 0x01, 0x65, 0x03, 0x04, 0x02, 0x01, 0x05, 0x00, 0xa1, 0x1c, 0x30, 0x1a, - 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, 0x08, 0x30, - 0x0d, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x01, - 0x05, 0x00, 0xa2, 0x03, 0x02, 0x01, 0x21}, - RsaPssClassification::kSha256NonstandardSalt}, + DigestAlgorithm::Sha256, + DigestAlgorithm::Sha256, + 32}, // SEQUENCE { // # rsassa-pss // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.10 } @@ -1436,41 +1218,9 @@ 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, 0x08, 0x30, 0x0d, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x02, 0x05, 0x00, 0xa2, 0x03, 0x02, 0x01, 0x30}, - RsaPssClassification::kSha384}, - // SEQUENCE { - // # rsassa-pss - // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.10 } - // SEQUENCE { - // [0] { - // SEQUENCE { - // # sha384 - // OBJECT_IDENTIFIER { 2.16.840.1.101.3.4.2.2 } - // NULL {} - // } - // } - // [1] { - // SEQUENCE { - // # mgf1 - // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.8 } - // SEQUENCE { - // # sha384 - // OBJECT_IDENTIFIER { 2.16.840.1.101.3.4.2.2 } - // NULL {} - // } - // } - // } - // [2] { - // INTEGER { 49 } - // } - // } - // } - {{0x30, 0x41, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, - 0x0a, 0x30, 0x34, 0xa0, 0x0f, 0x30, 0x0d, 0x06, 0x09, 0x60, 0x86, 0x48, - 0x01, 0x65, 0x03, 0x04, 0x02, 0x02, 0x05, 0x00, 0xa1, 0x1c, 0x30, 0x1a, - 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, 0x08, 0x30, - 0x0d, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x02, - 0x05, 0x00, 0xa2, 0x03, 0x02, 0x01, 0x31}, - RsaPssClassification::kSha384NonstandardSalt}, + DigestAlgorithm::Sha384, + DigestAlgorithm::Sha384, + 48}, // SEQUENCE { // # rsassa-pss // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.10 } @@ -1504,7 +1254,201 @@ 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, 0x08, 0x30, 0x0d, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x03, 0x05, 0x00, 0xa2, 0x03, 0x02, 0x01, 0x40}, - RsaPssClassification::kSha512}, + DigestAlgorithm::Sha512, + DigestAlgorithm::Sha512, + 64}, + + // The same inputs as above, but the NULLs in the digest algorithms are + // omitted. + {{0x30, 0x3d, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, + 0x01, 0x0a, 0x30, 0x30, 0xa0, 0x0d, 0x30, 0x0b, 0x06, 0x09, 0x60, + 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x01, 0xa1, 0x1a, 0x30, + 0x18, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, + 0x08, 0x30, 0x0b, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, + 0x04, 0x02, 0x01, 0xa2, 0x03, 0x02, 0x01, 0x20}, + DigestAlgorithm::Sha256, + DigestAlgorithm::Sha256, + 32}, + {{0x30, 0x3d, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, + 0x01, 0x0a, 0x30, 0x30, 0xa0, 0x0d, 0x30, 0x0b, 0x06, 0x09, 0x60, + 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x02, 0xa1, 0x1a, 0x30, + 0x18, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, + 0x08, 0x30, 0x0b, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, + 0x04, 0x02, 0x02, 0xa2, 0x03, 0x02, 0x01, 0x30}, + DigestAlgorithm::Sha384, + DigestAlgorithm::Sha384, + 48}, + {{0x30, 0x3d, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, + 0x01, 0x0a, 0x30, 0x30, 0xa0, 0x0d, 0x30, 0x0b, 0x06, 0x09, 0x60, + 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x03, 0xa1, 0x1a, 0x30, + 0x18, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, + 0x08, 0x30, 0x0b, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, + 0x04, 0x02, 0x03, 0xa2, 0x03, 0x02, 0x01, 0x40}, + DigestAlgorithm::Sha512, + DigestAlgorithm::Sha512, + 64}}; + for (const auto& t : kValidTests) { + std::unique_ptr<SignatureAlgorithm> algorithm; + ASSERT_TRUE(ParseDer(t.data, &algorithm)); + ASSERT_EQ(SignatureAlgorithmId::RsaPss, algorithm->algorithm()); + EXPECT_EQ(t.expected_digest, algorithm->digest()); + EXPECT_EQ(t.expected_mgf1_hash, algorithm->ParamsForRsaPss()->mgf1_hash()); + EXPECT_EQ(t.expected_salt_length, + algorithm->ParamsForRsaPss()->salt_length()); + } + + struct { + std::vector<uint8_t> data; + } kInvalidTests[] = { + // SEQUENCE { + // # rsassa-pss + // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.10 } + // SEQUENCE { + // [0] { + // SEQUENCE { + // # sha256 + // OBJECT_IDENTIFIER { 2.16.840.1.101.3.4.2.1 } + // NULL {} + // } + // } + // [1] { + // SEQUENCE { + // # mgf1 + // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.8 } + // SEQUENCE { + // # sha384 + // OBJECT_IDENTIFIER { 2.16.840.1.101.3.4.2.2 } + // NULL {} + // } + // } + // } + // } + // } + {{0x30, 0x3c, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, + 0x01, 0x0a, 0x30, 0x2f, 0xa0, 0x0f, 0x30, 0x0d, 0x06, 0x09, 0x60, + 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x01, 0x05, 0x00, 0xa1, + 0x1c, 0x30, 0x1a, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, + 0x01, 0x01, 0x08, 0x30, 0x0d, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, + 0x65, 0x03, 0x04, 0x02, 0x02, 0x05, 0x00}}, + // SEQUENCE { + // # rsassa-pss + // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.10 } + // SEQUENCE { + // [0] { + // SEQUENCE { + // # md5 + // OBJECT_IDENTIFIER { 1.2.840.113549.2.5 } + // NULL {} + // } + // } + // [1] { + // SEQUENCE { + // # mgf1 + // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.8 } + // SEQUENCE { + // # md5 + // OBJECT_IDENTIFIER { 1.2.840.113549.2.5 } + // NULL {} + // } + // } + // } + // [2] { + // INTEGER { 16 } + // } + // } + // } + {{0x30, 0x3f, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, + 0x01, 0x0a, 0x30, 0x32, 0xa0, 0x0e, 0x30, 0x0c, 0x06, 0x08, 0x2a, + 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x02, 0x05, 0x05, 0x00, 0xa1, 0x1b, + 0x30, 0x19, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, + 0x01, 0x08, 0x30, 0x0c, 0x06, 0x08, 0x2a, 0x86, 0x48, 0x86, 0xf7, + 0x0d, 0x02, 0x05, 0x05, 0x00, 0xa2, 0x03, 0x02, 0x01, 0x10}}, + // SEQUENCE { + // # rsassa-pss + // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.10 } + // # SHA-1 with salt length 20 is the default. + // SEQUENCE {} + // } + {{0x30, 0x0d, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, + 0x0a, 0x30, 0x00}}, + // SEQUENCE { + // # rsassa-pss + // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.10 } + // SEQUENCE { + // [2] { + // INTEGER { 21 } + // } + // } + // } + {{0x30, 0x12, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, + 0x01, 0x01, 0x0a, 0x30, 0x05, 0xa2, 0x03, 0x02, 0x01, 0x15}}, + // SEQUENCE { + // # rsassa-pss + // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.10 } + // SEQUENCE { + // [0] { + // SEQUENCE { + // # sha256 + // OBJECT_IDENTIFIER { 2.16.840.1.101.3.4.2.1 } + // NULL {} + // } + // } + // [1] { + // SEQUENCE { + // # mgf1 + // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.8 } + // SEQUENCE { + // # sha256 + // OBJECT_IDENTIFIER { 2.16.840.1.101.3.4.2.1 } + // NULL {} + // } + // } + // } + // [2] { + // INTEGER { 33 } + // } + // } + // } + {{0x30, 0x41, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, + 0x0a, 0x30, 0x34, 0xa0, 0x0f, 0x30, 0x0d, 0x06, 0x09, 0x60, 0x86, 0x48, + 0x01, 0x65, 0x03, 0x04, 0x02, 0x01, 0x05, 0x00, 0xa1, 0x1c, 0x30, 0x1a, + 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, 0x08, 0x30, + 0x0d, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x01, + 0x05, 0x00, 0xa2, 0x03, 0x02, 0x01, 0x21}}, + // SEQUENCE { + // # rsassa-pss + // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.10 } + // SEQUENCE { + // [0] { + // SEQUENCE { + // # sha384 + // OBJECT_IDENTIFIER { 2.16.840.1.101.3.4.2.2 } + // NULL {} + // } + // } + // [1] { + // SEQUENCE { + // # mgf1 + // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.8 } + // SEQUENCE { + // # sha384 + // OBJECT_IDENTIFIER { 2.16.840.1.101.3.4.2.2 } + // NULL {} + // } + // } + // } + // [2] { + // INTEGER { 49 } + // } + // } + // } + {{0x30, 0x41, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, + 0x0a, 0x30, 0x34, 0xa0, 0x0f, 0x30, 0x0d, 0x06, 0x09, 0x60, 0x86, 0x48, + 0x01, 0x65, 0x03, 0x04, 0x02, 0x02, 0x05, 0x00, 0xa1, 0x1c, 0x30, 0x1a, + 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, 0x08, 0x30, + 0x0d, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x02, + 0x05, 0x00, 0xa2, 0x03, 0x02, 0x01, 0x31}}, + // SEQUENCE { // # rsassa-pss // OBJECT_IDENTIFIER { 1.2.840.113549.1.1.10 } @@ -1537,24 +1481,11 @@ 0x01, 0x65, 0x03, 0x04, 0x02, 0x03, 0x05, 0x00, 0xa1, 0x1c, 0x30, 0x1a, 0x06, 0x09, 0x2a, 0x86, 0x48, 0x86, 0xf7, 0x0d, 0x01, 0x01, 0x08, 0x30, 0x0d, 0x06, 0x09, 0x60, 0x86, 0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x03, - 0x05, 0x00, 0xa2, 0x03, 0x02, 0x01, 0x41}, - RsaPssClassification::kSha512NonstandardSalt}, + 0x05, 0x00, 0xa2, 0x03, 0x02, 0x01, 0x41}}, }; - for (const auto& t : kTests) { - base::HistogramTester histogram_tester; - + for (const auto& t : kInvalidTests) { std::unique_ptr<SignatureAlgorithm> algorithm; - // The legacy digests are not currently reachable because - // `ParseHashAlgorithm` does not support them. - if (t.expected_classification == RsaPssClassification::kLegacyDigest) { - EXPECT_FALSE(ParseDer(t.data, &algorithm)); - continue; - } - ASSERT_TRUE(ParseDer(t.data, &algorithm)); - ASSERT_EQ(SignatureAlgorithmId::RsaPss, algorithm->algorithm()); - - histogram_tester.ExpectUniqueSample("Net.CertVerifier.RsaPssClassification", - t.expected_classification, 1); + EXPECT_FALSE(ParseDer(t.data, &algorithm)); } }
diff --git a/net/cert/internal/simple_path_builder_delegate_unittest.cc b/net/cert/internal/simple_path_builder_delegate_unittest.cc index 565987b..e89e0b4e 100644 --- a/net/cert/internal/simple_path_builder_delegate_unittest.cc +++ b/net/cert/internal/simple_path_builder_delegate_unittest.cc
@@ -48,16 +48,10 @@ : public ::testing::TestWithParam<const char*> {}; const char* kSuccess1024Filenames[] = { - "rsa-pkcs1-sha1.pem", - "rsa-pkcs1-sha256.pem", - "rsa2048-pkcs1-sha512.pem", - "ecdsa-secp384r1-sha256.pem", - "ecdsa-prime256v1-sha512.pem", - "rsa-pss-sha1-salt20.pem", - "rsa-pss-sha256-mgf1-sha512-salt33.pem", - "rsa-pss-sha256-salt10.pem", - "ecdsa-secp384r1-sha256.pem", - "ecdsa-prime256v1-sha512.pem", + "rsa-pkcs1-sha1.pem", "rsa-pkcs1-sha256.pem", + "rsa2048-pkcs1-sha512.pem", "ecdsa-secp384r1-sha256.pem", + "ecdsa-prime256v1-sha512.pem", "rsa-pss-sha256.pem", + "ecdsa-secp384r1-sha256.pem", "ecdsa-prime256v1-sha512.pem", }; INSTANTIATE_TEST_SUITE_P(All,
diff --git a/net/cert/internal/verify_signed_data_unittest.cc b/net/cert/internal/verify_signed_data_unittest.cc index 39f3fafd..62bf85f1 100644 --- a/net/cert/internal/verify_signed_data_unittest.cc +++ b/net/cert/internal/verify_signed_data_unittest.cc
@@ -98,20 +98,12 @@ RunTestCase(SUCCESS, "ecdsa-prime256v1-sha512.pem"); } -TEST(VerifySignedDataTest, RsaPssSha1) { - RunTestCase(SUCCESS, "rsa-pss-sha1-salt20.pem"); -} - -TEST(VerifySignedDataTest, RsaPssSha256Mgf1Sha512Salt33) { - RunTestCase(SUCCESS, "rsa-pss-sha256-mgf1-sha512-salt33.pem"); -} - TEST(VerifySignedDataTest, RsaPssSha256) { - RunTestCase(SUCCESS, "rsa-pss-sha256-salt10.pem"); + RunTestCase(SUCCESS, "rsa-pss-sha256.pem"); } -TEST(VerifySignedDataTest, RsaPssSha1WrongSalt) { - RunTestCase(FAILURE, "rsa-pss-sha1-wrong-salt.pem"); +TEST(VerifySignedDataTest, RsaPssSha256WrongSalt) { + RunTestCase(FAILURE, "rsa-pss-sha256-wrong-salt.pem"); } TEST(VerifySignedDataTest, EcdsaSecp384r1Sha256CorruptedData) { @@ -162,28 +154,13 @@ RunTestCase(FAILURE, "rsa-pkcs1-sha1-key-params-absent.pem"); } -TEST(VerifySignedDataTest, RsaPssSha1Salt20UsingPssKeyNoParams) { - // We do not support RSA-PSS SPKIs. - RunTestCase(FAILURE, "rsa-pss-sha1-salt20-using-pss-key-no-params.pem"); -} - TEST(VerifySignedDataTest, RsaPkcs1Sha1UsingPssKeyNoParams) { RunTestCase(FAILURE, "rsa-pkcs1-sha1-using-pss-key-no-params.pem"); } -TEST(VerifySignedDataTest, RsaPssSha256Salt10UsingPssKeyWithParams) { +TEST(VerifySignedDataTest, RsaPssSha256UsingPssKeyWithParams) { // We do not support RSA-PSS SPKIs. - RunTestCase(FAILURE, "rsa-pss-sha256-salt10-using-pss-key-with-params.pem"); -} - -TEST(VerifySignedDataTest, RsaPssSha256Salt10UsingPssKeyWithWrongParams) { - RunTestCase(FAILURE, - "rsa-pss-sha256-salt10-using-pss-key-with-wrong-params.pem"); -} - -TEST(VerifySignedDataTest, RsaPssSha256Salt12UsingPssKeyWithNullParams) { - RunTestCase(FAILURE, - "rsa-pss-sha1-salt20-using-pss-key-with-null-params.pem"); + RunTestCase(FAILURE, "rsa-pss-sha256-using-pss-key-with-params.pem"); } TEST(VerifySignedDataTest, EcdsaPrime256v1Sha512SpkiParamsNull) {
diff --git a/net/data/verify_signed_data_unittest/rsa-pss-sha1-salt20-using-pss-key-no-params.pem b/net/data/verify_signed_data_unittest/rsa-pss-sha1-salt20-using-pss-key-no-params.pem deleted file mode 100644 index 74adc3eb..0000000 --- a/net/data/verify_signed_data_unittest/rsa-pss-sha1-salt20-using-pss-key-no-params.pem +++ /dev/null
@@ -1,38 +0,0 @@ -This is the same test as rsa-pss-sha1-salt20.pem, except the public key's -algorithm identifier has been changed from rsaEncryption (1.2.840.113549.1.1.1) -to rsaPss (1.2.840.113549.1.1.10). - - -$ openssl asn1parse -i < [PUBLIC KEY] - 0:d=0 hl=3 l= 157 cons: SEQUENCE - 3:d=1 hl=2 l= 11 cons: SEQUENCE - 5:d=2 hl=2 l= 9 prim: OBJECT :rsassaPss - 16:d=1 hl=3 l= 141 prim: BIT STRING ------BEGIN PUBLIC KEY----- -MIGdMAsGCSqGSIb3DQEBCgOBjQAwgYkCgYEApW5KDnAQF1iaUYfcfqhB0Vby7A42rVKkTf6x5h9 -62ZHYxRBW/+2xYrTA8oOhKoijlN/1JqtykcuzB86r/OCx39XNlQgJbVsri2311nHvY3fAkhyyPC -cKcOJZjm/4nRnxBazC0/DLNfKSgOE4a29kxO8i4eHyDQzoz/siSb2aITcCAwEAAQ== ------END PUBLIC KEY----- - -$ openssl asn1parse -i < [ALGORITHM] - 0:d=0 hl=2 l= 13 cons: SEQUENCE - 2:d=1 hl=2 l= 9 prim: OBJECT :rsassaPss - 13:d=1 hl=2 l= 0 cons: SEQUENCE ------BEGIN ALGORITHM----- -MA0GCSqGSIb3DQEBCjAA ------END ALGORITHM----- - ------BEGIN DATA----- -zch9oiPXht87ReC7vHITJtHuKvgGzDFUdcxvDZxm4bYjcdRc4jkuGskoRMMQEC8Vag2NUsH0xAu -jqmUJV4bLdpdXplY7qVj+0LzJhOi1F6PV9RWyO4pB50qoZ2k/kN+wYabobfqu5kRywA5fIJRXKc -vr538Gznjgj0CY+6QfnWGTwDF+i2DUtghKy0LSnjgIo7w3LYXjMRcPy/fMctC3HClmSLOk0Q9BY -pXQgHqmJcqydE/Z6o/SI8QlNwKYKL0WvgJUbxMP0uM7k20mduCK7RtzMYt1CgFn0A== ------END DATA----- - -$ openssl asn1parse -i < [SIGNATURE] - 0:d=0 hl=3 l= 129 prim: BIT STRING ------BEGIN SIGNATURE----- -A4GBAJB0MI+1mOlwGyKUOI5S+XH6rCtgpRRa8YXfUoe17SiH5Xzn/UTchjTkB8jg5DYLwibz7CJ -/nZ5UY46NMfUFEhXfbrucL5V5qndZijj5FLW5wb2DxOL584Kg0Ko1Qv/uZZhKYBvGnrKN6yfcoS -yCwtTD9mzVAPH/K5lNik4wy7M8 ------END SIGNATURE-----
diff --git a/net/data/verify_signed_data_unittest/rsa-pss-sha1-salt20-using-pss-key-with-null-params.pem b/net/data/verify_signed_data_unittest/rsa-pss-sha1-salt20-using-pss-key-with-null-params.pem deleted file mode 100644 index 42e9546a..0000000 --- a/net/data/verify_signed_data_unittest/rsa-pss-sha1-salt20-using-pss-key-with-null-params.pem +++ /dev/null
@@ -1,40 +0,0 @@ -This is the same test as rsa-pss-sha1-salt20.pem, except the public key's -algorithm identifier has been changed from rsaEncryption (1.2.840.113549.1.1.1) -to rsaPss (1.2.840.113549.1.1.10). Note that the PSS parameters have been -encoded as NULL which is incorrect. - - -$ openssl asn1parse -i < [PUBLIC KEY] - 0:d=0 hl=3 l= 159 cons: SEQUENCE - 3:d=1 hl=2 l= 13 cons: SEQUENCE - 5:d=2 hl=2 l= 9 prim: OBJECT :rsassaPss - 16:d=2 hl=2 l= 0 prim: NULL - 18:d=1 hl=3 l= 141 prim: BIT STRING ------BEGIN PUBLIC KEY----- -MIGfMA0GCSqGSIb3DQEBCgUAA4GNADCBiQKBgQClbkoOcBAXWJpRh9x+qEHRVvLsDjatUqRN/rH -mH3rZkdjFEFb/7bFitMDyg6EqiKOU3/Umq3KRy7MHzqv84LHf1c2VCAltWyuLbfXWce9jd8CSHL -I8Jwpw4lmOb/idGfEFrMLT8Ms18pKA4Thrb2TE7yLh4fINDOjP+yJJvZohNwIDAQAB ------END PUBLIC KEY----- - -$ openssl asn1parse -i < [ALGORITHM] - 0:d=0 hl=2 l= 13 cons: SEQUENCE - 2:d=1 hl=2 l= 9 prim: OBJECT :rsassaPss - 13:d=1 hl=2 l= 0 cons: SEQUENCE ------BEGIN ALGORITHM----- -MA0GCSqGSIb3DQEBCjAA ------END ALGORITHM----- - ------BEGIN DATA----- -zch9oiPXht87ReC7vHITJtHuKvgGzDFUdcxvDZxm4bYjcdRc4jkuGskoRMMQEC8Vag2NUsH0xAu -jqmUJV4bLdpdXplY7qVj+0LzJhOi1F6PV9RWyO4pB50qoZ2k/kN+wYabobfqu5kRywA5fIJRXKc -vr538Gznjgj0CY+6QfnWGTwDF+i2DUtghKy0LSnjgIo7w3LYXjMRcPy/fMctC3HClmSLOk0Q9BY -pXQgHqmJcqydE/Z6o/SI8QlNwKYKL0WvgJUbxMP0uM7k20mduCK7RtzMYt1CgFn0A== ------END DATA----- - -$ openssl asn1parse -i < [SIGNATURE] - 0:d=0 hl=3 l= 129 prim: BIT STRING ------BEGIN SIGNATURE----- -A4GBAJB0MI+1mOlwGyKUOI5S+XH6rCtgpRRa8YXfUoe17SiH5Xzn/UTchjTkB8jg5DYLwibz7CJ -/nZ5UY46NMfUFEhXfbrucL5V5qndZijj5FLW5wb2DxOL584Kg0Ko1Qv/uZZhKYBvGnrKN6yfcoS -yCwtTD9mzVAPH/K5lNik4wy7M8 ------END SIGNATURE-----
diff --git a/net/data/verify_signed_data_unittest/rsa-pss-sha1-salt20.pem b/net/data/verify_signed_data_unittest/rsa-pss-sha1-salt20.pem deleted file mode 100644 index 4f7a81c..0000000 --- a/net/data/verify_signed_data_unittest/rsa-pss-sha1-salt20.pem +++ /dev/null
@@ -1,43 +0,0 @@ -The key, message, and signature come from Example 1.1 of: -ftp://ftp.rsasecurity.com/pub/pkcs/pkcs-1/pkcs-1v2-1-vec.zip (pss-vect.txt) - -(The algorithm DER was synthesized to match, and the signature enclosed in a BIT STRING). - -It uses an RSA key with modulus length of 1024 bits, PSS padding, -SHA-1 as the digest, MGF1 with SHA-1, and salt length of 20. - - -$ openssl asn1parse -i < [PUBLIC KEY] - 0:d=0 hl=3 l= 159 cons: SEQUENCE - 3:d=1 hl=2 l= 13 cons: SEQUENCE - 5:d=2 hl=2 l= 9 prim: OBJECT :rsaEncryption - 16:d=2 hl=2 l= 0 prim: NULL - 18:d=1 hl=3 l= 141 prim: BIT STRING ------BEGIN PUBLIC KEY----- -MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQClbkoOcBAXWJpRh9x+qEHRVvLsDjatUqRN/rH -mH3rZkdjFEFb/7bFitMDyg6EqiKOU3/Umq3KRy7MHzqv84LHf1c2VCAltWyuLbfXWce9jd8CSHL -I8Jwpw4lmOb/idGfEFrMLT8Ms18pKA4Thrb2TE7yLh4fINDOjP+yJJvZohNwIDAQAB ------END PUBLIC KEY----- - -$ openssl asn1parse -i < [ALGORITHM] - 0:d=0 hl=2 l= 13 cons: SEQUENCE - 2:d=1 hl=2 l= 9 prim: OBJECT :rsassaPss - 13:d=1 hl=2 l= 0 cons: SEQUENCE ------BEGIN ALGORITHM----- -MA0GCSqGSIb3DQEBCjAA ------END ALGORITHM----- - ------BEGIN DATA----- -zch9oiPXht87ReC7vHITJtHuKvgGzDFUdcxvDZxm4bYjcdRc4jkuGskoRMMQEC8Vag2NUsH0xAu -jqmUJV4bLdpdXplY7qVj+0LzJhOi1F6PV9RWyO4pB50qoZ2k/kN+wYabobfqu5kRywA5fIJRXKc -vr538Gznjgj0CY+6QfnWGTwDF+i2DUtghKy0LSnjgIo7w3LYXjMRcPy/fMctC3HClmSLOk0Q9BY -pXQgHqmJcqydE/Z6o/SI8QlNwKYKL0WvgJUbxMP0uM7k20mduCK7RtzMYt1CgFn0A== ------END DATA----- - -$ openssl asn1parse -i < [SIGNATURE] - 0:d=0 hl=3 l= 129 prim: BIT STRING ------BEGIN SIGNATURE----- -A4GBAJB0MI+1mOlwGyKUOI5S+XH6rCtgpRRa8YXfUoe17SiH5Xzn/UTchjTkB8jg5DYLwibz7CJ -/nZ5UY46NMfUFEhXfbrucL5V5qndZijj5FLW5wb2DxOL584Kg0Ko1Qv/uZZhKYBvGnrKN6yfcoS -yCwtTD9mzVAPH/K5lNik4wy7M8 ------END SIGNATURE-----
diff --git a/net/data/verify_signed_data_unittest/rsa-pss-sha256-mgf1-sha512-salt33.pem b/net/data/verify_signed_data_unittest/rsa-pss-sha256-mgf1-sha512-salt33.pem deleted file mode 100644 index b322226..0000000 --- a/net/data/verify_signed_data_unittest/rsa-pss-sha256-mgf1-sha512-salt33.pem +++ /dev/null
@@ -1,57 +0,0 @@ -This test exercises using a different hash function parameter to the mask gen -function (SHA-256 for the hash, but SHA-512 for the MGF1 hash). - -This test data was constructed manually by calling signing functions from -OpenSSL code. - -It constructs an RSASSA-PSS signature using: - * Key with modulus 1024 bit - * Salt length 33 bytes - * Digest function of SHA-256 - * Mask gen function of MGF1 with SHA-512 - - -$ openssl asn1parse -i < [PUBLIC KEY] - 0:d=0 hl=3 l= 159 cons: SEQUENCE - 3:d=1 hl=2 l= 13 cons: SEQUENCE - 5:d=2 hl=2 l= 9 prim: OBJECT :rsaEncryption - 16:d=2 hl=2 l= 0 prim: NULL - 18:d=1 hl=3 l= 141 prim: BIT STRING ------BEGIN PUBLIC KEY----- -MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQClbkoOcBAXWJpRh9x+qEHRVvLsDjatUqRN/rH -mH3rZkdjFEFb/7bFitMDyg6EqiKOU3/Umq3KRy7MHzqv84LHf1c2VCAltWyuLbfXWce9jd8CSHL -I8Jwpw4lmOb/idGfEFrMLT8Ms18pKA4Thrb2TE7yLh4fINDOjP+yJJvZohNwIDAQAB ------END PUBLIC KEY----- - -$ openssl asn1parse -i < [ALGORITHM] - 0:d=0 hl=2 l= 65 cons: SEQUENCE - 2:d=1 hl=2 l= 9 prim: OBJECT :rsassaPss - 13:d=1 hl=2 l= 52 cons: SEQUENCE - 15:d=2 hl=2 l= 15 cons: cont [ 0 ] - 17:d=3 hl=2 l= 13 cons: SEQUENCE - 19:d=4 hl=2 l= 9 prim: OBJECT :sha256 - 30:d=4 hl=2 l= 0 prim: NULL - 32:d=2 hl=2 l= 28 cons: cont [ 1 ] - 34:d=3 hl=2 l= 26 cons: SEQUENCE - 36:d=4 hl=2 l= 9 prim: OBJECT :mgf1 - 47:d=4 hl=2 l= 13 cons: SEQUENCE - 49:d=5 hl=2 l= 9 prim: OBJECT :sha512 - 60:d=5 hl=2 l= 0 prim: NULL - 62:d=2 hl=2 l= 3 cons: cont [ 2 ] - 64:d=3 hl=2 l= 1 prim: INTEGER :21 ------BEGIN ALGORITHM----- -MEEGCSqGSIb3DQEBCjA0oA8wDQYJYIZIAWUDBAIBBQChHDAaBgkqhkiG9w0BAQgwDQYJYIZIAWU -DBAIDBQCiAwIBIQ== ------END ALGORITHM----- - ------BEGIN DATA----- -VGVzdCBtZXNzYWdlIHRvIGJlIHNpZ25lZC4uLg== ------END DATA----- - -$ openssl asn1parse -i < [SIGNATURE] - 0:d=0 hl=3 l= 129 prim: BIT STRING ------BEGIN SIGNATURE----- -A4GBAFob0HSC5uuTqKu4J/lj+5bDa+Hhij4H3klWnvt6Yc+wwPza7/UC4lgGGyvZqD32RUEdt7v -Z14qqYNk53b5aj4C2gBMvLzV7Pay4mmQM4DSWa5JHMxTILqE3DDqihrbMcBw2q3XAsLcjeqLWQ9 -yp8tfnV21h98qsCLtErrxZWHRr ------END SIGNATURE-----
diff --git a/net/data/verify_signed_data_unittest/rsa-pss-sha256-salt10-using-pss-key-with-params.pem b/net/data/verify_signed_data_unittest/rsa-pss-sha256-salt10-using-pss-key-with-params.pem deleted file mode 100644 index 62da07a..0000000 --- a/net/data/verify_signed_data_unittest/rsa-pss-sha256-salt10-using-pss-key-with-params.pem +++ /dev/null
@@ -1,64 +0,0 @@ -This is the same test as rsa-pss-sha256-salt10.pem except instead of specifying -the SPKI using rsaEncryption it is specified using rsaPss along with -parameters that match those of the signature algorithm. - - -$ openssl asn1parse -i < [PUBLIC KEY] - 0:d=0 hl=3 l= 209 cons: SEQUENCE - 3:d=1 hl=2 l= 65 cons: SEQUENCE - 5:d=2 hl=2 l= 9 prim: OBJECT :rsassaPss - 16:d=2 hl=2 l= 52 cons: SEQUENCE - 18:d=3 hl=2 l= 15 cons: cont [ 0 ] - 20:d=4 hl=2 l= 13 cons: SEQUENCE - 22:d=5 hl=2 l= 9 prim: OBJECT :sha256 - 33:d=5 hl=2 l= 0 prim: NULL - 35:d=3 hl=2 l= 28 cons: cont [ 1 ] - 37:d=4 hl=2 l= 26 cons: SEQUENCE - 39:d=5 hl=2 l= 9 prim: OBJECT :mgf1 - 50:d=5 hl=2 l= 13 cons: SEQUENCE - 52:d=6 hl=2 l= 9 prim: OBJECT :sha256 - 63:d=6 hl=2 l= 0 prim: NULL - 65:d=3 hl=2 l= 3 cons: cont [ 2 ] - 67:d=4 hl=2 l= 1 prim: INTEGER :0A - 70:d=1 hl=3 l= 139 prim: BIT STRING ------BEGIN PUBLIC KEY----- -MIHRMEEGCSqGSIb3DQEBCjA0oA8wDQYJYIZIAWUDBAIBBQChHDAaBgkqhkiG9w0BAQgwDQYJYIZ -IAWUDBAIBBQCiAwIBCgOBiwAwgYcCgYEAvkmbXn8GyD+gKT4xRlyOtrWK+SC65Sp7W5v+t6py2x -JkES6z/UMdMaKn5QlBVmkpSUoOiR7VYTkYtLUbDR+5d4Oyas99DzhM+zX00oJPXdOAYjomvxgLY -5YcYZ3NsgyuQG8i9uJ2yAo3JZSQz+tywacahPGEbTMId7o+MQHsnHsCARE= ------END PUBLIC KEY----- - -$ openssl asn1parse -i < [ALGORITHM] - 0:d=0 hl=2 l= 65 cons: SEQUENCE - 2:d=1 hl=2 l= 9 prim: OBJECT :rsassaPss - 13:d=1 hl=2 l= 52 cons: SEQUENCE - 15:d=2 hl=2 l= 15 cons: cont [ 0 ] - 17:d=3 hl=2 l= 13 cons: SEQUENCE - 19:d=4 hl=2 l= 9 prim: OBJECT :sha256 - 30:d=4 hl=2 l= 0 prim: NULL - 32:d=2 hl=2 l= 28 cons: cont [ 1 ] - 34:d=3 hl=2 l= 26 cons: SEQUENCE - 36:d=4 hl=2 l= 9 prim: OBJECT :mgf1 - 47:d=4 hl=2 l= 13 cons: SEQUENCE - 49:d=5 hl=2 l= 9 prim: OBJECT :sha256 - 60:d=5 hl=2 l= 0 prim: NULL - 62:d=2 hl=2 l= 3 cons: cont [ 2 ] - 64:d=3 hl=2 l= 1 prim: INTEGER :0A ------BEGIN ALGORITHM----- -MEEGCSqGSIb3DQEBCjA0oA8wDQYJYIZIAWUDBAIBBQChHDAaBgkqhkiG9w0BAQgwDQYJYIZIAWU -DBAIBBQCiAwIBCg== ------END ALGORITHM----- - ------BEGIN DATA----- -x/UnD8pyX5vRn1GajXzKPMXAeQJAKfO65RD5sCFA/iOJCOT2wY8HqJxofIaEZpsfHbK6+SUaPIK -frMtJMIThbsnijViGgHSl1iIWZ91uUo0W/iyfPbTPr2xNzoyEOa84zqqqnOLsrnvI9KWlXjv5bf -nNV1xPnLMnlRuM3+QIcWg= ------END DATA----- - -$ openssl asn1parse -i < [SIGNATURE] - 0:d=0 hl=3 l= 129 prim: BIT STRING ------BEGIN SIGNATURE----- -A4GBABHhafL9QLB2Qbl2iiqxmWX7bCfxD88DI/zG0S608cBrMw3aoepQRAevop3p6+A3T+nR59D -/vV/Bzzo0RuQUVBXSqyT3ibNGTFxDola7wdaSz38EgB2sW7QBpKA6t9VyioYMGeGk3Hl8pULIID -zsLmAesMUfVn8u2gIrC5693u76 ------END SIGNATURE-----
diff --git a/net/data/verify_signed_data_unittest/rsa-pss-sha256-salt10-using-pss-key-with-wrong-params.pem b/net/data/verify_signed_data_unittest/rsa-pss-sha256-salt10-using-pss-key-with-wrong-params.pem deleted file mode 100644 index 9b2b67950..0000000 --- a/net/data/verify_signed_data_unittest/rsa-pss-sha256-salt10-using-pss-key-with-wrong-params.pem +++ /dev/null
@@ -1,64 +0,0 @@ -This is the same test as rsa-pss-sha256-salt10-using-pss-key-with-params.pem -except the hash in the PSS key's parameters has been changed from SHA-256 to -SHA-384. - - -$ openssl asn1parse -i < [PUBLIC KEY] - 0:d=0 hl=3 l= 209 cons: SEQUENCE - 3:d=1 hl=2 l= 65 cons: SEQUENCE - 5:d=2 hl=2 l= 9 prim: OBJECT :rsassaPss - 16:d=2 hl=2 l= 52 cons: SEQUENCE - 18:d=3 hl=2 l= 15 cons: cont [ 0 ] - 20:d=4 hl=2 l= 13 cons: SEQUENCE - 22:d=5 hl=2 l= 9 prim: OBJECT :sha384 - 33:d=5 hl=2 l= 0 prim: NULL - 35:d=3 hl=2 l= 28 cons: cont [ 1 ] - 37:d=4 hl=2 l= 26 cons: SEQUENCE - 39:d=5 hl=2 l= 9 prim: OBJECT :mgf1 - 50:d=5 hl=2 l= 13 cons: SEQUENCE - 52:d=6 hl=2 l= 9 prim: OBJECT :sha256 - 63:d=6 hl=2 l= 0 prim: NULL - 65:d=3 hl=2 l= 3 cons: cont [ 2 ] - 67:d=4 hl=2 l= 1 prim: INTEGER :0A - 70:d=1 hl=3 l= 139 prim: BIT STRING ------BEGIN PUBLIC KEY----- -MIHRMEEGCSqGSIb3DQEBCjA0oA8wDQYJYIZIAWUDBAICBQChHDAaBgkqhkiG9w0BAQgwDQYJYIZ -IAWUDBAIBBQCiAwIBCgOBiwAwgYcCgYEAvkmbXn8GyD+gKT4xRlyOtrWK+SC65Sp7W5v+t6py2x -JkES6z/UMdMaKn5QlBVmkpSUoOiR7VYTkYtLUbDR+5d4Oyas99DzhM+zX00oJPXdOAYjomvxgLY -5YcYZ3NsgyuQG8i9uJ2yAo3JZSQz+tywacahPGEbTMId7o+MQHsnHsCARE= ------END PUBLIC KEY----- - -$ openssl asn1parse -i < [ALGORITHM] - 0:d=0 hl=2 l= 65 cons: SEQUENCE - 2:d=1 hl=2 l= 9 prim: OBJECT :rsassaPss - 13:d=1 hl=2 l= 52 cons: SEQUENCE - 15:d=2 hl=2 l= 15 cons: cont [ 0 ] - 17:d=3 hl=2 l= 13 cons: SEQUENCE - 19:d=4 hl=2 l= 9 prim: OBJECT :sha256 - 30:d=4 hl=2 l= 0 prim: NULL - 32:d=2 hl=2 l= 28 cons: cont [ 1 ] - 34:d=3 hl=2 l= 26 cons: SEQUENCE - 36:d=4 hl=2 l= 9 prim: OBJECT :mgf1 - 47:d=4 hl=2 l= 13 cons: SEQUENCE - 49:d=5 hl=2 l= 9 prim: OBJECT :sha256 - 60:d=5 hl=2 l= 0 prim: NULL - 62:d=2 hl=2 l= 3 cons: cont [ 2 ] - 64:d=3 hl=2 l= 1 prim: INTEGER :0A ------BEGIN ALGORITHM----- -MEEGCSqGSIb3DQEBCjA0oA8wDQYJYIZIAWUDBAIBBQChHDAaBgkqhkiG9w0BAQgwDQYJYIZIAWU -DBAIBBQCiAwIBCg== ------END ALGORITHM----- - ------BEGIN DATA----- -x/UnD8pyX5vRn1GajXzKPMXAeQJAKfO65RD5sCFA/iOJCOT2wY8HqJxofIaEZpsfHbK6+SUaPIK -frMtJMIThbsnijViGgHSl1iIWZ91uUo0W/iyfPbTPr2xNzoyEOa84zqqqnOLsrnvI9KWlXjv5bf -nNV1xPnLMnlRuM3+QIcWg= ------END DATA----- - -$ openssl asn1parse -i < [SIGNATURE] - 0:d=0 hl=3 l= 129 prim: BIT STRING ------BEGIN SIGNATURE----- -A4GBABHhafL9QLB2Qbl2iiqxmWX7bCfxD88DI/zG0S608cBrMw3aoepQRAevop3p6+A3T+nR59D -/vV/Bzzo0RuQUVBXSqyT3ibNGTFxDola7wdaSz38EgB2sW7QBpKA6t9VyioYMGeGk3Hl8pULIID -zsLmAesMUfVn8u2gIrC5693u76 ------END SIGNATURE-----
diff --git a/net/data/verify_signed_data_unittest/rsa-pss-sha256-salt10.pem b/net/data/verify_signed_data_unittest/rsa-pss-sha256-salt10.pem deleted file mode 100644 index 72d729a..0000000 --- a/net/data/verify_signed_data_unittest/rsa-pss-sha256-salt10.pem +++ /dev/null
@@ -1,55 +0,0 @@ -The key, message, and signature come from: -http://csrc.nist.gov/groups/STM/cavp/documents/dss/186-2rsatestvectors.zip (SigVerPSS_186-3.rsp) - -(The algorithm DER was synthesized to match, and the signature wrapped in a BIT STRING). - -It uses an RSA key with modulus length of 1024 bits, PSS padding, -SHA-256 as the digest, MGF1 with SHA-256, and salt length of 10. - - -$ openssl asn1parse -i < [PUBLIC KEY] - 0:d=0 hl=3 l= 157 cons: SEQUENCE - 3:d=1 hl=2 l= 13 cons: SEQUENCE - 5:d=2 hl=2 l= 9 prim: OBJECT :rsaEncryption - 16:d=2 hl=2 l= 0 prim: NULL - 18:d=1 hl=3 l= 139 prim: BIT STRING ------BEGIN PUBLIC KEY----- -MIGdMA0GCSqGSIb3DQEBAQUAA4GLADCBhwKBgQC+SZtefwbIP6ApPjFGXI62tYr5ILrlKntbm/6 -3qnLbEmQRLrP9Qx0xoqflCUFWaSlJSg6JHtVhORi0tRsNH7l3g7Jqz30POEz7NfTSgk9d04BiOi -a/GAtjlhxhnc2yDK5AbyL24nbICjcllJDP63LBpxqE8YRtMwh3uj4xAeycewIBEQ== ------END PUBLIC KEY----- - -$ openssl asn1parse -i < [ALGORITHM] - 0:d=0 hl=2 l= 65 cons: SEQUENCE - 2:d=1 hl=2 l= 9 prim: OBJECT :rsassaPss - 13:d=1 hl=2 l= 52 cons: SEQUENCE - 15:d=2 hl=2 l= 15 cons: cont [ 0 ] - 17:d=3 hl=2 l= 13 cons: SEQUENCE - 19:d=4 hl=2 l= 9 prim: OBJECT :sha256 - 30:d=4 hl=2 l= 0 prim: NULL - 32:d=2 hl=2 l= 28 cons: cont [ 1 ] - 34:d=3 hl=2 l= 26 cons: SEQUENCE - 36:d=4 hl=2 l= 9 prim: OBJECT :mgf1 - 47:d=4 hl=2 l= 13 cons: SEQUENCE - 49:d=5 hl=2 l= 9 prim: OBJECT :sha256 - 60:d=5 hl=2 l= 0 prim: NULL - 62:d=2 hl=2 l= 3 cons: cont [ 2 ] - 64:d=3 hl=2 l= 1 prim: INTEGER :0A ------BEGIN ALGORITHM----- -MEEGCSqGSIb3DQEBCjA0oA8wDQYJYIZIAWUDBAIBBQChHDAaBgkqhkiG9w0BAQgwDQYJYIZIAWU -DBAIBBQCiAwIBCg== ------END ALGORITHM----- - ------BEGIN DATA----- -x/UnD8pyX5vRn1GajXzKPMXAeQJAKfO65RD5sCFA/iOJCOT2wY8HqJxofIaEZpsfHbK6+SUaPIK -frMtJMIThbsnijViGgHSl1iIWZ91uUo0W/iyfPbTPr2xNzoyEOa84zqqqnOLsrnvI9KWlXjv5bf -nNV1xPnLMnlRuM3+QIcWg= ------END DATA----- - -$ openssl asn1parse -i < [SIGNATURE] - 0:d=0 hl=3 l= 129 prim: BIT STRING ------BEGIN SIGNATURE----- -A4GBABHhafL9QLB2Qbl2iiqxmWX7bCfxD88DI/zG0S608cBrMw3aoepQRAevop3p6+A3T+nR59D -/vV/Bzzo0RuQUVBXSqyT3ibNGTFxDola7wdaSz38EgB2sW7QBpKA6t9VyioYMGeGk3Hl8pULIID -zsLmAesMUfVn8u2gIrC5693u76 ------END SIGNATURE-----
diff --git a/net/data/verify_signed_data_unittest/rsa-pss-sha256-using-pss-key-with-params.pem b/net/data/verify_signed_data_unittest/rsa-pss-sha256-using-pss-key-with-params.pem new file mode 100644 index 0000000..4adbdecc --- /dev/null +++ b/net/data/verify_signed_data_unittest/rsa-pss-sha256-using-pss-key-with-params.pem
@@ -0,0 +1,71 @@ +This is the same test as rsa-pss-sha256.pem except instead of specifying +the SPKI using rsaEncryption it is specified using rsaPss along with +parameters that match those of the signature algorithm. + + +$ openssl asn1parse -i < [PUBLIC KEY] + 0:d=0 hl=4 l= 342 cons: SEQUENCE + 4:d=1 hl=2 l= 65 cons: SEQUENCE + 6:d=2 hl=2 l= 9 prim: OBJECT :rsassaPss + 17:d=2 hl=2 l= 52 cons: SEQUENCE + 19:d=3 hl=2 l= 15 cons: cont [ 0 ] + 21:d=4 hl=2 l= 13 cons: SEQUENCE + 23:d=5 hl=2 l= 9 prim: OBJECT :sha256 + 34:d=5 hl=2 l= 0 prim: NULL + 36:d=3 hl=2 l= 28 cons: cont [ 1 ] + 38:d=4 hl=2 l= 26 cons: SEQUENCE + 40:d=5 hl=2 l= 9 prim: OBJECT :mgf1 + 51:d=5 hl=2 l= 13 cons: SEQUENCE + 53:d=6 hl=2 l= 9 prim: OBJECT :sha256 + 64:d=6 hl=2 l= 0 prim: NULL + 66:d=3 hl=2 l= 3 cons: cont [ 2 ] + 68:d=4 hl=2 l= 1 prim: INTEGER :20 + 71:d=1 hl=4 l= 271 prim: BIT STRING +-----BEGIN PUBLIC KEY----- +MIIBVjBBBgkqhkiG9w0BAQowNKAPMA0GCWCGSAFlAwQCAQUAoRwwGgYJKoZIhvcN +AQEIMA0GCWCGSAFlAwQCAQUAogMCASADggEPADCCAQoCggEBAJ+eocEuecvSRuYF +5E0C15v0OB0iXT/5BAoM7TDELaoIr/kHS9CeTO20DW1Cu2YWbeaREuU9B4yXCBDQ +b4Vxc1Gd6wTjKeMhEhS1qEi9Kri9AwGkV/2bmak/jsOiz3ZMJb9SaSodN8pasQhm +8NWyBSBLBa6ekA53Uj1SNYn3dkH2Hvn3UULhfHpmhrudDikUoM4kAedCRyg9M0bI +dXIFHEE8hlIhY9p3RV8NQD88pVNvqLmLq5jd2Qq73D9if6oEHQMw2EUP26v7+yzW +EHPhrnfhCMxN/vbKcm51kYtmi65xsMAQmbP26nOusGitKcx/M/5g8GwdmUiGpegE +RdIllF0CAwEAAQ== +-----END PUBLIC KEY----- + +$ openssl asn1parse -i < [ALGORITHM] + 0:d=0 hl=2 l= 65 cons: SEQUENCE + 2:d=1 hl=2 l= 9 prim: OBJECT :rsassaPss + 13:d=1 hl=2 l= 52 cons: SEQUENCE + 15:d=2 hl=2 l= 15 cons: cont [ 0 ] + 17:d=3 hl=2 l= 13 cons: SEQUENCE + 19:d=4 hl=2 l= 9 prim: OBJECT :sha256 + 30:d=4 hl=2 l= 0 prim: NULL + 32:d=2 hl=2 l= 28 cons: cont [ 1 ] + 34:d=3 hl=2 l= 26 cons: SEQUENCE + 36:d=4 hl=2 l= 9 prim: OBJECT :mgf1 + 47:d=4 hl=2 l= 13 cons: SEQUENCE + 49:d=5 hl=2 l= 9 prim: OBJECT :sha256 + 60:d=5 hl=2 l= 0 prim: NULL + 62:d=2 hl=2 l= 3 cons: cont [ 2 ] + 64:d=3 hl=2 l= 1 prim: INTEGER :20 +-----BEGIN ALGORITHM----- +MEEGCSqGSIb3DQEBCjA0oA8wDQYJYIZIAWUDBAIBBQChHDAaBgkqhkiG9w0BAQgw +DQYJYIZIAWUDBAIBBQCiAwIBIA== +-----END ALGORITHM----- + +-----BEGIN DATA----- +x/UnD8pyX5vRn1GajXzKPMXAeQJAKfO65RD5sCFA/iOJCOT2wY8HqJxofIaEZpsfHbK6+SUaPIK +frMtJMIThbsnijViGgHSl1iIWZ91uUo0W/iyfPbTPr2xNzoyEOa84zqqqnOLsrnvI9KWlXjv5bf +nNV1xPnLMnlRuM3+QIcWg= +-----END DATA----- + +$ openssl asn1parse -i < [SIGNATURE] + 0:d=0 hl=4 l= 257 prim: BIT STRING +-----BEGIN SIGNATURE----- +A4IBAQAhgPL8PV86dM9W4p1s7IWu8+9oXpPnFgutfKffNrPRny+7zUmJFER/JUDB +7gnb4qiDRqKftRIpizyrZb0M4Vrhq1CyINHM1anqinZESRy8npVvhrYv4QiHZnYX +vXtDjgBg3Rw2DufTOKgxs+nX8a050aHsuMulTRCwR6NuHkChJlJfg6p0b1losgcL +jKlu7EqTUUkY7Mt0WyCobxIKGbgrSVJsjV8La6rPh3LpA3d9i0Ik1HkyM1w+7utn +h2eT/FKO8W1BtB8haiyuhatuZ1c/2uttLBSZa8hK/2W4YuomUEoWz8JIP9xXQkoq +u0P2zB7MXW5jPJwpUX0fKXqFNSry +-----END SIGNATURE-----
diff --git a/net/data/verify_signed_data_unittest/rsa-pss-sha256-wrong-salt.pem b/net/data/verify_signed_data_unittest/rsa-pss-sha256-wrong-salt.pem new file mode 100644 index 0000000..6b641de --- /dev/null +++ b/net/data/verify_signed_data_unittest/rsa-pss-sha256-wrong-salt.pem
@@ -0,0 +1,61 @@ +This is the same as rsa-pss-sha256.pem, except the signature was generated +with a salt length of 33 instead of 32, while the algorithm still reports +the standard value of 32. + +The public key in SPKI form: +$ openssl pkey -in key.pem -pubout +-----BEGIN PUBLIC KEY----- +MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAn56hwS55y9JG5gXkTQLX +m/Q4HSJdP/kECgztMMQtqgiv+QdL0J5M7bQNbUK7ZhZt5pES5T0HjJcIENBvhXFz +UZ3rBOMp4yESFLWoSL0quL0DAaRX/ZuZqT+Ow6LPdkwlv1JpKh03ylqxCGbw1bIF +IEsFrp6QDndSPVI1ifd2QfYe+fdRQuF8emaGu50OKRSgziQB50JHKD0zRsh1cgUc +QTyGUiFj2ndFXw1APzylU2+ouYurmN3ZCrvcP2J/qgQdAzDYRQ/bq/v7LNYQc+Gu +d+EIzE3+9spybnWRi2aLrnGwwBCZs/bqc66waK0pzH8z/mDwbB2ZSIal6ARF0iWU +XQIDAQAB +-----END PUBLIC KEY----- + +The signing algorithm: + +$ openssl asn1parse -i < [ALGORITHM] + 0:d=0 hl=2 l= 65 cons: SEQUENCE + 2:d=1 hl=2 l= 9 prim: OBJECT :rsassaPss + 13:d=1 hl=2 l= 52 cons: SEQUENCE + 15:d=2 hl=2 l= 15 cons: cont [ 0 ] + 17:d=3 hl=2 l= 13 cons: SEQUENCE + 19:d=4 hl=2 l= 9 prim: OBJECT :sha256 + 30:d=4 hl=2 l= 0 prim: NULL + 32:d=2 hl=2 l= 28 cons: cont [ 1 ] + 34:d=3 hl=2 l= 26 cons: SEQUENCE + 36:d=4 hl=2 l= 9 prim: OBJECT :mgf1 + 47:d=4 hl=2 l= 13 cons: SEQUENCE + 49:d=5 hl=2 l= 9 prim: OBJECT :sha256 + 60:d=5 hl=2 l= 0 prim: NULL + 62:d=2 hl=2 l= 3 cons: cont [ 2 ] + 64:d=3 hl=2 l= 1 prim: INTEGER :20 +-----BEGIN ALGORITHM----- +MEEGCSqGSIb3DQEBCjA0oA8wDQYJYIZIAWUDBAIBBQChHDAaBgkqhkiG9w0BAQgw +DQYJYIZIAWUDBAIBBQCiAwIBIA== +-----END ALGORITHM----- + +-----BEGIN DATA----- +x/UnD8pyX5vRn1GajXzKPMXAeQJAKfO65RD5sCFA/iOJCOT2wY8HqJxofIaEZpsfHbK6+SUaPIK +frMtJMIThbsnijViGgHSl1iIWZ91uUo0W/iyfPbTPr2xNzoyEOa84zqqqnOLsrnvI9KWlXjv5bf +nNV1xPnLMnlRuM3+QIcWg= +-----END DATA----- + +The signature was generated with: +$ openssl dgst -sign key.pem -sha256 -sigopt rsa_padding_mode:pss \ + -sigopt rsa_pss_saltlen:33 < [DATA] > [SIGNATURE] + +Then the signature was wrapped in a BIT STRING. + +$ openssl asn1parse -i < [SIGNATURE] + 0:d=0 hl=4 l= 257 prim: BIT STRING +-----BEGIN SIGNATURE----- +A4IBAQB4R+AnrWUH+TvyBU3yR1GP1ghodbwUZdyJfG1rqzEqpY/MJtsd1YM9bC9q +FqHao1+idLj+WSl91hbtZAEtNb0TDdXkO+iattPYsTBAeLm70A7DbqwM7s/1rTp0 +KJ4QFOJe05wYO+p/zHZ4Oiyhx2bCx+8J1FLlYEtwR0NhwRwPflVO7TNZC1l40iqk +iyxsJrXsibuFnFnBe6BytBdlKF/CHFuve6z5aLauuuQtA17I6YRZ4cdKceD9I3Hs +NVhe+V1V10YoMDx3AywQTnaM+Au+VoxHU6oh9KP5lrrzBhPZPDtzfF++4Ag2Vd2O +GFvPoL8xTp3S8QG5iVs90BkW8GvL +-----END SIGNATURE-----
diff --git a/net/data/verify_signed_data_unittest/rsa-pss-sha256.pem b/net/data/verify_signed_data_unittest/rsa-pss-sha256.pem new file mode 100644 index 0000000..a01984bc --- /dev/null +++ b/net/data/verify_signed_data_unittest/rsa-pss-sha256.pem
@@ -0,0 +1,92 @@ +The key and signature were generated with OpenSSL. +It uses an RSA key with modulus length of 1024 bits, PSS padding, +SHA-256 as the digest, MGF1 with SHA-256, and salt length of 10. + +The key was generated with: + +$ openssl genrsa -out key.pem 2048 +-----BEGIN RSA PRIVATE KEY----- +MIIEpAIBAAKCAQEAn56hwS55y9JG5gXkTQLXm/Q4HSJdP/kECgztMMQtqgiv+QdL +0J5M7bQNbUK7ZhZt5pES5T0HjJcIENBvhXFzUZ3rBOMp4yESFLWoSL0quL0DAaRX +/ZuZqT+Ow6LPdkwlv1JpKh03ylqxCGbw1bIFIEsFrp6QDndSPVI1ifd2QfYe+fdR +QuF8emaGu50OKRSgziQB50JHKD0zRsh1cgUcQTyGUiFj2ndFXw1APzylU2+ouYur +mN3ZCrvcP2J/qgQdAzDYRQ/bq/v7LNYQc+Gud+EIzE3+9spybnWRi2aLrnGwwBCZ +s/bqc66waK0pzH8z/mDwbB2ZSIal6ARF0iWUXQIDAQABAoIBAHKu+AsjiFDgSR5V +111ZkG41vud33EXtdXB/LyAdo62KRl0HV/qQ8jbLaeY5zwkfTmEdlNTtz3G8xgfG +qonXJILckpJVYLAW/7WvezSf7YUEEJfqa2oElRfcWYfIf4TAW1KmNHcUvRP/qzid +NaZkHHjCTlfTBy/NnWH/ogX5rZbfy1mqfBkGCsBAKrIp8OxIdc2gvy7fzjmOc9Bj +wSIswqGWu5YCeJ5S6tQ3PCYwb9A/gJS4/DMz2Mq0wj1r0dn9xVtMcQZRrG3JsvHt +Q4ImTXE3gTDS1gw8a0iB1UHlnOuq19O74ImupndpbpS2AZ3r8/GB2hGc+p3RXV+D +2MdlVEUCgYEA0h1yM5qJcAQQH5xFXK/eFF3DHeQNl10ugqiq8dF1+uFVodNhu/ZI +OGddhgxSrYDy7ryoZLGnZxcgrdxsfgfIHFOIp8sn9DO6wxfNQEBMGrWAXlgM+0js +EZ5FG/hHsZycM5/LXAncXmPDacu5AJ0UFv84iFahSsmaPR/FB3SdiO8CgYEAwno5 +eywaSdo2AWu/QeCtfN+Db9CmStjhHJY5NidppoeLcKwO5Jlh1DqbYvE38+SmUCeq +nZoXmj2EBsHU8xHY7U8pS0JHW8Uj+Ii6KxzMx1cdyUXy9bCmVVj4wtfaQIHdYruj +T7eD31NZ/sQHplsVT7EdTprVFPys7GPgy321/3MCgYEAxS25BFBb9fD6KJAAT7ED +Gd27w4tGbeuWQCuE8JX+v8dDEzBJoZjHwZbPH4Lk+8ntMLl+1bAaRxZfJomajtNC +qcKCleSCxBrfg0IM7eTpBo+Zve+njxGp6Aa9GDhxH26274Nf1imy0imRMvFp1feS +6Nnt9ZRGnOaAhigQQKThSaUCgYBVS9Y6N7Wv/o0BQoi4FBsDUeUL/a9x1H2nVBvz +rIWiDIEUAeLmUH+f3bSZSMMJrZdkQIGMbjE77Q8jB5Cmq4VBUB8EayVxEp4cO5ur +nQ4TwBnIVW2iZMAPXt58Vr/a2xqGW1XdeNfV83DdVI0mYXyPX1dDSpV6hvgxFf1a +QuC4EQKBgQCtapB1LkCJ0ro6BDK1uxyMd4/uJWR2Ke6vZD1P+MgUDCbIwBCecick +WUzTx9Uc8ZfRH8s3JAMz6f8XpJoxvwFVpDqOB5X1y/8TNo5kEooQB1BnwLPL169O +Pqi9SE06v7syvuXBbFRQFOxmGvK7jYi0G1VGuc7OcjDw9SRGENtTKQ== +-----END RSA PRIVATE KEY----- + +The public key in SPKI form: +$ openssl pkey -in key.pem -pubout +-----BEGIN PUBLIC KEY----- +MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAn56hwS55y9JG5gXkTQLX +m/Q4HSJdP/kECgztMMQtqgiv+QdL0J5M7bQNbUK7ZhZt5pES5T0HjJcIENBvhXFz +UZ3rBOMp4yESFLWoSL0quL0DAaRX/ZuZqT+Ow6LPdkwlv1JpKh03ylqxCGbw1bIF +IEsFrp6QDndSPVI1ifd2QfYe+fdRQuF8emaGu50OKRSgziQB50JHKD0zRsh1cgUc +QTyGUiFj2ndFXw1APzylU2+ouYurmN3ZCrvcP2J/qgQdAzDYRQ/bq/v7LNYQc+Gu +d+EIzE3+9spybnWRi2aLrnGwwBCZs/bqc66waK0pzH8z/mDwbB2ZSIal6ARF0iWU +XQIDAQAB +-----END PUBLIC KEY----- + +The signing algorithm: + +$ openssl asn1parse -i < [ALGORITHM] + 0:d=0 hl=2 l= 65 cons: SEQUENCE + 2:d=1 hl=2 l= 9 prim: OBJECT :rsassaPss + 13:d=1 hl=2 l= 52 cons: SEQUENCE + 15:d=2 hl=2 l= 15 cons: cont [ 0 ] + 17:d=3 hl=2 l= 13 cons: SEQUENCE + 19:d=4 hl=2 l= 9 prim: OBJECT :sha256 + 30:d=4 hl=2 l= 0 prim: NULL + 32:d=2 hl=2 l= 28 cons: cont [ 1 ] + 34:d=3 hl=2 l= 26 cons: SEQUENCE + 36:d=4 hl=2 l= 9 prim: OBJECT :mgf1 + 47:d=4 hl=2 l= 13 cons: SEQUENCE + 49:d=5 hl=2 l= 9 prim: OBJECT :sha256 + 60:d=5 hl=2 l= 0 prim: NULL + 62:d=2 hl=2 l= 3 cons: cont [ 2 ] + 64:d=3 hl=2 l= 1 prim: INTEGER :20 +-----BEGIN ALGORITHM----- +MEEGCSqGSIb3DQEBCjA0oA8wDQYJYIZIAWUDBAIBBQChHDAaBgkqhkiG9w0BAQgw +DQYJYIZIAWUDBAIBBQCiAwIBIA== +-----END ALGORITHM----- + +-----BEGIN DATA----- +x/UnD8pyX5vRn1GajXzKPMXAeQJAKfO65RD5sCFA/iOJCOT2wY8HqJxofIaEZpsfHbK6+SUaPIK +frMtJMIThbsnijViGgHSl1iIWZ91uUo0W/iyfPbTPr2xNzoyEOa84zqqqnOLsrnvI9KWlXjv5bf +nNV1xPnLMnlRuM3+QIcWg= +-----END DATA----- + +The signature was generated with: +$ openssl dgst -sign key.pem -sha256 -sigopt rsa_padding_mode:pss \ + -sigopt rsa_pss_saltlen:32 < [DATA] > [SIGNATURE] + +Then the signature was wrapped in a BIT STRING. + +$ openssl asn1parse -i < [SIGNATURE] + 0:d=0 hl=4 l= 257 prim: BIT STRING +-----BEGIN SIGNATURE----- +A4IBAQAhgPL8PV86dM9W4p1s7IWu8+9oXpPnFgutfKffNrPRny+7zUmJFER/JUDB +7gnb4qiDRqKftRIpizyrZb0M4Vrhq1CyINHM1anqinZESRy8npVvhrYv4QiHZnYX +vXtDjgBg3Rw2DufTOKgxs+nX8a050aHsuMulTRCwR6NuHkChJlJfg6p0b1losgcL +jKlu7EqTUUkY7Mt0WyCobxIKGbgrSVJsjV8La6rPh3LpA3d9i0Ik1HkyM1w+7utn +h2eT/FKO8W1BtB8haiyuhatuZ1c/2uttLBSZa8hK/2W4YuomUEoWz8JIP9xXQkoq +u0P2zB7MXW5jPJwpUX0fKXqFNSry +-----END SIGNATURE-----
diff --git a/storage/browser/blob/blob_builder_from_stream.cc b/storage/browser/blob/blob_builder_from_stream.cc index 8abde34..3dabb39 100644 --- a/storage/browser/blob/blob_builder_from_stream.cc +++ b/storage/browser/blob/blob_builder_from_stream.cc
@@ -668,23 +668,17 @@ if (!callback_) return; - RecordResult(result); std::move(callback_).Run(this, nullptr); } void BlobBuilderFromStream::OnSuccess() { DCHECK(context_); DCHECK(callback_); - RecordResult(Result::kSuccess); std::move(callback_).Run( this, context_->AddFinishedBlob(base::GenerateGUID(), content_type_, content_disposition_, std::move(items_))); } -void BlobBuilderFromStream::RecordResult(Result result) { - UMA_HISTOGRAM_ENUMERATION("Storage.Blob.BuildFromStreamResult", result); -} - bool BlobBuilderFromStream::ShouldStoreNextBlockOnDisk(uint64_t length_hint) { DCHECK(context_); const BlobMemoryController& controller = context_->memory_controller();
diff --git a/storage/browser/blob/blob_builder_from_stream.h b/storage/browser/blob/blob_builder_from_stream.h index d4ecc17c6..0fc0cea 100644 --- a/storage/browser/blob/blob_builder_from_stream.h +++ b/storage/browser/blob/blob_builder_from_stream.h
@@ -137,7 +137,6 @@ void OnError(Result result); void OnSuccess(); - void RecordResult(Result result); bool ShouldStoreNextBlockOnDisk(uint64_t length_hint);
diff --git a/storage/browser/blob/blob_data_builder.cc b/storage/browser/blob/blob_data_builder.cc index 9414959..c3680e5 100644 --- a/storage/browser/blob/blob_data_builder.cc +++ b/storage/browser/blob/blob_data_builder.cc
@@ -143,7 +143,6 @@ total_size_ += length; transport_quota_needed_ += length; found_file_transport_ = true; - UMA_HISTOGRAM_BOOLEAN("Storage.BlobItemSize.File.Unknown", false); return FutureFile(std::move(item)); } @@ -162,8 +161,6 @@ items_.push_back(std::move(shareable_item)); total_size_ += length; - bool unknown_size = length == blink::BlobUtils::kUnknownSize; - UMA_HISTOGRAM_BOOLEAN("Storage.BlobItemSize.File.Unknown", unknown_size); } void BlobDataBuilder::AppendBlob(const std::string& uuid,
diff --git a/testing/buildbot/chromium.android.json b/testing/buildbot/chromium.android.json index 4785bdf1..acda91f4 100644 --- a/testing/buildbot/chromium.android.json +++ b/testing/buildbot/chromium.android.json
@@ -40558,7 +40558,7 @@ ], "quickrun_shards": 40, "service_account": "chromium-tester@chops-service-accounts.iam.gserviceaccount.com", - "shards": 15 + "shards": 20 }, "test": "content_browsertests", "test_id_prefix": "ninja://content/test:content_browsertests/"
diff --git a/testing/buildbot/chromium.updater.json b/testing/buildbot/chromium.updater.json index 43f0c35..12ebfd4e 100644 --- a/testing/buildbot/chromium.updater.json +++ b/testing/buildbot/chromium.updater.json
@@ -886,58 +886,6 @@ } ] }, - "win7(32)-updater-tester-dbg": { - "gtest_tests": [ - { - "args": [ - "--test-launcher-timeout=90000", - "--ui-test-action-max-timeout=45000", - "--ui-test-action-timeout=40000" - ], - "merge": { - "args": [], - "script": "//testing/merge_scripts/standard_gtest_merge.py" - }, - "swarming": { - "can_use_on_swarming_builders": true, - "dimension_sets": [ - { - "cpu": "x86-32", - "integrity": "high", - "os": "Windows-7-SP1" - } - ], - "service_account": "chromium-tester@chops-service-accounts.iam.gserviceaccount.com" - }, - "test": "updater_tests", - "test_id_prefix": "ninja://chrome/updater:updater_tests/" - }, - { - "args": [ - "--test-launcher-timeout=90000", - "--ui-test-action-max-timeout=45000", - "--ui-test-action-timeout=40000" - ], - "merge": { - "args": [], - "script": "//testing/merge_scripts/standard_gtest_merge.py" - }, - "swarming": { - "can_use_on_swarming_builders": true, - "dimension_sets": [ - { - "cpu": "x86-32", - "integrity": "high", - "os": "Windows-7-SP1" - } - ], - "service_account": "chromium-tester@chops-service-accounts.iam.gserviceaccount.com" - }, - "test": "updater_tests_system", - "test_id_prefix": "ninja://chrome/updater:updater_tests_system/" - } - ] - }, "win7(32)-updater-tester-rel": { "gtest_tests": [ { @@ -990,59 +938,6 @@ } ] }, - "win7-updater-tester-dbg-uac": { - "gtest_tests": [ - { - "args": [ - "--test-launcher-timeout=90000", - "--ui-test-action-max-timeout=45000", - "--ui-test-action-timeout=40000" - ], - "merge": { - "args": [], - "script": "//testing/merge_scripts/standard_gtest_merge.py" - }, - "swarming": { - "can_use_on_swarming_builders": true, - "dimension_sets": [ - { - "cpu": "x86-64", - "integrity": "high", - "os": "Windows-7-SP1", - "pool": "chromium.win.uac" - } - ], - "service_account": "chromium-tester@chops-service-accounts.iam.gserviceaccount.com" - }, - "test": "updater_tests_system", - "test_id_prefix": "ninja://chrome/updater:updater_tests_system/" - }, - { - "args": [ - "--test-launcher-timeout=90000", - "--ui-test-action-max-timeout=45000", - "--ui-test-action-timeout=40000" - ], - "merge": { - "args": [], - "script": "//testing/merge_scripts/standard_gtest_merge.py" - }, - "swarming": { - "can_use_on_swarming_builders": true, - "dimension_sets": [ - { - "cpu": "x86-64", - "os": "Windows-7-SP1", - "pool": "chromium.win.uac" - } - ], - "service_account": "chromium-tester@chops-service-accounts.iam.gserviceaccount.com" - }, - "test": "updater_tests_win_uac", - "test_id_prefix": "ninja://chrome/updater:updater_tests_win_uac/" - } - ] - }, "win7-updater-tester-rel": { "gtest_tests": [ {
diff --git a/testing/buildbot/chromium.webrtc.fyi.json b/testing/buildbot/chromium.webrtc.fyi.json index 39cd9e9f..2b23d99 100644 --- a/testing/buildbot/chromium.webrtc.fyi.json +++ b/testing/buildbot/chromium.webrtc.fyi.json
@@ -559,145 +559,6 @@ } ] }, - "WebRTC Chromium FYI Win7 Tester": { - "gtest_tests": [ - { - "args": [ - "--test-launcher-filter-file=../../testing/buildbot/filters/webrtc_functional.browser_tests.filter", - "--run-manual", - "--test-launcher-jobs=1" - ], - "merge": { - "args": [], - "script": "//testing/merge_scripts/standard_gtest_merge.py" - }, - "name": "browser_tests_functional", - "swarming": { - "can_use_on_swarming_builders": true, - "dimension_sets": [ - { - "cpu": "x86-64", - "os": "Windows-7-SP1" - } - ], - "service_account": "chromium-tester@chops-service-accounts.iam.gserviceaccount.com" - }, - "test": "browser_tests", - "test_id_prefix": "ninja://chrome/test:browser_tests/" - }, - { - "args": [ - "--gtest_filter=WebRtcApprtcBrowserTest.*", - "--run-manual", - "--test-launcher-jobs=1" - ], - "merge": { - "args": [], - "script": "//testing/merge_scripts/standard_gtest_merge.py" - }, - "swarming": { - "can_use_on_swarming_builders": true, - "dimension_sets": [ - { - "cpu": "x86-64", - "os": "Windows-7-SP1" - } - ], - "service_account": "chromium-tester@chops-service-accounts.iam.gserviceaccount.com" - }, - "test": "browser_tests_apprtc", - "test_id_prefix": "ninja://chrome/test:browser_tests_apprtc/" - }, - { - "args": [ - "--gtest_filter=WebRtc*" - ], - "merge": { - "args": [], - "script": "//testing/merge_scripts/standard_gtest_merge.py" - }, - "swarming": { - "can_use_on_swarming_builders": true, - "dimension_sets": [ - { - "cpu": "x86-64", - "os": "Windows-7-SP1" - } - ], - "service_account": "chromium-tester@chops-service-accounts.iam.gserviceaccount.com" - }, - "test": "content_browsertests", - "test_id_prefix": "ninja://content/test:content_browsertests/" - }, - { - "args": [ - "--gtest_filter=WebRtc*MANUAL*:-UsingRealWebcam*", - "--run-manual", - "--ui-test-action-max-timeout=110000", - "--test-launcher-timeout=120000" - ], - "merge": { - "args": [], - "script": "//testing/merge_scripts/standard_gtest_merge.py" - }, - "name": "content_browsertests_stress", - "swarming": { - "can_use_on_swarming_builders": true, - "dimension_sets": [ - { - "cpu": "x86-64", - "os": "Windows-7-SP1" - } - ], - "service_account": "chromium-tester@chops-service-accounts.iam.gserviceaccount.com" - }, - "test": "content_browsertests", - "test_id_prefix": "ninja://content/test:content_browsertests/" - }, - { - "args": [ - "--test-launcher-filter-file=../../testing/buildbot/filters/webrtc.content_unittests.filter" - ], - "merge": { - "args": [], - "script": "//testing/merge_scripts/standard_gtest_merge.py" - }, - "swarming": { - "can_use_on_swarming_builders": true, - "dimension_sets": [ - { - "cpu": "x86-64", - "os": "Windows-7-SP1" - } - ], - "service_account": "chromium-tester@chops-service-accounts.iam.gserviceaccount.com" - }, - "test": "content_unittests", - "test_id_prefix": "ninja://content/test:content_unittests/" - }, - { - "args": [ - "--gtest_filter=Webrtc*" - ], - "merge": { - "args": [], - "script": "//testing/merge_scripts/standard_gtest_merge.py" - }, - "swarming": { - "can_use_on_swarming_builders": true, - "dimension_sets": [ - { - "cpu": "x86-64", - "os": "Windows-7-SP1" - } - ], - "service_account": "chromium-tester@chops-service-accounts.iam.gserviceaccount.com" - }, - "test": "remoting_unittests", - "test_id_prefix": "ninja://remoting:remoting_unittests/" - } - ] - }, "WebRTC Chromium FYI ios-device": {}, "WebRTC Chromium FYI ios-simulator": { "isolated_scripts": [
diff --git a/testing/buildbot/chromium.webrtc.json b/testing/buildbot/chromium.webrtc.json index ebfce3c2..b1426acb 100644 --- a/testing/buildbot/chromium.webrtc.json +++ b/testing/buildbot/chromium.webrtc.json
@@ -710,177 +710,5 @@ "test_id_prefix": "ninja://remoting:remoting_unittests/" } ] - }, - "WebRTC Chromium Win7 Tester": { - "gtest_tests": [ - { - "annotate": "graphing", - "args": [ - "--gtest_filter=WebRtcStatsPerfBrowserTest.*:WebRtcVideoDisplayPerfBrowserTests*:WebRtcVideoQualityBrowserTests*:WebRtcVideoHighBitrateBrowserTest*:WebRtcWebcamBrowserTests*", - "--run-manual", - "--ui-test-action-max-timeout=300000", - "--test-launcher-timeout=350000", - "--test-launcher-jobs=1", - "--test-launcher-bot-mode", - "--test-launcher-print-test-stdio=always" - ], - "merge": { - "args": [], - "script": "//testing/merge_scripts/standard_gtest_merge.py" - }, - "perf_builder_name_alias": "chromium-webrtc-rel-7", - "perf_config": { - "a_default_rev": "r_webrtc_git", - "r_webrtc_git": "${webrtc_got_rev}" - }, - "swarming": { - "can_use_on_swarming_builders": false - }, - "test": "browser_tests", - "test_id_prefix": "ninja://chrome/test:browser_tests/" - }, - { - "args": [ - "--test-launcher-filter-file=../../testing/buildbot/filters/webrtc_functional.browser_tests.filter", - "--run-manual", - "--test-launcher-jobs=1" - ], - "merge": { - "args": [], - "script": "//testing/merge_scripts/standard_gtest_merge.py" - }, - "name": "browser_tests_functional", - "perf_builder_name_alias": "chromium-webrtc-rel-7", - "swarming": { - "can_use_on_swarming_builders": true, - "service_account": "chromium-tester@chops-service-accounts.iam.gserviceaccount.com" - }, - "test": "browser_tests", - "test_id_prefix": "ninja://chrome/test:browser_tests/" - }, - { - "args": [ - "--gtest_filter=WebRtcApprtcBrowserTest.*", - "--run-manual", - "--test-launcher-jobs=1" - ], - "merge": { - "args": [], - "script": "//testing/merge_scripts/standard_gtest_merge.py" - }, - "perf_builder_name_alias": "chromium-webrtc-rel-7", - "swarming": { - "can_use_on_swarming_builders": true, - "service_account": "chromium-tester@chops-service-accounts.iam.gserviceaccount.com" - }, - "test": "browser_tests_apprtc", - "test_id_prefix": "ninja://chrome/test:browser_tests_apprtc/" - }, - { - "args": [ - "--enable-logging", - "--v=1", - "--test-launcher-jobs=1", - "--test-launcher-print-test-stdio=always" - ], - "merge": { - "args": [], - "script": "//testing/merge_scripts/standard_gtest_merge.py" - }, - "perf_builder_name_alias": "chromium-webrtc-rel-7", - "swarming": { - "can_use_on_swarming_builders": false - }, - "test": "capture_unittests", - "test_id_prefix": "ninja://media/capture:capture_unittests/" - }, - { - "args": [ - "--gtest_filter=WebRtc*" - ], - "merge": { - "args": [], - "script": "//testing/merge_scripts/standard_gtest_merge.py" - }, - "perf_builder_name_alias": "chromium-webrtc-rel-7", - "swarming": { - "can_use_on_swarming_builders": true, - "service_account": "chromium-tester@chops-service-accounts.iam.gserviceaccount.com" - }, - "test": "content_browsertests", - "test_id_prefix": "ninja://content/test:content_browsertests/" - }, - { - "args": [ - "--gtest_filter=UsingRealWebcam*", - "--run-manual", - "--test-launcher-jobs=1" - ], - "merge": { - "args": [], - "script": "//testing/merge_scripts/standard_gtest_merge.py" - }, - "name": "content_browsertests_sequential", - "perf_builder_name_alias": "chromium-webrtc-rel-7", - "swarming": { - "can_use_on_swarming_builders": true, - "service_account": "chromium-tester@chops-service-accounts.iam.gserviceaccount.com" - }, - "test": "content_browsertests", - "test_id_prefix": "ninja://content/test:content_browsertests/" - }, - { - "args": [ - "--gtest_filter=WebRtc*MANUAL*:-UsingRealWebcam*", - "--run-manual", - "--ui-test-action-max-timeout=110000", - "--test-launcher-timeout=120000" - ], - "merge": { - "args": [], - "script": "//testing/merge_scripts/standard_gtest_merge.py" - }, - "name": "content_browsertests_stress", - "perf_builder_name_alias": "chromium-webrtc-rel-7", - "swarming": { - "can_use_on_swarming_builders": true, - "service_account": "chromium-tester@chops-service-accounts.iam.gserviceaccount.com" - }, - "test": "content_browsertests", - "test_id_prefix": "ninja://content/test:content_browsertests/" - }, - { - "args": [ - "--test-launcher-filter-file=../../testing/buildbot/filters/webrtc.content_unittests.filter" - ], - "merge": { - "args": [], - "script": "//testing/merge_scripts/standard_gtest_merge.py" - }, - "perf_builder_name_alias": "chromium-webrtc-rel-7", - "swarming": { - "can_use_on_swarming_builders": true, - "service_account": "chromium-tester@chops-service-accounts.iam.gserviceaccount.com" - }, - "test": "content_unittests", - "test_id_prefix": "ninja://content/test:content_unittests/" - }, - { - "args": [ - "--gtest_filter=Webrtc*" - ], - "merge": { - "args": [], - "script": "//testing/merge_scripts/standard_gtest_merge.py" - }, - "perf_builder_name_alias": "chromium-webrtc-rel-7", - "swarming": { - "can_use_on_swarming_builders": true, - "service_account": "chromium-tester@chops-service-accounts.iam.gserviceaccount.com" - }, - "test": "remoting_unittests", - "test_id_prefix": "ninja://remoting:remoting_unittests/" - } - ] } }
diff --git a/testing/buildbot/filters/linux-lacros.browser_tests.filter b/testing/buildbot/filters/linux-lacros.browser_tests.filter index e654b71..8fe7205 100644 --- a/testing/buildbot/filters/linux-lacros.browser_tests.filter +++ b/testing/buildbot/filters/linux-lacros.browser_tests.filter
@@ -1,191 +1,54 @@ # TODO(crbug.com/1111979) Enable all tests on lacros. -AccessContextAuditBrowserTest.CheckSessionOnly --AccessContextAuditBrowserTest.PRE_RemoveRecords -AccessContextAuditBrowserTest.RemoveRecords -AdsPageLoadMetricsObserverBrowserTest.PageAdDensityIgnoreDisplayNoneFrame -AdsPageLoadMetricsObserverBrowserTest.PageAdDensityMultipleFrames -AdsPageLoadMetricsObserverBrowserTest.PageAdDensityRecordsPageMax --All/DownloadReferrerPolicyTest.SaveLinkAsReferrerPolicy* --All/HostedAppProcessModelTest.BackgroundPageWithAppCoveringDifferentSites/0 -All/HostedOrWebAppTest.CtrlClickLink/HostedApp -All/HostedOrWebAppTest.CtrlClickLink/WebApp --All/IntentPickerBubbleViewBrowserTest.NavigationInAppWindowToInScopeLinkDoesNotShowIntentPicker* --All/MultiActionAPITest.PopupCreation/1 --All/MultiActionAPITest.SessionStorageDoesNotPersistBetweenOpenings/1 -All/PopupBrowserTest.MoveClampedToCurrentDisplay* -All/WebRtcScreenCaptureBrowserTestWithPicker.ScreenCaptureVideo* -All/WebRtcScreenCaptureBrowserTestWithPicker.ScreenCaptureVideoAndAudio* --AppViewTest.KillGuestCommunicatingWithWrongAppView --AppViewTest.KillGuestWithInvalidInstanceID -AudioFocusWebContentsObserverBrowserTest.PlatformAppHasDifferentAudioFocus --AutofillProviderBrowserTest.FrameDetachedOnFormlessSubmission --AutofillProviderBrowserTestWithSkipFlagOn.InferredLabelChangeNotImpactFormComparing --AutomationApiTest.ForceLayout --AutoplayExtensionBrowserTest.AutoplayAllowedInIframe -BluetoothApiTest.* -BluetoothLowEnergyApiTest.* -BluetoothPrivateApiTest.* --BrowserActionApiTest.BrowserActionOpenPopupOnPopup --BrowserNavigatorTest.NavigateFromNoTabStripWindowToOptions --BrowserNavigatorTest.NavigateFromNTPToOptionsPageInSameTab --BrowserNavigatorTest.NavigateFromNTPToOptionsSingleton --BrowserNavigatorTest.SwitchToTabLatestWindow -BrowserTest.GetSizeForNewRenderView -BrowserTest.RestorePinnedTabs -BrowserViewTest.DevToolsUpdatesBrowserWindow -BrowserViewTest.F6CyclesThroughCaptionBubbleToo -BrowserViewTest.GetAccessibleTabModalDialogTitle -BrowsingDataRemoverBrowserTest.StorageRemovedFromDisk --CaptivePortalBrowserTest.SecureDnsErrorTriggersCheck --CaptivePortalBrowserTest.SlowLoadSecureDnsErrorAfterLogin --CaptivePortalBrowserTest.SlowLoadSecureDnsErrorWithCaptivePortal --ChromeSitePerProcessTest.PopupWindowFocus --ClientHintsBrowserTest.ClientHintsClearSession --ClipboardApiTest.Extension --ContentIndexTest.MetricsCollected -ContentSettingsTest.AllowCookiesForASessionUsingExceptions --ContentVerifierTest.PolicyCorrupted -ContextMenuBrowserTest.* --CrComponentsCertificateManagerTest.All --CrComponentsManagedFootnoteTest.All --CreativeOriginAdsPageLoadMetricsObserverBrowserTest.CreativeOriginStatusWithThrottlingNestedThrottled --CrSettingsAdvancedPageTest.Load --CrSettingsBasicPageTest.All --CrSettingsClearBrowsingDataTest.ClearBrowsingDataAllPlatforms --CrSettingsDownloadsPageTest.All --CrSettingsLanguagesPageTest.AddLanguagesDialog --CrSettingsLanguagesPageTest.LanguageMenu --CrSettingsLanguagesPageTest.Spellcheck --CrSettingsLanguagesTest.All --CrSettingsMainPageTest.MainPage --CrSettingsRouteTest.DynamicParameters --CrSettingsRouteTest.NonExistentRoute --CrSettingsSiteDetailsTest.SiteDetails --CrSettingsSiteListEntryTest.All --CrSettingsSyncAccountControlTest.All -CustomTabBarViewBrowserTest.BackToAppButtonIsNotVisibleInOutOfScopePopups -CustomTabBarViewBrowserTest.IsNotCreatedInPopup -CustomTabBarViewBrowserTest.RightClickMenuShowsCopyUrl -DeclarativeContentApiTest.RulesPersistence --DeepScanningDialogDelegateBlockLargeFileTransferBrowserTest.Test/3 --DesktopCaptureApiTest.ChooseDesktopMedia --DiceManageAccountBrowserTest.ClearManagedProfileOnStartup --DownloadExtensionTest.DownloadExtensionTest_SearchEmptyQuery --DownloadTest.DownloadTest_History --DownloadWakeLockTest.WakeLockAcquireAndCancel --ExtensionLoadingTest.KeepAliveWithDevToolsOpenOnReload --ExtensionManagementApiBrowserTest.GetAllIncludesTerminated --ExtensionManagementApiEscalationTest.SetEnabled --ExtensionOverrideTest.SubframeNavigationInOverridenNTPDoesNotAffectFocus --ExtensionPreferenceApiTest.Standard --ExtensionsMenuViewInteractiveUITest.ClickingContextMenuButton --ExtensionWebRequestApiTest.WebSocketRequest --ExtensionWebRequestApiTest.WebSocketRequestAuthRequired -ExternalProtocolDialogBrowserTest.TestFocus --FeedbackTest.AnonymousUser --FeedbackTest.ExtraDiagnostics --FeedbackTest.ShowFeedback --FeedbackTest.ShowFeedbackFromAssistant --FeedbackTest.ShowLoginFeedback --FeedbackTest.SubmissionTest -FindInPageControllerTest.FindMovesOnTabClose_Issue1343052 -FindInPageControllerTest.FindMovesWhenObscuring -FolderUploadConfirmationViewTest.InitiallyFocusesCancel --GlobalErrorBubbleTest.InvokeUi_ExtensionDisabledGlobalError --GlobalErrorBubbleTest.InvokeUi_ExtensionDisabledGlobalErrorRemote -GlobalErrorBubbleTest.InvokeUi_ExternalInstallBubbleAlert --InlineLoginHelperBrowserTest.ForceSigninWithUserManager -KeepAliveDevToolsTest.KeepsAliveUntilBrowserClose --LiteVideoBrowserTest.SimplePlayback --LoadImageBrowserTest.LoadImage --LoadImageBrowserTest.LoadImageWithMap --LocalCardMigrationBrowserTestForNickname.CardIdentifierString/1 -MediaRouterUIBrowserTest.EphemeralToolbarIconForDialog -MediaRouterUIBrowserTest.OpenDialogFromAppMenu --MediaSessionPictureInPictureWindowControllerBrowserTest.PlayPauseButtonVisibility --MediaSessionPictureInPictureWindowControllerBrowserTest.PreviousTrackHandlerCalled --NotificationPermissionContextApiTest.Granted --NtpExtensionBubbleViewBrowserTest.InvokeUi_ntp_override --NtpExtensionBubbleViewBrowserTest.TestControlledNewTabPageMessageBubble --NtpExtensionBubbleViewBrowserTest.TestControlledNewTabPageMessageBubbleLearnMore -OmniboxPopupContentsViewTest.ClickOmnibox -OmniboxPopupContentsViewTest.PopupMatchesLocationBarBackground -OutOfProcessPPAPITest.NetAddress -OutOfProcessPPAPITest.Printing -OutOfProcessPPAPITest.URLRequest_CreateAndIsURLRequestInfo --PageInfoBubbleViewBrowserTest.FocusDoesNotReturnToContentsOnReloadPrompt --PageInfoBubbleViewBrowserTest.FocusReturnsToContentOnClose -PageLoadMetricsBrowserTest.MainFrameIntersectionsMainFrame --PaymentRequestCompletionStatusMetricsTest.UserAborted_TabClosed --PaymentRequestCreditCardEditorTest.EditingExpiredCard --PaymentRequestShippingAddressEditorTest.FocusFirstField_Name --PaymentRequestShippingAddressEditorTest.FocusFirstInvalidField_NotName --PDFExtensionJSTest.Bookmark/1 --PDFExtensionTestWithTestGuestViewManager* --PermissionRequestManagerWithBackForwardCacheBrowserTest.RequestsForPagesInCacheNotGrouped --PermissionsApiTest.AlwaysAllowed --PictureInPicturePixelComparisonBrowserTest.* --PictureInPictureWindowControllerBrowserTest.* --PopupTrackerBrowserTest.PopupInWindow_IsWindowTrue --PopupTrackerBrowserTest.ShiftClick_HasTracker --PresentationReceiverWindowControllerBrowserTest.CreatesWindow -PreservedWindowPlacement.Test --PrintPreviewDestinationSelectTest.ChangeIconDeprecationWarnings --PrintPreviewDestinationSelectTest.UpdateStatusDeprecationWarnings --PrintPreviewDestinationStoreTest.LoadAndSelectDestination --PrintPreviewModelSettingsAvailabilityTest.All --PrintPreviewModelTest.GetPrintTicket --PrintPreviewModelTest.SetStickySettings --PrintPreviewRestoreStateTest.SaveValues --ProfileHelperTest.OpenNewWindowForProfile -ProfileListDesktopBrowserTest.SwitchToProfile --ProfileManagerBrowserTest.EphemeralProfile --ProfileManagerBrowserTest.SwitchToProfile --RemoteCopyBrowserTest.ImageUrl --RemoteCopyBrowserTest.Text --RemoteCopyBrowserTest.TextThenImageUrl --RunInBackgroundTest.RunInBackgroundBasicTest --RuntimeAPIUpdateTest.TerminatedExtensionUpdateHasCorrectPreviousVersion --SafeBrowsingBlockingPageBrowserTestWithThreatTypeAndIsolationSetting/SafeBrowsingBlockingPageBrowserTest.IframeOptInAndReportThreatDetails/3 --SafeBrowsingBlockingPageWithDelayedWarningsBrowserTest/SafeBrowsingBlockingPageDelayedWarningBrowserTest.JavaScriptDialog_WarningShown/3 --SafeBrowsingNetworkContext/NetworkContextConfigurationBrowserTest.Cache/0 --SaveCardBubbleViewsFullFormBrowserTest.StrikeDatabase_Local_AddStrikeIfBubbleDeclined --SaveCardBubbleViewsSyncTransportFullFormBrowserTest.Upload_TransportMode_RequestedCardholderNameTextfieldIsPrefilledWithFocusName --SearchByImageBrowserTest.ImageSearchWithCorruptImage --SearchByImageBrowserTest.ImageSearchWithValidImage --SecurityStateTabHelperTestWithFormsDangerous.MarkHttpAsWarningAndDangerousOnFormEdits --SerialTest.NavigateWithChooserCrossOrigin --ServiceWorkerAndExtensionsMenu/BrowserActionApiLazyTest.IncognitoBasic/0 --SessionCrashedBubbleViewTest.InvokeUi_SessionCrashedBubble -SessionRestoreTest.RestoredTabsHaveCorrectInitialSize --SettingsA11yAccessibilityV3.Accessibility_* --SettingsA11yBasicV3.Basic_* --SettingsA11yManageProfileV3.ManageProfile_* --SettingsA11yPasswordsV3.Passwords_* --SettingsA11ySignoutV3.Signout_* -SSLUITest.DisplayedContentWithCertErrorsClearedOnNavigation -SSLUITest.InAppTestHTTPSExpiredCertAndPreviouslyProceeded -SSLUITest.TestCloseTabWithUnsafePopup --StartupBrowserCreatorExtensionsCheckupExperimentTest.ExtensionsCheckup --StartupBrowserCreatorTest.RestoreWithNoStartupWindow --SubresourceRedirectBrowserTest.TestBypassOn503LoadShedFailure -TabActivityWatcherTest.AllWindowMetricsArePopulated --TabGroupEditorBubbleViewDialogBrowserTest.InvokeUi_default -TabHoverCardBubbleViewBrowserTest.WidgetNotVisibleOnMousePressAfterTabFocus -TabHoverCardBubbleViewBrowserTest.WidgetVisibleOnKeyPressAfterTabFocus -TabRestoreTest.RestoreWindowBounds --TabSearchBubbleBrowserTest.InvokeUi_default --TabStripDragManagerTest.All --TabStripUIBrowserTest.ActivatingTabClosesEmbedder --TranslateLanguageBrowserTest.LanguageModelLogSucceed --TranslateLanguageBrowserTest.TranslateAndRevert --TranslateLanguageBrowserTestWithTranslateRecentTarget.RecentTargetLanguage --TranslateManagerBrowserTest.PageTranslationTimeoutError --WebRtcDesktopCaptureBrowserTest.RunsScreenshareFromOneTabToAnother --WebViewTest.SelectShowHide --WebViewTest.Shim_TestDisplayNoneWebviewRemoveChild --WelcomeA11y.WelcomeFlow_listitem --WorkerTaskProviderBrowserTest.CreateTasksForMultiProfiles # crbug.com/1121486 # Following tests were flaky. We disable them first until we have time to investigate. -DevToolsExtensionTest.HttpIframeInDevToolsExtensionDevtools
diff --git a/testing/buildbot/filters/linux-lacros.components_unittests.filter b/testing/buildbot/filters/linux-lacros.components_unittests.filter index 16d6081..07be5d0 100644 --- a/testing/buildbot/filters/linux-lacros.components_unittests.filter +++ b/testing/buildbot/filters/linux-lacros.components_unittests.filter
@@ -1,2 +1 @@ # TODO(crbug.com/1111979) Enable all tests on lacros. --NetExportFileWriterTest*
diff --git a/testing/buildbot/filters/linux-lacros.sync_integration_tests.filter b/testing/buildbot/filters/linux-lacros.sync_integration_tests.filter index 14776985..07be5d0 100644 --- a/testing/buildbot/filters/linux-lacros.sync_integration_tests.filter +++ b/testing/buildbot/filters/linux-lacros.sync_integration_tests.filter
@@ -1,6 +1 @@ --SingleClientSessionsSyncTestWithFaviconTestServer.ShouldDeleteOnDemandIconsOnSessionsDisabled --SingleClientNigoriWithWebApiTest.ShoudRecordTrustedVaultErrorShownOnStartupWhenErrorNotShown --SingleClientNigoriWithWebApiTest.ShouldAcceptEncryptionKeysFromTheWebBeforeSignIn --SingleClientNigoriWithWebApiTest.ShouldClearEncryptionKeysFromTheWebWhenSigninCookiesCleared --SingleClientPollingSyncTest.ShouldPollWhenIntervalExpiredAcrossRestarts --SingleClientPollingSyncTest.ShouldUsePollIntervalFromPrefs +# TODO(crbug.com/1111979) Enable all tests on lacros.
diff --git a/testing/buildbot/filters/linux-lacros.unit_tests.filter b/testing/buildbot/filters/linux-lacros.unit_tests.filter index 1378475..bb5fb1b2 100644 --- a/testing/buildbot/filters/linux-lacros.unit_tests.filter +++ b/testing/buildbot/filters/linux-lacros.unit_tests.filter
@@ -1,5 +1,4 @@ # TODO(crbug.com/1111979) Enable all tests on lacros. --NativeDesktopMediaListTest.* -PermissionMessageCombinationsUnittest.USBSerialBluetoothCoalescing --RelaunchNotificationControllerPlatformImplTest.SynchronousNotification --WindowSizerTest.* +-WindowSizerTest.DefaultSizeCase +-WindowSizerTest.PersistedBoundsCase
diff --git a/testing/buildbot/mixins.pyl b/testing/buildbot/mixins.pyl index 3cdd9791..e14df0d 100644 --- a/testing/buildbot/mixins.pyl +++ b/testing/buildbot/mixins.pyl
@@ -365,9 +365,6 @@ 'service_account': 'chromium-tester@chops-service-accounts.iam.gserviceaccount.com', }, }, - 'chromium-webrtc-rel-7': { - 'perf_builder_name_alias': 'chromium-webrtc-rel-7', - }, 'chromium-webrtc-rel-linux': { 'perf_builder_name_alias': 'chromium-webrtc-rel-linux', },
diff --git a/testing/buildbot/test_suites.pyl b/testing/buildbot/test_suites.pyl index 0eab8b2..a50f89671 100644 --- a/testing/buildbot/test_suites.pyl +++ b/testing/buildbot/test_suites.pyl
@@ -229,7 +229,7 @@ 'cc_unittests': {}, 'content_browsertests': { 'swarming': { - 'shards': 15, + 'shards': 20, }, }, 'viz_unittests': {},
diff --git a/testing/buildbot/waterfalls.pyl b/testing/buildbot/waterfalls.pyl index b7f714a..5d56829 100644 --- a/testing/buildbot/waterfalls.pyl +++ b/testing/buildbot/waterfalls.pyl
@@ -6109,22 +6109,6 @@ ] }, }, - 'win7(32)-updater-tester-dbg': { - 'mixins': [ - 'win7', - 'x86-32' - ], - 'test_suites': { - 'gtest_tests': 'updater_gtests_win', - }, - 'swarming': { - 'dimension_sets': [ - { - 'integrity': 'high', - } - ] - }, - }, 'win7(32)-updater-tester-rel': { 'mixins': [ 'win7', @@ -6141,22 +6125,6 @@ ] }, }, - 'win7-updater-tester-dbg-uac': { - 'mixins': [ - 'win7', - 'x86-64', - ], - 'test_suites': { - 'gtest_tests': 'updater_gtests_win_uac', - }, - 'swarming': { - 'dimension_sets': [ - { - 'pool': 'chromium.win.uac', - } - ] - }, - }, 'win7-updater-tester-rel': { 'mixins': [ 'win7', @@ -6234,14 +6202,6 @@ 'gtest_tests': 'webrtc_chromium_tests_with_baremetal_tests', }, }, - 'WebRTC Chromium Win7 Tester': { - 'mixins': [ - 'chromium-webrtc-rel-7', - ], - 'test_suites': { - 'gtest_tests': 'webrtc_chromium_tests_with_baremetal_tests', - }, - }, }, }, { @@ -6333,15 +6293,6 @@ 'gtest_tests': 'webrtc_chromium_gtests', }, }, - 'WebRTC Chromium FYI Win7 Tester': { - 'mixins': [ - 'x86-64', - 'win7', - ], - 'test_suites': { - 'gtest_tests': 'webrtc_chromium_gtests', - }, - }, 'WebRTC Chromium FYI ios-device': {}, 'WebRTC Chromium FYI ios-simulator': { 'mixins': [
diff --git a/testing/trigger_scripts/base_test_triggerer.py b/testing/trigger_scripts/base_test_triggerer.py index 994a28b..06cc261f1 100755 --- a/testing/trigger_scripts/base_test_triggerer.py +++ b/testing/trigger_scripts/base_test_triggerer.py
@@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # Copyright 2018 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file.
diff --git a/testing/trigger_scripts/base_test_triggerer_unittest.py b/testing/trigger_scripts/base_test_triggerer_unittest.py index a331ba5..998fc547 100755 --- a/testing/trigger_scripts/base_test_triggerer_unittest.py +++ b/testing/trigger_scripts/base_test_triggerer_unittest.py
@@ -1,4 +1,4 @@ -#!/usr/bin/env vpython +#!/usr/bin/env vpython3 # Copyright 2020 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file.
diff --git a/testing/trigger_scripts/chromeos_device_trigger.py b/testing/trigger_scripts/chromeos_device_trigger.py index 7a8e686..d323b52 100755 --- a/testing/trigger_scripts/chromeos_device_trigger.py +++ b/testing/trigger_scripts/chromeos_device_trigger.py
@@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # Copyright 2019 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file.
diff --git a/testing/trigger_scripts/perf_device_trigger.py b/testing/trigger_scripts/perf_device_trigger.py index edd7a8d..4f45c06c 100755 --- a/testing/trigger_scripts/perf_device_trigger.py +++ b/testing/trigger_scripts/perf_device_trigger.py
@@ -1,4 +1,4 @@ -#!/usr/bin/env python +#!/usr/bin/env python3 # Copyright 2017 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file.
diff --git a/testing/trigger_scripts/perf_device_trigger_unittest.py b/testing/trigger_scripts/perf_device_trigger_unittest.py index 6d6c7c471..7bd66916 100755 --- a/testing/trigger_scripts/perf_device_trigger_unittest.py +++ b/testing/trigger_scripts/perf_device_trigger_unittest.py
@@ -1,4 +1,4 @@ -#!/usr/bin/env vpython +#!/usr/bin/env vpython3 # Copyright 2018 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file.
diff --git a/testing/unexpected_passes_common/builders.py b/testing/unexpected_passes_common/builders.py index c10cc2e..0d6499e 100644 --- a/testing/unexpected_passes_common/builders.py +++ b/testing/unexpected_passes_common/builders.py
@@ -45,16 +45,46 @@ class Builders(object): - def __init__(self, include_internal_builders): - self._authenticated = False - self._include_internal_builders = include_internal_builders - - def GetCiBuilders(self, suite): - """Gets the set of CI builders to query. - + def __init__(self, suite, include_internal_builders): + """ Args: suite: A string containing particular suite of interest if applicable, such as for Telemetry-based tests. Can be None if not applicable. + """ + self._authenticated = False + self._suite = suite + self._include_internal_builders = include_internal_builders + + def _ProcessJsonFiles(self, files, are_internal_files, builder_type): + builders = set() + for filepath in files: + if not filepath.endswith('.json'): + continue + if builder_type == constants.BuilderTypes.CI: + if 'tryserver' in filepath: + continue + elif builder_type == constants.BuilderTypes.TRY: + if 'tryserver' not in filepath: + continue + with open(filepath) as f: + buildbot_json = json.load(f) + # Skip any JSON files that don't contain builder information. + if AUTOGENERATED_JSON_KEY not in buildbot_json: + continue + + for builder, test_map in buildbot_json.items(): + # Remove the auto-generated comments. + if 'AAAA' in builder: + continue + # Filter out any builders that don't run the suite in question. + if not self._BuilderRunsTestOfInterest(test_map): + continue + builders.add( + data_types.BuilderEntry(builder, builder_type, are_internal_files)) + return builders + + def GetCiBuilders(self): + """Gets the set of CI builders to query. Returns: A set of data_types.BuilderEntry, each element corresponding to either a @@ -62,43 +92,22 @@ """ ci_builders = set() - def ProcessJsonFiles(files, are_internal_files): - for filepath in files: - if not filepath.endswith('.json'): - continue - with open(filepath) as f: - buildbot_json = json.load(f) - # Skip any JSON files that don't contain builder information. - if AUTOGENERATED_JSON_KEY not in buildbot_json: - continue - - for builder, test_map in buildbot_json.items(): - # Remove the auto-generated comments. - if 'AAAA' in builder: - continue - # Filter out any builders that don't run the suite in question. - if not self._BuilderRunsTestOfInterest(test_map, suite): - continue - ci_builders.add( - data_types.BuilderEntry(builder, constants.BuilderTypes.CI, - are_internal_files)) - logging.info('Getting CI builders') - ProcessJsonFiles([ + ci_builders = self._ProcessJsonFiles([ os.path.join(TESTING_BUILDBOT_DIR, f) for f in os.listdir(TESTING_BUILDBOT_DIR) - ], False) + ], False, constants.BuilderTypes.CI) if self._include_internal_builders: - ProcessJsonFiles([ + ci_builders |= self._ProcessJsonFiles([ os.path.join(INTERNAL_TESTING_BUILDBOT_DIR, f) for f in os.listdir(INTERNAL_TESTING_BUILDBOT_DIR) - ], True) + ], True, constants.BuilderTypes.CI) logging.debug('Got %d CI builders after trimming: %s', len(ci_builders), ', '.join([b.name for b in ci_builders])) return ci_builders - def _BuilderRunsTestOfInterest(self, test_map, suite): + def _BuilderRunsTestOfInterest(self, test_map): """Determines if a builder runs a test of interest. Args: @@ -115,17 +124,27 @@ def GetTryBuilders(self, ci_builders): """Gets the set of try builders to query. - A try builder is of interest if it mirrors a builder in |ci_builders|. + A try builder is of interest if it mirrors a builder in |ci_builders| or is + a dedicated try builder. Args: ci_builders: An iterable of data_types.BuilderEntry, each element being a public or internal CI builder that results will be/were queried from. Returns: - A set of strings, each element being the name of a Chromium try builder to - query results from. + A set of data_types.BuilderEntry, each element being the name of a + Chromium try builder to query results from. """ logging.info('Getting try builders') + dedicated_try_builders = self._ProcessJsonFiles([ + os.path.join(TESTING_BUILDBOT_DIR, f) + for f in os.listdir(TESTING_BUILDBOT_DIR) + ], False, constants.BuilderTypes.TRY) + if self._include_internal_builders: + dedicated_try_builders |= self._ProcessJsonFiles([ + os.path.join(INTERNAL_TESTING_BUILDBOT_DIR, f) + for f in os.listdir(INTERNAL_TESTING_BUILDBOT_DIR) + ], True, constants.BuilderTypes.TRY) mirrored_builders = set() no_output_builders = set() @@ -141,10 +160,11 @@ raise RuntimeError( 'Did not get Buildbucket output for the following builders. They may ' 'need to be added to the GetFakeCiBuilders or ' - 'GetNonChromiumBuilders .\n%s' % '\n'.join(no_output_builders)) + 'GetNonChromiumBuilders .\n%s' % + '\n'.join([b.name for b in no_output_builders])) logging.debug('Got %d try builders: %s', len(mirrored_builders), mirrored_builders) - return mirrored_builders + return dedicated_try_builders | mirrored_builders def _GetMirroredBuildersForCiBuilder(self, ci_builder): """Gets the set of try builders that mirror a CI builder. @@ -153,12 +173,12 @@ ci_builder: A data_types.BuilderEntry for a public or internal CI builder. Returns: - A tuple (builders, found_mirror). |builders| is a set of strings, either - the set of try builders that mirror |ci_builder| or |ci_builder|, - depending on the value of |found_mirror|. |found_mirror| is True if - mirrors were actually found, in which case |builders| contains the try - builders. Otherwise, |found_mirror| is False and |builders| contains - |ci_builder|. + A tuple (builders, found_mirror). |builders| is a set of + data_types.BuilderEntry, either the set of try builders that mirror + |ci_builder| or |ci_builder|, depending on the value of |found_mirror|. + |found_mirror| is True if mirrors were actually found, in which case + |builders| contains the try builders. Otherwise, |found_mirror| is False + and |builders| contains |ci_builder|. """ mirrored_builders = set() if ci_builder in self.GetNonChromiumBuilders():
diff --git a/testing/unexpected_passes_common/builders_unittest.py b/testing/unexpected_passes_common/builders_unittest.py index 4c6e8c6..ce4650d 100755 --- a/testing/unexpected_passes_common/builders_unittest.py +++ b/testing/unexpected_passes_common/builders_unittest.py
@@ -24,16 +24,7 @@ from unexpected_passes_common import unittest_utils -class GetCiBuildersUnittest(fake_filesystem_unittest.TestCase): - def setUp(self): - self._builders_instance = unittest_utils.GenericBuilders() - self._isolate_patcher = mock.patch.object( - self._builders_instance, - 'GetIsolateNames', - return_value={'telemetry_gpu_integration_test'}) - self._isolate_mock = self._isolate_patcher.start() - self.addCleanup(self._isolate_patcher.stop) - +class FakeFilesystemTestCaseWithFileCreation(fake_filesystem_unittest.TestCase): def CreateFile(self, *args, **kwargs): # TODO(crbug.com/1156806): Remove this and just use fs.create_file() when # Catapult is updated to a newer version of pyfakefs that is compatible with @@ -43,6 +34,18 @@ else: self.fs.CreateFile(*args, **kwargs) + +class GetCiBuildersUnittest(FakeFilesystemTestCaseWithFileCreation): + def setUp(self): + self._builders_instance = unittest_utils.GenericBuilders( + suite='webgl_conformance') + self._isolate_patcher = mock.patch.object( + self._builders_instance, + 'GetIsolateNames', + return_value={'telemetry_gpu_integration_test'}) + self._isolate_mock = self._isolate_patcher.start() + self.addCleanup(self._isolate_patcher.stop) + def testJsonContentLoaded(self): """Tests that the correct JSON data is loaded in.""" self.setUpPyfakefs() @@ -72,6 +75,31 @@ }, 'GPU FYI Linux Builder': {}, } + # Should be ignored. + tryserver_json = { + 'AAAAA1 AUTOGENERATED FILE DO NOT EDIT': {}, + 'Trybot': { + 'isolated_scripts': [{ + 'args': [ + 'webgl_conformance', + ], + 'isolate_name': + 'telemetry_gpu_integration_test', + }], + }, + } + # Also should be ignored. + not_buildbot_json = { + 'Not buildbot': { + 'isolated_scripts': [{ + 'args': [ + 'webgl_conformance', + ], + 'isolate_name': + 'telemetry_gpu_integration_test', + }], + }, + } self.CreateFile(os.path.join(builders.TESTING_BUILDBOT_DIR, 'chromium.gpu.json'), @@ -79,8 +107,14 @@ self.CreateFile(os.path.join(builders.TESTING_BUILDBOT_DIR, 'chromium.gpu.fyi.json'), contents=json.dumps(gpu_fyi_json)) + self.CreateFile(os.path.join(builders.TESTING_BUILDBOT_DIR, + 'tryserver.gpu.json'), + contents=json.dumps(tryserver_json)) + self.CreateFile(os.path.join(builders.TESTING_BUILDBOT_DIR, + 'not_buildbot.json'), + contents=json.dumps(not_buildbot_json)) - gpu_builders = self._builders_instance.GetCiBuilders('webgl_conformance') + gpu_builders = self._builders_instance.GetCiBuilders() self.assertEqual( gpu_builders, set([ @@ -97,11 +131,11 @@ def testFilterBySuite(self): """Tests that only builders that run the given suite are returned.""" - def SideEffect(tm, s): + def SideEffect(tm): tests = tm.get('isolated_scripts', []) for t in tests: if t.get('isolate_name') == 'foo_integration_test': - if s in t.get('args', []): + if 'webgl_conformance' in t.get('args', []): return True return False @@ -112,7 +146,7 @@ 'isolated_scripts': [ { 'args': [ - 'bar_conformance', + 'webgl_conformance', ], 'isolate_name': 'not_telemetry', }, @@ -132,7 +166,7 @@ 'isolated_scripts': [ { 'args': [ - 'bar_conformance', + 'webgl_conformance', ], 'isolate_name': 'foo_integration_test', }, @@ -147,7 +181,7 @@ with mock.patch.object(self._builders_instance, '_BuilderRunsTestOfInterest', side_effect=SideEffect): - gpu_builders = self._builders_instance.GetCiBuilders('bar_conformance') + gpu_builders = self._builders_instance.GetCiBuilders() self.assertEqual( gpu_builders, set([ @@ -161,13 +195,12 @@ # skip the test. if not os.path.exists(builders.TESTING_BUILDBOT_DIR): return - self.assertNotEqual( - len(self._builders_instance.GetCiBuilders('webgl_conformance')), 0) + self.assertNotEqual(len(self._builders_instance.GetCiBuilders()), 0) class GetMirroredBuildersForCiBuilderUnittest(unittest.TestCase): def setUp(self): - self._builders_instance = builders.Builders(False) + self._builders_instance = builders.Builders(None, False) self._bb_patcher = mock.patch.object(self._builders_instance, '_GetBuildbucketOutputForCiBuilder') self._bb_mock = self._bb_patcher.start() @@ -264,27 +297,39 @@ ])) -class GetTryBuildersUnittest(unittest.TestCase): +class GetTryBuildersUnittest(FakeFilesystemTestCaseWithFileCreation): def setUp(self): - self._builders_instance = builders.Builders(False) + self._builders_instance = builders.Builders(None, False) self._get_patcher = mock.patch.object(self._builders_instance, '_GetMirroredBuildersForCiBuilder') self._get_mock = self._get_patcher.start() self.addCleanup(self._get_patcher.stop) + self._runs_test_patcher = mock.patch.object(self._builders_instance, + '_BuilderRunsTestOfInterest') + self._runs_test_mock = self._runs_test_patcher.start() + self.addCleanup(self._runs_test_patcher.stop) self._pool_patcher = mock.patch.object(multiprocessing_utils, 'GetProcessPool') self._pool_mock = self._pool_patcher.start() self._pool_mock.return_value = unittest_utils.FakePool() self.addCleanup(self._pool_patcher.stop) - def testNoOutputCausesFailure(self): + self.setUpPyfakefs() + # Make sure the directory exists. + self.CreateFile( + os.path.join(builders.TESTING_BUILDBOT_DIR, 'placeholder.txt')) + + def testMirrorNoOutputCausesFailure(self): """Tests that a failure to get Buildbot output raises an exception.""" - self._get_mock.return_value = (set(['foo_ci']), False) + self._get_mock.return_value = (set( + [data_types.BuilderEntry('foo_ci', constants.BuilderTypes.CI, + False)]), False) + self._runs_test_mock.return_value = True with self.assertRaises(RuntimeError): self._builders_instance.GetTryBuilders(['foo_ci']) - def testOutputReturned(self): - """Tests that parsed builders get returned on success.""" + def testMirrorOutputReturned(self): + """Tests that parsed, mirrored builders get returned on success.""" def SideEffect(ci_builder): b = [ @@ -294,11 +339,191 @@ return set(b), True self._get_mock.side_effect = SideEffect + self._runs_test_mock.return_value = False mirrored_builders = self._builders_instance.GetTryBuilders( ['foo_ci', 'bar_ci']) self.assertEqual(mirrored_builders, set(['foo_try', 'foo_try2', 'bar_try', 'bar_try2'])) + def testDedicatedJsonContentLoaded(self): + """Tests that tryserver JSON content is loaded.""" + + def SideEffect(test_spec): + # Treat non-empty test specs as valid. + return bool(test_spec) + + self._runs_test_mock.side_effect = SideEffect + # Should be ignored. + gpu_json = { + 'AAAAA1 AUTOGENERATED FILE DO NOT EDIT': {}, + 'Android Release (Nexus 5X)': { + 'isolated_scripts': [{ + 'args': [ + 'webgl_conformance', + ], + 'isolate_name': + 'telemetry_gpu_integration_test', + }], + }, + 'GPU Linux Builder': {}, + } + # Should be ignored. + gpu_fyi_json = { + 'AAAAA1 AUTOGENERATED FILE DO NOT EDIT': {}, + 'ANGLE GPU Android Release (Nexus 5X)': { + 'isolated_scripts': [{ + 'args': [ + 'webgl_conformance', + ], + 'isolate_name': + 'telemetry_gpu_integration_test', + }], + }, + 'GPU FYI Linux Builder': {}, + } + tryserver_json = { + 'AAAAA1 AUTOGENERATED FILE DO NOT EDIT': {}, + 'Trybot': { + 'isolated_scripts': [{ + 'args': [ + 'webgl_conformance', + ], + 'isolate_name': + 'telemetry_gpu_integration_test', + }], + }, + 'Trybot Empty': {}, + } + # Also should be ignored. + not_buildbot_json = { + 'Not buildbot': { + 'isolated_scripts': [{ + 'args': [ + 'webgl_conformance', + ], + 'isolate_name': + 'telemetry_gpu_integration_test', + }], + }, + } + + self.CreateFile(os.path.join(builders.TESTING_BUILDBOT_DIR, + 'chromium.gpu.json'), + contents=json.dumps(gpu_json)) + self.CreateFile(os.path.join(builders.TESTING_BUILDBOT_DIR, + 'chromium.gpu.fyi.json'), + contents=json.dumps(gpu_fyi_json)) + self.CreateFile(os.path.join(builders.TESTING_BUILDBOT_DIR, + 'tryserver.gpu.json'), + contents=json.dumps(tryserver_json)) + self.CreateFile(os.path.join(builders.TESTING_BUILDBOT_DIR, + 'not_buildbot.json'), + contents=json.dumps(not_buildbot_json)) + + gpu_builders = self._builders_instance.GetTryBuilders({}) + self.assertEqual( + gpu_builders, + set([ + data_types.BuilderEntry('Trybot', constants.BuilderTypes.TRY, + False), + ])) + + def testDedicatedFilterBySuite(self): + """Tests that only builders that run the given suite are returned.""" + + def SideEffect(tm): + tests = tm.get('isolated_scripts', []) + for t in tests: + if t.get('isolate_name') == 'foo_integration_test': + if 'webgl_conformance' in t.get('args', []): + return True + return False + + self._runs_test_mock.side_effect = SideEffect + gpu_json = { + 'AAAAA1 AUTOGENERATED FILE DO NOT EDIT': {}, + 'Android Tester': { + 'isolated_scripts': [ + { + 'args': [ + 'webgl_conformance', + ], + 'isolate_name': 'not_telemetry', + }, + ], + }, + 'Linux Tester': { + 'isolated_scripts': [ + { + 'args': [ + 'not_a_suite', + ], + 'isolate_name': 'foo_integration_test', + }, + ], + }, + 'Windows Tester': { + 'isolated_scripts': [ + { + 'args': [ + 'webgl_conformance', + ], + 'isolate_name': 'foo_integration_test', + }, + ], + }, + } + + self.CreateFile(os.path.join(builders.TESTING_BUILDBOT_DIR, + 'tryserver.chromium.json'), + contents=json.dumps(gpu_json)) + + gpu_builders = self._builders_instance.GetTryBuilders({}) + self.assertEqual( + gpu_builders, + set([ + data_types.BuilderEntry('Windows Tester', + constants.BuilderTypes.TRY, False) + ])) + + def testDedicatedAndMirroredCombined(self): + """Tests that both dedicated and mirrored trybots are returned.""" + + def SideEffect(_): + return set({ + data_types.BuilderEntry('mirrored_trybot', constants.BuilderTypes.TRY, + False) + }), True + + self._get_mock.side_effect = SideEffect + self._runs_test_mock.return_value = True + tryserver_json = { + 'AAAAA1 AUTOGENERATED FILE DO NOT EDIT': {}, + 'Trybot': { + 'isolated_scripts': [{ + 'args': [ + 'webgl_conformance', + ], + 'isolate_name': + 'telemetry_gpu_integration_test', + }], + }, + } + + self.CreateFile(os.path.join(builders.TESTING_BUILDBOT_DIR, + 'tryserver.chromium.json'), + contents=json.dumps(tryserver_json)) + + try_builders = self._builders_instance.GetTryBuilders({ + data_types.BuilderEntry('ci_builder', constants.BuilderTypes.CI, False) + }) + self.assertEqual( + try_builders, { + data_types.BuilderEntry('mirrored_trybot', + constants.BuilderTypes.TRY, False), + data_types.BuilderEntry('Trybot', constants.BuilderTypes.TRY, False) + }) + if __name__ == '__main__': unittest.main(verbosity=2)
diff --git a/testing/unexpected_passes_common/unittest_utils.py b/testing/unexpected_passes_common/unittest_utils.py index bfc3b405..986064f0 100644 --- a/testing/unexpected_passes_common/unittest_utils.py +++ b/testing/unexpected_passes_common/unittest_utils.py
@@ -142,14 +142,12 @@ class GenericBuilders(builders.Builders): #pylint: disable=useless-super-delegation - def __init__(self, include_internal_builders=False): - super(GenericBuilders, self).__init__(include_internal_builders) + def __init__(self, suite=None, include_internal_builders=False): + super(GenericBuilders, self).__init__(suite, include_internal_builders) #pylint: enable=useless-super-delegation - #pylint: disable=unused-argument - def _BuilderRunsTestOfInterest(self, test_map, suite): + def _BuilderRunsTestOfInterest(self, _test_map): return True - #pylint: enable=unused-argument def GetIsolateNames(self): return {}
diff --git a/testing/variations/fieldtrial_testing_config.json b/testing/variations/fieldtrial_testing_config.json index 3ef3bd6..8c977e5c 100644 --- a/testing/variations/fieldtrial_testing_config.json +++ b/testing/variations/fieldtrial_testing_config.json
@@ -1817,28 +1817,6 @@ ] } ], - "Canvas2dStaysGPUOnReadback": [ - { - "platforms": [ - "android", - "android_weblayer", - "android_webview", - "chromeos", - "chromeos_lacros", - "linux", - "mac", - "windows" - ], - "experiments": [ - { - "name": "Enabled", - "enable_features": [ - "Canvas2dStaysGPUOnReadback" - ] - } - ] - } - ], "CanvasOutOfProcessRasterization": [ { "platforms": [ @@ -7649,29 +7627,6 @@ ] } ], - "UpdateClientHintsGREASERollout": [ - { - "platforms": [ - "android", - "chromeos", - "chromeos_lacros", - "linux", - "mac", - "windows" - ], - "experiments": [ - { - "name": "Enabled", - "params": { - "updated_algorithm": "true" - }, - "enable_features": [ - "GreaseUACH" - ] - } - ] - } - ], "UpdateHistoryEntryPointsInIncognito": [ { "platforms": [
diff --git a/third_party/blink/renderer/core/dom/document.cc b/third_party/blink/renderer/core/dom/document.cc index 95e465a..b939589c 100644 --- a/third_party/blink/renderer/core/dom/document.cc +++ b/third_party/blink/renderer/core/dom/document.cc
@@ -5788,6 +5788,9 @@ } if (GetFrame()) { + // This code should never fire for fenced frames because it should be + // blocked by permission policy. + DCHECK(!GetFrame()->IsInFencedFrameTree()); UseCounter::Count(*this, dom_window_->GetSecurityOrigin()->Port() == 0 ? WebFeature::kDocumentDomainSetWithDefaultPort @@ -5795,7 +5798,7 @@ bool was_cross_origin_to_main_frame = GetFrame()->IsCrossOriginToMainFrame(); bool was_cross_origin_to_parent_frame = - GetFrame()->IsCrossOriginToParentFrame(); + GetFrame()->IsCrossOriginToParentOrOuterDocument(); dom_window_->GetMutableSecurityOrigin()->SetDomainFromDOM(new_domain); bool is_cross_origin_to_main_frame = GetFrame()->IsCrossOriginToMainFrame(); if (FrameScheduler* frame_scheduler = GetFrame()->GetFrameScheduler()) @@ -5818,13 +5821,14 @@ } if (View() && was_cross_origin_to_parent_frame != - GetFrame()->IsCrossOriginToParentFrame()) { + GetFrame()->IsCrossOriginToParentOrOuterDocument()) { View()->CrossOriginToParentFrameChanged(); } // Notify all child frames if their cross-origin-to-parent status changed. - // TODO(pdr): This will notify even if |Frame::IsCrossOriginToParentFrame| - // is the same. Track whether each child was cross-origin-to-parent before - // and after changing the domain, and only notify the changed ones. + // TODO(pdr): This will notify even if + // |Frame::IsCrossOriginToParentOrOuterDocument| is the same. Track whether + // each child was cross-origin-to-parent before and after changing the + // domain, and only notify the changed ones. for (Frame* child = GetFrame()->Tree().FirstChild(); child; child = child->Tree().NextSibling()) { auto* child_local_frame = DynamicTo<LocalFrame>(child);
diff --git a/third_party/blink/renderer/core/editing/commands/insert_list_command.cc b/third_party/blink/renderer/core/editing/commands/insert_list_command.cc index fda3f69..887ea9a 100644 --- a/third_party/blink/renderer/core/editing/commands/insert_list_command.cc +++ b/third_party/blink/renderer/core/editing/commands/insert_list_command.cc
@@ -210,9 +210,10 @@ int index_for_end_of_selection = IndexForVisiblePosition( visible_end_of_selection, scope_for_end_of_selection); - if (StartOfParagraph(visible_start_of_selection, - kCanSkipOverEditingBoundary) - .DeepEquivalent() != start_of_last_paragraph) { + if (!StartOfParagraph(visible_start_of_selection, + kCanSkipOverEditingBoundary) + .DeepEquivalent() + .IsEquivalent(start_of_last_paragraph)) { force_list_creation = !SelectionHasListOfType(selection.Start(), selection.End(), list_tag);
diff --git a/third_party/blink/renderer/core/editing/commands/insert_list_command_test.cc b/third_party/blink/renderer/core/editing/commands/insert_list_command_test.cc index c6dc397..733438f1 100644 --- a/third_party/blink/renderer/core/editing/commands/insert_list_command_test.cc +++ b/third_party/blink/renderer/core/editing/commands/insert_list_command_test.cc
@@ -9,6 +9,7 @@ #include "third_party/blink/renderer/core/editing/frame_selection.h" #include "third_party/blink/renderer/core/editing/selection_template.h" #include "third_party/blink/renderer/core/editing/testing/editing_test_base.h" +#include "third_party/blink/renderer/core/editing/testing/selection_sample.h" #include "third_party/blink/renderer/core/editing/visible_position.h" #include "third_party/blink/renderer/core/editing/visible_units.h" #include "third_party/blink/renderer/core/frame/local_frame.h" @@ -275,4 +276,31 @@ "<li><input>|</li></ul>", GetSelectionTextFromBody()); } + +// Refer https://crbug.com/1316041 +TEST_F(InsertListCommandTest, TimeAndMeterInRoot) { + Document& document = GetDocument(); + document.setDesignMode("on"); + + Element* root = document.documentElement(); + Element* time = document.CreateRawElement(html_names::kTimeTag); + Element* meter = document.CreateRawElement(html_names::kMeterTag); + time->appendChild(meter); + root->insertBefore(time, root->firstChild()); + + Selection().SetSelection(SelectionInDOMTree::Builder() + .Collapse(Position(time, 0)) + .Extend(Position::LastPositionInNode(*time)) + .Build(), + SetSelectionOptions()); + + auto* command = MakeGarbageCollected<InsertListCommand>( + document, InsertListCommand::kUnorderedList); + + // Crash happens here. + EXPECT_TRUE(command->Apply()); + EXPECT_EQ("<ul><li>|<time></time></li></ul><head></head><body></body>", + SelectionSample::GetSelectionText( + *root, Selection().GetSelectionInDOMTree())); +} }
diff --git a/third_party/blink/renderer/core/editing/inline_box_position.cc b/third_party/blink/renderer/core/editing/inline_box_position.cc index 0bee263..b246127 100644 --- a/third_party/blink/renderer/core/editing/inline_box_position.cc +++ b/third_party/blink/renderer/core/editing/inline_box_position.cc
@@ -128,6 +128,20 @@ return box.NextLeafChild() && box.NextLeafChild()->IsLineBreak(); } +template <typename Strategy> +LayoutObject& GetLayoutObjectSkippingShadowRoot( + const PositionTemplate<Strategy>& position) { + // TODO(editing-dev): This function doesn't handle all types of positions. We + // may want to investigate callers and decide if we need to generalize it. + DCHECK(position.IsNotNull()); + const Node* anchor_node = position.AnchorNode(); + auto* shadow_root = DynamicTo<ShadowRoot>(anchor_node); + LayoutObject* result = shadow_root ? shadow_root->host().GetLayoutObject() + : anchor_node->GetLayoutObject(); + DCHECK(result) << position; + return *result; +} + InlineBoxPosition ComputeInlineBoxPositionForTextNode( const LayoutText* text_layout_object, int caret_offset, @@ -240,13 +254,8 @@ const PositionWithAffinityTemplate<Strategy>& position, int recursion_depth, EditingBoundaryCrossingRule rule) { - // TODO(yoichio): We don't assume |position| is canonicalized no longer and - // there are few cases failing to compute. Fix it: crbug.com/812535. - DCHECK(position.IsNotNull()); - DCHECK(!position.AnchorNode()->IsShadowRoot()) << position; - DCHECK(position.GetPosition().AnchorNode()->GetLayoutObject()) << position; const LayoutObject& layout_object = - *position.GetPosition().AnchorNode()->GetLayoutObject(); + GetLayoutObjectSkippingShadowRoot(position.GetPosition()); if (layout_object.IsText()) return position; @@ -272,10 +281,10 @@ bool NeedsLineEndAdjustment( const PositionWithAffinityTemplate<Strategy>& adjusted) { const PositionTemplate<Strategy>& position = adjusted.GetPosition(); - const LayoutObject& layout_object = *position.AnchorNode()->GetLayoutObject(); - if (!layout_object.IsText()) + const LayoutObject* layout_object = position.AnchorNode()->GetLayoutObject(); + if (!layout_object || !layout_object->IsText()) return false; - const auto& layout_text = To<LayoutText>(layout_object); + const auto& layout_text = To<LayoutText>(*layout_object); if (layout_text.IsBR()) return position.IsAfterAnchor(); // For normal text nodes. @@ -333,9 +342,7 @@ return ComputeInlineBoxPositionForLineEnd(adjusted); const PositionTemplate<Strategy>& position = adjusted.GetPosition(); - DCHECK(!position.AnchorNode()->IsShadowRoot()) << adjusted; - DCHECK(position.AnchorNode()->GetLayoutObject()) << adjusted; - LayoutObject& layout_object = *position.AnchorNode()->GetLayoutObject(); + LayoutObject& layout_object = GetLayoutObjectSkippingShadowRoot(position); const int caret_offset = position.ComputeEditingOffset(); if (layout_object.IsText()) {
diff --git a/third_party/blink/renderer/core/editing/selection_modifier_test.cc b/third_party/blink/renderer/core/editing/selection_modifier_test.cc index 1da31e5..9d696f2 100644 --- a/third_party/blink/renderer/core/editing/selection_modifier_test.cc +++ b/third_party/blink/renderer/core/editing/selection_modifier_test.cc
@@ -443,4 +443,28 @@ } } +// For https://crbug.com/1312704 +TEST_F(SelectionModifierTest, OptgroupAndTable) { + InsertStyleElement( + "optgroup, table { display: inline-table; }" + "table { appearance:button; }"); + SelectionModifier modifier( + GetFrame(), SetSelectionTextToBody( + "<optgroup>^</optgroup>|<table><td></td></table>")); + EXPECT_TRUE(modifier.Modify(SelectionModifyAlteration::kExtend, + SelectionModifyDirection::kForward, + TextGranularity::kLine)); + + const SelectionInDOMTree& selection = modifier.Selection().AsSelection(); + EXPECT_EQ( + "<optgroup></optgroup><table><tbody><tr><td></td></tr></tbody></table>", + GetSelectionTextFromBody(selection)); + + Element* optgroup = GetDocument().QuerySelector("optgroup"); + ShadowRoot* shadow_root = optgroup->GetShadowRoot(); + Element* label = shadow_root->getElementById("optgroup-label"); + EXPECT_EQ(Position(label, 0), selection.Base()); + EXPECT_EQ(Position(shadow_root, 1), selection.Extent()); +} + } // namespace blink
diff --git a/third_party/blink/renderer/core/frame/frame.cc b/third_party/blink/renderer/core/frame/frame.cc index 2b66f26e..c136ea0 100644 --- a/third_party/blink/renderer/core/frame/frame.cc +++ b/third_party/blink/renderer/core/frame/frame.cc
@@ -211,8 +211,10 @@ return IsCrossOriginToMainFrame() || IsInFencedFrameTree(); } -bool Frame::IsCrossOriginToParentFrame() const { +bool Frame::IsCrossOriginToParentOrOuterDocument() const { DCHECK(GetSecurityContext()); + if (IsInFencedFrameTree()) + return true; if (IsMainFrame()) return false; Frame* parent = Tree().Parent();
diff --git a/third_party/blink/renderer/core/frame/frame.h b/third_party/blink/renderer/core/frame/frame.h index 0b19a55..9aa6541 100644 --- a/third_party/blink/renderer/core/frame/frame.h +++ b/third_party/blink/renderer/core/frame/frame.h
@@ -152,7 +152,7 @@ // // Important notes: // - This function is not appropriate for determining if a subframe is - // cross-origin to its parent (see: |IsCrossOriginToParentFrame|). + // cross-origin to its parent (see: |IsCrossOriginToParentOrOuterDocument|). // - The return value must NOT be cached. A frame can be reused across // navigations, so the return value can change over time. // - The return value is inaccurate for a detached frame: it always @@ -174,8 +174,9 @@ bool IsCrossOriginToOutermostMainFrame() const; // Returns true if this frame is a subframe and is cross-origin to the parent - // frame. See |IsCrossOriginToMainFrame| for important notes. - bool IsCrossOriginToParentFrame() const; + // frame or has an outer document in another frame tree. + // See |IsCrossOriginToMainFrame| for important notes. + bool IsCrossOriginToParentOrOuterDocument() const; FrameOwner* Owner() const; void SetOwner(FrameOwner*);
diff --git a/third_party/blink/renderer/core/frame/local_frame.cc b/third_party/blink/renderer/core/frame/local_frame.cc index 0ee40eb..019b87a 100644 --- a/third_party/blink/renderer/core/frame/local_frame.cc +++ b/third_party/blink/renderer/core/frame/local_frame.cc
@@ -3210,8 +3210,10 @@ perfetto::TracedDictionary dict = std::move(ctx).WriteDictionary(); dict.Add("document", GetDocument()); dict.Add("is_main_frame", IsMainFrame()); - dict.Add("is_cross_origin_to_parent", IsCrossOriginToParentFrame()); - dict.Add("is_cross_origin_to_main_frame", IsCrossOriginToMainFrame()); + dict.Add("is_outermost_main_frame", IsOutermostMainFrame()); + dict.Add("is_cross_origin_to_parent", IsCrossOriginToParentOrOuterDocument()); + dict.Add("is_cross_origin_to_outermost_main_frame", + IsCrossOriginToOutermostMainFrame()); } } // namespace blink
diff --git a/third_party/blink/renderer/core/html/forms/select_type.cc b/third_party/blink/renderer/core/html/forms/select_type.cc index 527bf56..7b6ccbc4 100644 --- a/third_party/blink/renderer/core/html/forms/select_type.cc +++ b/third_party/blink/renderer/core/html/forms/select_type.cc
@@ -1074,7 +1074,8 @@ // OptionRemoved() makes sure option_to_scroll_to_ doesn't have an option // with another owner. DCHECK_EQ(option->OwnerSelectElement(), select_); - select_->GetDocument().UpdateStyleAndLayout(DocumentUpdateReason::kScroll); + select_->GetDocument().UpdateStyleAndLayoutForNode( + select_, DocumentUpdateReason::kScroll); if (!select_->GetLayoutObject()) return; PhysicalRect bounds = option->BoundingBoxForScrollIntoView();
diff --git a/third_party/blink/renderer/core/input/pointer_event_manager.cc b/third_party/blink/renderer/core/input/pointer_event_manager.cc index 071c62a..292a062c 100644 --- a/third_party/blink/renderer/core/input/pointer_event_manager.cc +++ b/third_party/blink/renderer/core/input/pointer_event_manager.cc
@@ -658,6 +658,11 @@ mojom::blink::UserActivationNotificationType::kInteraction); } + if (event.GetType() == WebInputEvent::Type::kPointerDown) { + touch_event_manager_->UpdateTouchAttributeMapsForPointerDown( + event, pointer_event_target); + } + WebInputEventResult result = DispatchTouchPointerEvent( event, coalesced_events, predicted_events, pointer_event_target);
diff --git a/third_party/blink/renderer/core/input/touch_event_manager.cc b/third_party/blink/renderer/core/input/touch_event_manager.cc index 856961e3..f7af7beb 100644 --- a/third_party/blink/renderer/core/input/touch_event_manager.cc +++ b/third_party/blink/renderer/core/input/touch_event_manager.cc
@@ -624,12 +624,6 @@ return; } - // In touch event model only touch starts can set the target and after that - // the touch event always goes to that target. - if (event.GetType() == WebInputEvent::Type::kPointerDown) { - UpdateTouchAttributeMapsForPointerDown(event, pointer_event_target); - } - // We might not receive the down action for a touch point. In that case we // would have never added them to |touch_attribute_map_| or hit-tested // them. For those just keep them in the map with a null target. Later they
diff --git a/third_party/blink/renderer/core/input/touch_event_manager.h b/third_party/blink/renderer/core/input/touch_event_manager.h index 6075f79..8843365 100644 --- a/third_party/blink/renderer/core/input/touch_event_manager.h +++ b/third_party/blink/renderer/core/input/touch_event_manager.h
@@ -48,6 +48,14 @@ // Returns whether there is any touch on the screen. bool IsAnyTouchActive() const; + // Keeps track of attributes of the touch point in the + // |touch_points_attributes_| map and computes the effective touch-action + // value, after possibly performing a hit-test if the original hit test result + // was not inside capturing frame |touch_sequence_document_| for touch events. + void UpdateTouchAttributeMapsForPointerDown( + const WebPointerEvent&, + const event_handling_util::PointerEventTarget&); + private: // Class represending one touch point event with its coalesced events and // related attributes. @@ -75,14 +83,6 @@ Touch* CreateDomTouch(const TouchPointAttributes*, bool* known_target); void AllTouchesReleasedCleanup(); - // Keeps track of attributes of the touch point in the - // |touch_points_attributes_| map and does the hit-testing if the original hit - // test result was not inside capturing frame |touch_sequence_document_| for - // touch events. - void UpdateTouchAttributeMapsForPointerDown( - const WebPointerEvent&, - const event_handling_util::PointerEventTarget&); - // This is triggered either by VSync signal to send one touch event per frame // accumulating all move events or by discrete events pointerdown/up/cancel. WebInputEventResult DispatchTouchEventFromAccumulatdTouchPoints(); @@ -135,6 +135,9 @@ // action which is sent to the browser after handling each dispatched // 'touchstart' is the intersection of all the previously calculated effective // touch action values during the sequence. + // + // TODO(https://crbug.com/844493): This seems incomplete code, should be + // removed. absl::optional<TouchAction> delayed_effective_touch_action_; };
diff --git a/third_party/blink/renderer/core/layout/layout_view.cc b/third_party/blink/renderer/core/layout/layout_view.cc index 4d8b214..ee6e79c 100644 --- a/third_party/blink/renderer/core/layout/layout_view.cc +++ b/third_party/blink/renderer/core/layout/layout_view.cc
@@ -960,7 +960,7 @@ NOT_DESTROYED(); // TODO(lfg): Audit for portals const LocalFrame& frame = frame_view_->GetFrame(); - if (frame.OwnerLayoutObject() && frame.IsCrossOriginToParentFrame()) + if (frame.OwnerLayoutObject() && frame.IsCrossOriginToParentOrOuterDocument()) return CompositingReason::kIFrame; return CompositingReason::kNone; }
diff --git a/third_party/blink/renderer/core/loader/DEPS b/third_party/blink/renderer/core/loader/DEPS index 2b4731d..904d7124 100644 --- a/third_party/blink/renderer/core/loader/DEPS +++ b/third_party/blink/renderer/core/loader/DEPS
@@ -18,6 +18,7 @@ } include_rules = [ "+base/containers/flat_map.h", + "+base/features.h", "+base/no_destructor.h", "+services/network/public/cpp/client_hints.h", ]
diff --git a/third_party/blink/renderer/core/loader/document_load_timing.cc b/third_party/blink/renderer/core/loader/document_load_timing.cc index 4438edc..3ecdb7c 100644 --- a/third_party/blink/renderer/core/loader/document_load_timing.cc +++ b/third_party/blink/renderer/core/loader/document_load_timing.cc
@@ -129,6 +129,8 @@ document_loader_ ? document_loader_->Url().GetString() : ""); dict.Add("isLoadingMainFrame", GetFrame() ? GetFrame()->IsMainFrame() : false); + dict.Add("isOutermostMainFrame", + GetFrame() ? GetFrame()->IsOutermostMainFrame() : false); dict.Add("navigationId", IdentifiersFactory::LoaderId(document_loader_)); }
diff --git a/third_party/blink/renderer/core/loader/frame_loader.cc b/third_party/blink/renderer/core/loader/frame_loader.cc index b3b4a4ce..04ba877 100644 --- a/third_party/blink/renderer/core/loader/frame_loader.cc +++ b/third_party/blink/renderer/core/loader/frame_loader.cc
@@ -1793,6 +1793,7 @@ frame_dict.Add("id_ref", IdentifiersFactory::FrameId(frame_.Get())); } dict.Add("isLoadingMainFrame", frame_->IsMainFrame()); + dict.Add("isOutermostMainFrame", frame_->IsOutermostMainFrame()); dict.Add("documentLoaderURL", document_loader_ ? document_loader_->Url().GetString() : String()); }
diff --git a/third_party/blink/renderer/core/loader/mixed_content_checker.cc b/third_party/blink/renderer/core/loader/mixed_content_checker.cc index 013c8b1bd..3afcf2f8 100644 --- a/third_party/blink/renderer/core/loader/mixed_content_checker.cc +++ b/third_party/blink/renderer/core/loader/mixed_content_checker.cc
@@ -30,6 +30,7 @@ #include "base/containers/contains.h" #include "base/feature_list.h" +#include "base/features.h" #include "base/metrics/field_trial_params.h" #include "services/network/public/cpp/is_potentially_trustworthy.h" #include "third_party/abseil-cpp/absl/types/optional.h" @@ -215,12 +216,24 @@ return settings && settings->GetAllowRunningOfInsecureContent(); } +bool IsUrlPotentiallyTrustworthy(const KURL& url) { + // This saves a copy of the url, which can be expensive for large data URLs. + // TODO(crbug.com/1322100): Remove this logic once + // network::IsUrlPotentiallyTrustworthy() doesn't copy the URL. + if (base::FeatureList::IsEnabled(base::features::kOptimizeDataUrls) && + url.ProtocolIsData()) { + DCHECK(network::IsUrlPotentiallyTrustworthy(url)); + return true; + } + return network::IsUrlPotentiallyTrustworthy(url); +} + } // namespace static bool IsInsecureUrl(const KURL& url) { // |url| is mixed content if it is not a potentially trustworthy URL. // See https://w3c.github.io/webappsec-mixed-content/#should-block-response - return !network::IsUrlPotentiallyTrustworthy(url); + return !IsUrlPotentiallyTrustworthy(url); } static void MeasureStricterVersionOfIsMixedContent(Frame& frame, @@ -238,7 +251,7 @@ source->GetDocument(), WebFeature::kMixedContentInNonHTTPSFrameThatRestrictsMixedContent); } - } else if (!network::IsUrlPotentiallyTrustworthy(url) && + } else if (!IsUrlPotentiallyTrustworthy(url) && base::Contains(url::GetSecureSchemes(), origin->Protocol().Ascii())) { UseCounter::Count( @@ -898,7 +911,7 @@ KURL url = resource_request.Url(); - if (!url.ProtocolIs("http") || network::IsUrlPotentiallyTrustworthy(url)) + if (!url.ProtocolIs("http") || IsUrlPotentiallyTrustworthy(url)) return; if (frame_type == mojom::RequestContextFrameType::kNone ||
diff --git a/third_party/blink/renderer/modules/mediasource/cross_thread_media_source_attachment.cc b/third_party/blink/renderer/modules/mediasource/cross_thread_media_source_attachment.cc index b8361cd..885341c 100644 --- a/third_party/blink/renderer/modules/mediasource/cross_thread_media_source_attachment.cc +++ b/third_party/blink/renderer/modules/mediasource/cross_thread_media_source_attachment.cc
@@ -60,8 +60,8 @@ void CrossThreadMediaSourceAttachment::NotifyDurationChanged( MediaSourceTracer* /* tracer */, - double /* duration */) { - DVLOG(1) << __func__ << " this=" << this << " (no-op)"; + double new_duration) { + DVLOG(1) << __func__ << " this=" << this << ", new_duration=" << new_duration; attachment_state_lock_.AssertAcquired(); @@ -72,11 +72,17 @@ DCHECK(!IsMainThread()); DCHECK(worker_runner_->BelongsToCurrentThread()); - // While the duration value of the attached media element is only updated upon - // a notification of the change hopping threads from the demuxer through the - // pipeline, a side effect of a duration change is a potentially new value for - // the buffered and seekable ranges, so we send updated values here, too. - SendUpdatedInfoToMainThreadCache(); + // Changing the duration has side effect of potentially new values for the + // buffered and seekable ranges. Furthermore, duration-changed notification of + // the media element, when attached cross-thread, needs to be done in a posted + // task's dispatch (to both mitigate high-res timer creation by apps, and to + // not require locks in the media element itself.) Finally, when that task is + // executed on the main thread, the way of updating the media element's + // duration correctly depends upon the element's current readyState. In short, + // send updated values and indicate that the recipient on the main thread also + // needs to correctly update the element's duration. + SendUpdatedInfoToMainThreadCacheInternal(/* has_duration */ true, + new_duration); } base::TimeDelta CrossThreadMediaSourceAttachment::GetRecentMediaTime( @@ -961,6 +967,13 @@ } void CrossThreadMediaSourceAttachment::SendUpdatedInfoToMainThreadCache() { + // No explicit duration update was done by application in this case. + SendUpdatedInfoToMainThreadCacheInternal(false, 0); +} + +void CrossThreadMediaSourceAttachment::SendUpdatedInfoToMainThreadCacheInternal( + bool has_new_duration, + double new_duration) { attachment_state_lock_.AssertAcquired(); VerifyCalledWhileContextsAliveForDebugging(); DCHECK(main_runner_); @@ -972,7 +985,7 @@ DCHECK(worker_runner_->BelongsToCurrentThread()); // TODO(https://crbug.com/878133): Consider coalescing frequent calls to this - // using a timer. + // using a timer, except when |has_new_duration| is true. // Here, since we are in scope of |lock| holding |attachment_state_lock_|, we // can correctly acquire an ExclusiveKey to give to MediaSource so it can know @@ -987,12 +1000,14 @@ CrossThreadBindOnce( &CrossThreadMediaSourceAttachment::UpdateMainThreadInfoCache, WTF::RetainedRef(this), std::move(new_buffered), - std::move(new_seekable))); + std::move(new_seekable), has_new_duration, new_duration)); } void CrossThreadMediaSourceAttachment::UpdateMainThreadInfoCache( WebTimeRanges new_buffered, - WebTimeRanges new_seekable) { + WebTimeRanges new_seekable, + bool has_new_duration, + double new_duration) { MutexLocker lock(attachment_state_lock_); DCHECK(IsMainThread()); @@ -1020,6 +1035,31 @@ cached_buffered_ = std::move(new_buffered); cached_seekable_ = std::move(new_seekable); + + if (has_new_duration) { + // We may need to let the media element know duration has changed. Whether + // we do this needs to be conditioned upon the media element's current + // readyState. + if (attached_element_->getReadyState() == HTMLMediaElement::kHaveNothing) { + DVLOG(1) << __func__ << " this=" << this + << ": new_duration=" << new_duration + << " and media element readyState is HAVE_NOTHING"; + // Explicitly notify the media element of the updated duration. This + // happens when app sets MediaSource duration before the pipeline has + // reached HAVE_METADATA. + bool request_seek = attached_element_->currentTime() > new_duration; + attached_element_->DurationChanged(new_duration, request_seek); + return; + } + + // The pipeline will deliver explicit duration changed notifications to the + // element at and after the transition to HAVE_METADATA, including when the + // app sets MediaSource duration in those cases, so don't deliver any extra + // notification to the element here. + DVLOG(1) << __func__ << " this=" << this + << ": new_duration=" << new_duration + << " and media element readyState is beyond HAVE_NOTHING (no-op)"; + } } void CrossThreadMediaSourceAttachment::
diff --git a/third_party/blink/renderer/modules/mediasource/cross_thread_media_source_attachment.h b/third_party/blink/renderer/modules/mediasource/cross_thread_media_source_attachment.h index 62a6631..72db3250 100644 --- a/third_party/blink/renderer/modules/mediasource/cross_thread_media_source_attachment.h +++ b/third_party/blink/renderer/modules/mediasource/cross_thread_media_source_attachment.h
@@ -145,9 +145,6 @@ void SendUpdatedInfoToMainThreadCache() final EXCLUSIVE_LOCKS_REQUIRED(attachment_state_lock_); - void UpdateMainThreadInfoCache(WebTimeRanges new_buffered, - WebTimeRanges new_seekable); - private: ~CrossThreadMediaSourceAttachment() override; @@ -186,10 +183,19 @@ void HandleElementErrorOnWorkerThread() LOCKS_EXCLUDED(attachment_state_lock_); + void SendUpdatedInfoToMainThreadCacheInternal(bool has_new_duration, + double new_duration) + EXCLUSIVE_LOCKS_REQUIRED(attachment_state_lock_); + + void UpdateMainThreadInfoCache(WebTimeRanges new_buffered, + WebTimeRanges new_seekable, + bool has_new_duration, + double new_duration) + LOCKS_EXCLUDED(attachment_state_lock_); + // In this cross-thread implementation, this helper is used to verify // assumption of "liveness" of the attachment while the caller holds - // |attachment_state_lock_| - // for common operations. + // |attachment_state_lock_| for common operations. void VerifyCalledWhileContextsAliveForDebugging() const EXCLUSIVE_LOCKS_REQUIRED(attachment_state_lock_);
diff --git a/third_party/blink/renderer/platform/loader/fetch/resource_fetcher.cc b/third_party/blink/renderer/platform/loader/fetch/resource_fetcher.cc index 37f30ca3..749e13e 100644 --- a/third_party/blink/renderer/platform/loader/fetch/resource_fetcher.cc +++ b/third_party/blink/renderer/platform/loader/fetch/resource_fetcher.cc
@@ -35,6 +35,7 @@ #include "base/debug/dump_without_crashing.h" #include "base/feature_list.h" #include "base/logging.h" +#include "base/metrics/histogram_functions.h" #include "base/metrics/histogram_macros.h" #include "base/time/time.h" #include "services/network/public/cpp/request_mode.h" @@ -1012,8 +1013,17 @@ TRACE_DISABLED_BY_DEFAULT("network"), "ResourceLoad", TRACE_ID_WITH_SCOPE("BlinkResourceID", TRACE_ID_LOCAL(identifier)), "url", resource_request.Url()); - SCOPED_BLINK_UMA_HISTOGRAM_TIMER_THREAD_SAFE( - "Blink.Fetch.RequestResourceTime"); + base::ScopedClosureRunner timer(base::BindOnce( + [](base::TimeTicks start, bool is_data) { + base::TimeDelta elapsed = base::TimeTicks::Now() - start; + base::UmaHistogramMicrosecondsTimes("Blink.Fetch.RequestResourceTime2", + elapsed); + if (is_data) { + base::UmaHistogramMicrosecondsTimes( + "Blink.Fetch.RequestResourceTime2.Data", elapsed); + } + }, + base::TimeTicks::Now(), params.Url().ProtocolIsData())); TRACE_EVENT1("blink,blink.resource", "ResourceFetcher::requestResource", "url", params.Url().ElidedString().Utf8());
diff --git a/third_party/blink/tools/blinkpy/presubmit/audit_non_blink_usage.py b/third_party/blink/tools/blinkpy/presubmit/audit_non_blink_usage.py index 2022318..993a627 100755 --- a/third_party/blink/tools/blinkpy/presubmit/audit_non_blink_usage.py +++ b/third_party/blink/tools/blinkpy/presubmit/audit_non_blink_usage.py
@@ -272,6 +272,7 @@ 'base::Feature.*', 'base::FEATURE_.+', "base::GetFieldTrial.*", + 'base::features::.+', 'features::.+', # PartitionAlloc
diff --git a/third_party/blink/tools/blinkpy/web_tests/stale_expectation_removal/builders.py b/third_party/blink/tools/blinkpy/web_tests/stale_expectation_removal/builders.py index e467fdb..685e310 100644 --- a/third_party/blink/tools/blinkpy/web_tests/stale_expectation_removal/builders.py +++ b/third_party/blink/tools/blinkpy/web_tests/stale_expectation_removal/builders.py
@@ -10,11 +10,11 @@ class WebTestBuilders(builders.Builders): def __init__(self, include_internal_builders): - super(WebTestBuilders, self).__init__(include_internal_builders) + super(WebTestBuilders, self).__init__(None, include_internal_builders) self._fake_ci_builders = None self._non_chromium_builders = None - def _BuilderRunsTestOfInterest(self, test_map, _): + def _BuilderRunsTestOfInterest(self, test_map): tests = test_map.get('isolated_scripts', []) for t in tests: if t.get('isolate_name') in self.GetIsolateNames(): @@ -72,6 +72,9 @@ 'win10.20h2-blink-rel-dummy': { 'win10.20h2-blink-rel', }, + 'win11-blink-rel-dummy': { + 'win11-blink-rel', + }, # tryserver.chromium.linux # Explicit trybot. 'linux-blink-web-tests-force-accessibility-rel': {
diff --git a/third_party/blink/tools/blinkpy/web_tests/stale_expectation_removal/builders_unittest.py b/third_party/blink/tools/blinkpy/web_tests/stale_expectation_removal/builders_unittest.py index 96a40b0d2..60521a5 100755 --- a/third_party/blink/tools/blinkpy/web_tests/stale_expectation_removal/builders_unittest.py +++ b/third_party/blink/tools/blinkpy/web_tests/stale_expectation_removal/builders_unittest.py
@@ -23,8 +23,7 @@ }, ], } - self.assertTrue( - self.instance._BuilderRunsTestOfInterest(test_map, None)) + self.assertTrue(self.instance._BuilderRunsTestOfInterest(test_map)) # Re-add once WebGPU tests are supported. # test_map = { @@ -35,7 +34,7 @@ # ], # } # self.assertTrue( - # self.instance._BuilderRunsTestOfInterest(test_map, None)) + # self.instance._BuilderRunsTestOfInterest(test_map)) def testNoMatch(self): test_map = { @@ -45,8 +44,7 @@ }, ], } - self.assertFalse( - self.instance._BuilderRunsTestOfInterest(test_map, None)) + self.assertFalse(self.instance._BuilderRunsTestOfInterest(test_map)) class GetFakeCiBuildersUnittest(unittest.TestCase):
diff --git a/third_party/blink/tools/blinkpy/web_tests/stale_expectation_removal/queries.py b/third_party/blink/tools/blinkpy/web_tests/stale_expectation_removal/queries.py index 7661679..8f7aa52 100644 --- a/third_party/blink/tools/blinkpy/web_tests/stale_expectation_removal/queries.py +++ b/third_party/blink/tools/blinkpy/web_tests/stale_expectation_removal/queries.py
@@ -53,7 +53,8 @@ WHERE "Failure" IN UNNEST(typ_expectations) OR "Crash" IN UNNEST(typ_expectations) - OR "Timeout" IN UNNEST(typ_expectations)""" + OR "Timeout" IN UNNEST(typ_expectations) + OR "Slow" IN UNNEST(typ_expectations)""" # This query gets us all results for tests from CI that have had results with a # Failure, Timeout, or Crash expectation in the past |@num_builds| builds on @@ -147,6 +148,7 @@ "Failure" IN UNNEST(typ_expectations) OR "Crash" IN UNNEST(typ_expectations) OR "Timeout" IN UNNEST(typ_expectations) + OR "Slow" IN UNNEST(typ_expectations) """ ALL_BUILDERS_FROM_TABLE_SUBQUERY = """\ @@ -213,7 +215,7 @@ builder_type = builder.builder_type # Look for all tests. if not self._large_query_mode: - return WebTestFixedQueryGenerator(builder_type, '') + return WebTestFixedQueryGenerator(builder, '') query = TEST_FILTER_QUERY_TEMPLATE.format( builder_project=builder.project, builder_type=builder.builder_type) @@ -231,8 +233,7 @@ # splitting. target_num_ids = (queries_module.TARGET_RESULTS_PER_QUERY / self._num_samples) - return WebTestSplitQueryGenerator(builder_type, test_ids, - target_num_ids) + return WebTestSplitQueryGenerator(builder, test_ids, target_num_ids) def _StripPrefixFromTestId(self, test_id): # Web test IDs provided by ResultDB are the test name known by the test
diff --git a/third_party/blink/tools/blinkpy/web_tests/stale_expectation_removal/queries_unittest.py b/third_party/blink/tools/blinkpy/web_tests/stale_expectation_removal/queries_unittest.py index 1b11e75..ef25f47e 100755 --- a/third_party/blink/tools/blinkpy/web_tests/stale_expectation_removal/queries_unittest.py +++ b/third_party/blink/tools/blinkpy/web_tests/stale_expectation_removal/queries_unittest.py
@@ -91,12 +91,17 @@ """Tests that the expected clause is returned in normal mode.""" querier = wt_uu.CreateGenericWebTestQuerier() query_generator = querier._GetQueryGeneratorForBuilder( - common_data_types.BuilderEntry('builder', 'builder_type', False)) + common_data_types.BuilderEntry('builder', + common_constants.BuilderTypes.CI, + False)) self.assertEqual(len(query_generator.GetClauses()), 1) self.assertEqual(query_generator.GetClauses()[0], '') self.assertIsInstance(query_generator, queries.WebTestFixedQueryGenerator) self._query_mock.assert_not_called() + # Make sure that there aren't any issues with getting the queries. + q = query_generator.GetQueries() + self.assertEqual(len(q), 1) def testLargeQueryModeNoTests(self): """Tests that a special value is returned if no tests are found.""" @@ -128,6 +133,9 @@ ['AND test_id IN UNNEST(["foo_test", "bar_test"])']) self.assertIsInstance(query_generator, queries.WebTestSplitQueryGenerator) + # Make sure that there aren't any issues with getting the queries. + q = query_generator.GetQueries() + self.assertEqual(len(q), 1) @unittest.skipIf(six.PY2, 'Script and unittest are Python 3-only') @@ -294,6 +302,7 @@ "Failure" IN UNNEST(typ_expectations) OR "Crash" IN UNNEST(typ_expectations) OR "Timeout" IN UNNEST(typ_expectations) + OR "Slow" IN UNNEST(typ_expectations) """ self.assertEqual( queries.CI_BQ_QUERY_TEMPLATE.format(builder_project='chromium', @@ -356,6 +365,7 @@ "Failure" IN UNNEST(typ_expectations) OR "Crash" IN UNNEST(typ_expectations) OR "Timeout" IN UNNEST(typ_expectations) + OR "Slow" IN UNNEST(typ_expectations) """ self.assertEqual( queries.CI_BQ_QUERY_TEMPLATE.format(builder_project='chrome', @@ -433,6 +443,7 @@ "Failure" IN UNNEST(typ_expectations) OR "Crash" IN UNNEST(typ_expectations) OR "Timeout" IN UNNEST(typ_expectations) + OR "Slow" IN UNNEST(typ_expectations) """ self.assertEqual( queries.TRY_BQ_QUERY_TEMPLATE.format(builder_project='chromium', @@ -510,6 +521,7 @@ "Failure" IN UNNEST(typ_expectations) OR "Crash" IN UNNEST(typ_expectations) OR "Timeout" IN UNNEST(typ_expectations) + OR "Slow" IN UNNEST(typ_expectations) """ self.assertEqual( queries.TRY_BQ_QUERY_TEMPLATE.format(builder_project='chrome',
diff --git a/third_party/blink/tools/blinkpy/web_tests/stale_expectation_removal/remove_stale_expectations.py b/third_party/blink/tools/blinkpy/web_tests/stale_expectation_removal/remove_stale_expectations.py index 8d1b1e1..57712c3 100644 --- a/third_party/blink/tools/blinkpy/web_tests/stale_expectation_removal/remove_stale_expectations.py +++ b/third_party/blink/tools/blinkpy/web_tests/stale_expectation_removal/remove_stale_expectations.py
@@ -46,7 +46,7 @@ test_expectation_map = expectations_instance.CreateTestExpectationMap( expectations_instance.GetExpectationFilepaths(), None, args.expectation_grace_period) - ci_builders = builders_instance.GetCiBuilders(None) + ci_builders = builders_instance.GetCiBuilders() querier = queries.WebTestBigQueryQuerier(None, args.project, args.num_samples,
diff --git a/third_party/blink/web_tests/ASANExpectations b/third_party/blink/web_tests/ASANExpectations index 1300010..b43ec67 100644 --- a/third_party/blink/web_tests/ASANExpectations +++ b/third_party/blink/web_tests/ASANExpectations
@@ -24,52 +24,15 @@ crbug.com/166932 [ Linux ] plugins/embed-attributes-setting.html [ Skip ] crbug.com/166932 [ Linux ] plugins/embed-attributes-style.html [ Skip ] -# These have been failing since at least chrome r203901, blink r151723 (no memory errors, just text failure): -crbug.com/231357 [ Linux ] editing/execCommand/switch-list-type-with-orphaned-li.html [ Failure ] - -crbug.com/192172 [ Linux ] compositing/rtl/rtl-iframe-absolute-overflow.html [ Failure Pass ] -crbug.com/192172 [ Linux ] compositing/rtl/rtl-iframe-fixed-overflow-scrolled.html [ Failure Pass ] -crbug.com/192172 [ Linux ] compositing/rtl/rtl-iframe-fixed-overflow.html [ Failure Pass ] - -crbug.com/290411 [ Linux ] virtual/text-antialias/sub-pixel/text-scaling-pixel.html [ Failure Pass ] -crbug.com/339778 [ Linux ] fast/dom/timer-throttling-hidden-page.html [ Failure Pass ] -crbug.com/353746 [ Linux ] virtual/android/fullscreen/video-specified-size.html [ Failure Pass ] - -crbug.com/385015 [ Linux ] editing/execCommand/window-open-insert-list-crash.html [ Failure ] -crbug.com/385015 [ Linux ] fast/frames/iframe-onload-remove-self-no-crash.html [ Failure ] -crbug.com/385015 [ Linux ] fast/loader/create-frame-in-DOMContentLoaded.html [ Failure ] -crbug.com/385015 [ Linux ] fast/loader/frame-creation-removal.html [ Failure ] - -crbug.com/867982 external/wpt/requestidlecallback/basic.html [ Timeout Pass ] -crbug.com/882756 external/wpt/requestidlecallback/cancel-invoked.html [ Timeout Pass ] - # Stack use-after-return detection -crbug.com/438499 [ Linux ] crypto/worker-random-values-limits.html [ Timeout ] -crbug.com/438499 [ Linux ] fast/workers/worker-multi-startup.html [ Timeout ] -crbug.com/438499 [ Linux ] http/tests/websocket/workers/worker-simple.html [ Timeout ] -crbug.com/438499 [ Linux ] http/tests/workers/text-encoding.html [ Timeout ] -crbug.com/438499 [ Linux ] http/tests/devtools/profiler/heap-snapshot-loader.js [ Timeout ] -crbug.com/438499 [ Linux ] http/tests/devtools/profiler/heap-snapshot-containment-show-all.js [ Timeout ] crbug.com/438499 [ Linux ] virtual/threaded-no-composited-antialiasing/animations/unanimated-style.html [ Timeout ] # Flakily timeout on Linux ASAN bots. crbug.com/243871 [ Linux ] virtual/threaded-prefer-compositing/fast/scroll-behavior/* [ Skip ] -crbug.com/464065 [ Linux ] media/track/css-cue-for-video-in-shadow.html [ Timeout ] -crbug.com/464065 [ Linux ] media/track/css-cue-for-video-in-shadow-2.html [ Timeout ] crbug.com/700795 [ Linux ] http/tests/devtools/animation/animation-transition-setTiming-crash.js [ Skip ] -# Intentionally failed allocations, via partitionAllocGenericFlags() -crbug.com/577889 [ Linux ] fast/js/typed-array-allocation-failure.html [ Crash ] - # Memory allocation hooks are disabled on ASAN/MSAN crbug.com/803276 inspector-protocol/memory/sampling-native-profile.js [ Skip ] crbug.com/803276 inspector-protocol/memory/sampling-native-snapshot.js [ Skip ] -# Disabled by sheriff due to test crash -crbug.com/896068 [ Linux ] webaudio/AudioBuffer/huge-buffer.html [ Crash ] -crbug.com/896068 [ Linux ] webaudio/dom-exceptions.html [ Pass Crash ] - -# Sheriff 2019-07-31 -crbug.com/989365 [ Linux ] external/wpt/cookie-store/serviceworker_cookiechange_eventhandler_single_subscription.tentative.https.any.serviceworker.html [ Pass Timeout ] - crbug.com/1048597 [ Linux ] virtual/android/fullscreen/video-scrolled-iframe.html [ Pass Timeout ]
diff --git a/third_party/blink/web_tests/FlagExpectations/disable-layout-ng b/third_party/blink/web_tests/FlagExpectations/disable-layout-ng index ddd9370d..91b9d21 100644 --- a/third_party/blink/web_tests/FlagExpectations/disable-layout-ng +++ b/third_party/blink/web_tests/FlagExpectations/disable-layout-ng
@@ -43,10 +43,6 @@ crbug.com/626703 external/wpt/wasm/webapi/esm-integration/wasm-js-cycle.tentative.html [ Timeout ] crbug.com/626703 external/wpt/wasm/webapi/esm-integration/worker-import.tentative.html [ Timeout ] crbug.com/626703 external/wpt/wasm/webapi/esm-integration/worker.tentative.html [ Timeout ] -crbug.com/626703 external/wpt/webmessaging/broadcastchannel/opaque-origin.html [ Timeout ] -crbug.com/626703 external/wpt/webrtc-stats/rtp-stats-creation.html [ Crash Failure ] -crbug.com/626703 external/wpt/domxpath/xpath-evaluate-crash.html [ Crash ] -crbug.com/626703 virtual/prerender/external/wpt/speculation-rules/prerender/media-autoplay.html [ Failure Timeout ] crbug.com/626703 virtual/prerender/external/wpt/speculation-rules/prerender/restrictions.html [ Failure Timeout ] crbug.com/626703 external/wpt/css/css-flexbox/abspos/flex-abspos-staticpos-margin-003.html [ Failure ] crbug.com/626703 external/wpt/css/css-overflow/scrollbar-gutter-vertical-lr-002.html [ Failure ] @@ -78,15 +74,9 @@ ### editing/pasteboard/ crbug.com/591099 editing/pasteboard/mathml-sanitizer-bypass.html [ Failure ] -### editing/selection/mouse/ -crbug.com/591099 editing/selection/mouse/drag_over_text_transform.html [ Crash ] - ### editing/selection/select-line-up-down.html crbug.com/591099 editing/selection/select-line-up-down.html [ Failure ] -### external/wpt/css/CSS2/abspos/ -crbug.com/591099 external/wpt/css/CSS2/abspos/hypothetical-box-dynamic.html [ Failure ] - ### external/wpt/css/CSS2/floats/ crbug.com/591099 external/wpt/css/CSS2/floats/float-nowrap-3.html [ Failure ] crbug.com/591099 external/wpt/css/CSS2/floats/floats-line-wrap-shifted-001.html [ Failure ] @@ -138,7 +128,6 @@ crbug.com/829028 external/wpt/css/css-break/break-between-avoid-007.html [ Failure ] crbug.com/829028 external/wpt/css/css-break/break-between-avoid-009.html [ Failure ] crbug.com/829028 external/wpt/css/css-break/break-between-avoid-010.html [ Failure ] -crbug.com/1277976 external/wpt/css/css-break/change-inline-color.html [ Failure Pass ] crbug.com/726125 external/wpt/css/css-break/chrome-bug-1289999-crash.https.html [ Skip ] crbug.com/829028 external/wpt/css/css-break/fieldset-003.html [ Failure ] crbug.com/829028 external/wpt/css/css-break/fieldset-004.html [ Failure ] @@ -446,9 +435,7 @@ crbug.com/1045599 external/wpt/css/css-grid/grid-definition/grid-auto-repeat-minmax.html [ Failure ] crbug.com/1045599 external/wpt/css/css-grid/grid-definition/grid-limits-001.html [ Failure ] crbug.com/1045599 external/wpt/css/css-grid/grid-items/aspect-ratio-004.html [ Failure ] -crbug.com/1045599 external/wpt/css/css-grid/grid-items/grid-auto-margin-and-replaced-item-001.html [ Failure ] crbug.com/1045599 external/wpt/css/css-grid/grid-items/grid-intrinsic-maximums.html [ Failure ] -crbug.com/1045599 external/wpt/css/css-grid/grid-items/grid-item-inline-contribution-002.html [ Failure ] crbug.com/1045599 external/wpt/css/css-grid/grid-items/grid-item-inline-contribution-003.html [ Failure ] crbug.com/1045599 external/wpt/css/css-grid/grid-items/grid-size-with-orthogonal-child-dynamic.html [ Failure ] crbug.com/1045599 external/wpt/css/css-grid/grid-items/percentage-margin-dynamic.html [ Failure ] @@ -539,8 +526,6 @@ crbug.com/829028 external/wpt/css/css-multicol/multicol-nested-023.html [ Failure ] crbug.com/1246602 external/wpt/css/css-multicol/multicol-oof-inline-cb-001.html [ Failure ] crbug.com/1246602 external/wpt/css/css-multicol/multicol-oof-inline-cb-002.html [ Failure ] -crbug.com/1277976 external/wpt/css/css-multicol/multicol-overflow-positioned-transform-001.html [ Failure Pass ] -crbug.com/1277976 external/wpt/css/css-multicol/multicol-overflow-transform-001.html [ Failure Pass ] crbug.com/990240 external/wpt/css/css-multicol/multicol-rule-nested-balancing-004.html [ Failure ] crbug.com/829028 external/wpt/css/css-multicol/multicol-span-all-children-height-009.html [ Failure ] crbug.com/829028 external/wpt/css/css-multicol/multicol-span-all-children-height-010.html [ Failure ] @@ -580,7 +565,6 @@ crbug.com/591099 external/wpt/css/css-position/position-absolute-center-003.html [ Failure ] crbug.com/591099 external/wpt/css/css-position/position-absolute-center-004.html [ Failure ] crbug.com/591099 external/wpt/css/css-position/position-absolute-center-006.html [ Failure ] -crbug.com/591099 external/wpt/css/css-position/position-absolute-crash-chrome-006.html [ Crash ] crbug.com/591099 external/wpt/css/css-position/position-absolute-dynamic-overflow-002.html [ Failure ] crbug.com/591099 external/wpt/css/css-position/position-absolute-fit-content.html [ Failure ] crbug.com/591099 external/wpt/css/css-position/position-absolute-in-inline-003.html [ Failure ] @@ -683,7 +667,6 @@ crbug.com/591099 external/wpt/css/css-sizing/intrinsic-percent-replaced-dynamic-007.html [ Failure ] crbug.com/591099 external/wpt/css/css-sizing/intrinsic-percent-replaced-dynamic-008.html [ Failure ] crbug.com/591099 external/wpt/css/css-sizing/whitespace-and-break.html [ Failure ] -crbug.com/591099 external/wpt/css/css-sizing/ortho-writing-mode-001.html [ Failure ] crbug.com/1135287 external/wpt/css/css-sizing/image-min-max-content-intrinsic-size-change-001.html [ Failure ] crbug.com/1135287 external/wpt/css/css-sizing/image-min-max-content-intrinsic-size-change-002.html [ Failure ] crbug.com/1135287 external/wpt/css/css-sizing/image-min-max-content-intrinsic-size-change-003.html [ Failure ] @@ -717,14 +700,8 @@ crbug.com/591099 external/wpt/css/css-text/line-breaking/line-breaking-009.html [ Failure ] crbug.com/591099 external/wpt/css/css-text/line-breaking/line-breaking-011.html [ Failure ] crbug.com/591099 external/wpt/css/css-text/line-breaking/line-breaking-015.html [ Failure ] -crbug.com/591099 external/wpt/css/css-text/line-breaking/line-breaking-atomic-003.html [ Failure ] -crbug.com/591099 external/wpt/css/css-text/line-breaking/line-breaking-atomic-004.html [ Failure ] -crbug.com/591099 external/wpt/css/css-text/line-breaking/line-breaking-atomic-005.html [ Failure ] -crbug.com/591099 external/wpt/css/css-text/line-breaking/line-breaking-atomic-006.html [ Failure ] crbug.com/591099 external/wpt/css/css-text/line-breaking/line-breaking-ic-002.html [ Failure ] crbug.com/591099 external/wpt/css/css-text/line-breaking/line-breaking-ic-003.html [ Failure ] -crbug.com/591099 external/wpt/css/css-text/line-breaking/line-breaking-replaced-002.html [ Failure ] -crbug.com/591099 external/wpt/css/css-text/line-breaking/line-breaking-replaced-003.html [ Failure ] ### external/wpt/css/css-text/overflow-wrap/ crbug.com/1019695 external/wpt/css/css-text/overflow-wrap/overflow-wrap-shaping-001.html [ Failure ] @@ -795,14 +772,12 @@ crbug.com/591099 external/wpt/css/css-text-decor/text-decoration-thickness-scroll-001.html [ Failure ] crbug.com/591099 external/wpt/css/css-text-decor/text-decoration-thickness-underline-001.html [ Failure ] crbug.com/591099 external/wpt/css/css-text-decor/text-decoration-thickness-vertical-001.html [ Failure ] -crbug.com/591099 external/wpt/css/css-text-decor/text-underline-offset-scroll-001.html [ Failure ] ### external/wpt/css/css-ui/ crbug.com/591099 external/wpt/css/css-ui/text-overflow-010.html [ Failure ] crbug.com/1063319 external/wpt/css/css-ui/text-overflow-028.html [ Failure ] crbug.com/1078539 external/wpt/css/css-ui/outline-025.html [ Failure ] crbug.com/1078539 external/wpt/css/css-ui/outline-026.html [ Failure ] -crbug.com/1250194 wpt_internal/css/css-ui/outline-block-in-inline.html [ Failure ] ### external/wpt/css/css-writing-modes/ crbug.com/591099 external/wpt/css/css-writing-modes/abs-pos-non-replaced-icb-vlr-003.xht [ Failure ] @@ -974,10 +949,6 @@ ### fast/multicol/ crbug.com/467477 fast/multicol/vertical-rl/nested-columns.html [ Failure ] -### fast/replaced/ -crbug.com/591099 fast/replaced/border-radius-clip-content-edge.html [ Failure ] -crbug.com/591099 fast/replaced/outline-replaced-elements.html [ Failure ] - ### fast/selectors/ crbug.com/591099 fast/selectors/input-with-selection-pseudo-element.html [ Failure ] @@ -999,7 +970,6 @@ crbug.com/591099 virtual/text-antialias/justify-ideograph-simple.html [ Failure ] crbug.com/591099 virtual/text-antialias/apply-start-width-after-skipped-text.html [ Failure ] crbug.com/870219 virtual/text-antialias/hyphens/hyphens-auto-mock.html [ Failure ] -crbug.com/591099 virtual/text-antialias/hyphens/hyphens-auto-nowrap.html [ Failure ] crbug.com/639223 virtual/text-antialias/line-break-between-text-nodes-latin1.html [ Failure ] ### http/tests/ @@ -1010,15 +980,6 @@ crbug.com/1159760 http/tests/devtools/elements/highlight/highlight-css-flex.js [ Skip ] crbug.com/591099 http/tests/devtools/elements/highlight/highlight-node-vertical-rl.js [ Failure ] -### http/tests/images/ -crbug.com/591099 http/tests/images/png-partial-load-as-document.html [ Failure ] - -### http/tests/misc/ -crbug.com/591099 http/tests/misc/favicon-as-image.html [ Failure ] - -### images/ -crbug.com/591099 images/favicon-as-image.html [ Failure ] - ### inspector-protocol/ crbug.com/591099 inspector-protocol/layout-fonts/languages-emoji-rare-glyphs.js [ Failure ] @@ -1056,11 +1017,9 @@ crbug.com/591099 virtual/dark-color-scheme/media/audio-focus-ring.html [ Failure ] ### virtual/exotic-color-space/images/ -crbug.com/591099 virtual/exotic-color-space/images/favicon-as-image.html [ Failure ] ### virtual/gpu-rasterization/images/ crbug.com/591099 virtual/gpu-rasterization/images/color-profile-image-filter-all.html [ Failure Slow ] -crbug.com/591099 virtual/gpu-rasterization/images/favicon-as-image.html [ Failure ] ### virtual/layout_ng_table_frag/ virtual/layout_ng_table_frag/* [ Skip ] @@ -1068,11 +1027,6 @@ ### virtual/layout_ng_printing/ virtual/layout_ng_printing/* [ Skip ] -### virtual/plz-dedicated-worker/external/wpt/service-workers/service-worker/ -crbug.com/591099 virtual/plz-dedicated-worker/external/wpt/service-workers/service-worker/registration-updateviacache.https.html [ Failure ] - -crbug.com/591099 external/wpt/css/css-counter-styles/cjk-decimal/css3-counter-styles-001.html [ Failure ] -crbug.com/591099 external/wpt/css/css-counter-styles/cjk-decimal/css3-counter-styles-004.html [ Failure ] crbug.com/591099 external/wpt/css/css-counter-styles/cssom/cssom-name-setter-invalid.html [ Failure ] crbug.com/591099 external/wpt/css/css-counter-styles/cssom/cssom-name-setter.html [ Failure ] crbug.com/591099 external/wpt/css/css-counter-styles/hebrew/css3-counter-styles-016.html [ Failure ] @@ -1080,8 +1034,6 @@ crbug.com/591099 external/wpt/css/css-counter-styles/hiragana/css3-counter-styles-031.html [ Failure ] crbug.com/591099 external/wpt/css/css-counter-styles/hiragana-iroha/css3-counter-styles-033.html [ Failure ] crbug.com/591099 external/wpt/css/css-counter-styles/hiragana-iroha/css3-counter-styles-034.html [ Failure ] -crbug.com/591099 external/wpt/css/css-counter-styles/japanese-formal/css3-counter-styles-049.html [ Failure ] -crbug.com/591099 external/wpt/css/css-counter-styles/japanese-informal/css3-counter-styles-044.html [ Failure ] crbug.com/591099 external/wpt/css/css-counter-styles/katakana/css3-counter-styles-036.html [ Failure ] crbug.com/591099 external/wpt/css/css-counter-styles/katakana/css3-counter-styles-037.html [ Failure ] crbug.com/591099 external/wpt/css/css-counter-styles/katakana/css3-counter-styles-038.html [ Failure ] @@ -1100,8 +1052,6 @@ crbug.com/591099 external/wpt/css/css-tables/absolute-tables-011.tentative.html [ Failure ] crbug.com/591099 external/wpt/css/css-tables/absolute-tables-015.html [ Failure ] -crbug.com/591099 virtual/scalefactor200/external/wpt/element-timing/observe-text.html [ Failure ] - # Line clamp overflow fixed in NG crbug.com/591099 external/wpt/css/css-overflow/webkit-line-clamp-009.html [ Failure ] crbug.com/591099 external/wpt/css/css-overflow/webkit-line-clamp-010.html [ Failure ] @@ -1151,7 +1101,6 @@ crbug.com/1132627 external/wpt/css/css-flexbox/flex-minimum-height-flex-items-007.xht [ Failure ] crbug.com/1132627 external/wpt/css/css-flexbox/flex-aspect-ratio-img-column-011.html [ Failure ] crbug.com/721123 css3/flexbox/flexitem.html [ Failure ] -crbug.com/591099 css3/flexbox/flex-align-vertical-writing-mode.html [ Failure ] crbug.com/591099 css3/flexbox/flex-flow-auto-margins-no-available-space-assert.html [ Failure ] crbug.com/721123 external/wpt/css/css-flexbox/flexitem-stretch-image.html [ Failure ] crbug.com/704294 external/wpt/css/css-flexbox/flex-aspect-ratio-img-row-006.html [ Failure ] @@ -1164,26 +1113,15 @@ crbug.com/591099 external/wpt/css/css-flexbox/table-as-item-percent-width-cell-001.html [ Failure ] # These would need a rebaseline back from LayoutNGBlockFlow to LayoutBlockFlow -crbug.com/864567 paint/float/float-under-inline-self-painting-change.html [ Failure ] crbug.com/864567 paint/invalidation/compositing/iframe-inside-squashed-layer.html [ Failure ] -crbug.com/864567 paint/invalidation/compositing/updating-scrolling-container.html [ Failure ] crbug.com/864567 paint/invalidation/forms/textarea-caret.html [ Failure ] crbug.com/864567 paint/invalidation/position/layout-state-only-positioned.html [ Failure ] -crbug.com/864567 paint/invalidation/resize-iframe-text.html [ Failure ] -crbug.com/864567 paint/invalidation/scroll/destroy-overlay-scrollbar.html [ Failure ] -crbug.com/864567 paint/invalidation/scroll/destroy-scrollbar.html [ Failure ] crbug.com/864567 paint/invalidation/scroll/overflow-scroll-body-appear.html [ Failure ] -crbug.com/864567 paint/invalidation/scroll/scrollbar-ancestor-clip-change.html [ Failure ] crbug.com/864567 paint/invalidation/scroll/scrolled-iframe-scrollbar-change.html [ Failure ] -crbug.com/864567 paint/invalidation/svg/deep-nested-embedded-svg-size-changes-no-layout-triggers-1.html [ Failure ] -crbug.com/864567 paint/invalidation/svg/deep-nested-embedded-svg-size-changes-no-layout-triggers-2.html [ Failure ] -crbug.com/864567 paint/invalidation/svg/nested-embedded-svg-size-changes-no-layout-triggers-1.html [ Failure ] -crbug.com/864567 paint/invalidation/svg/nested-embedded-svg-size-changes-no-layout-triggers-2.html [ Failure ] compositing/squashing/squash-same-transform-ancestor.html [ Failure ] compositing/geometry/layer-due-to-layer-children-deep-switch.html [ Failure ] compositing/geometry/layer-due-to-layer-children-switch.html [ Failure ] compositing/layer-creation/overlap-transformed-layer-with-transform-body.html [ Failure ] -compositing/layer-creation/overlap-transformed-layer.html [ Failure ] compositing/overflow/rotate-then-clip-effect-interleave.html [ Failure ] compositing/overflow/rotate-then-clip-z-order-interleave.html [ Failure ] compositing/overflow/rotate-then-clip.html [ Failure ] @@ -1195,14 +1133,12 @@ crbug.com/1016759 paint/invalidation/search-field-cancel.html [ Failure ] crbug.com/1016759 paint/invalidation/subtree-root-skipped.html [ Failure ] crbug.com/1016759 paint/invalidation/svg/animated-path-inside-transformed-html.xhtml [ Failure ] -crbug.com/1016759 paint/invalidation/svg/circle-move-invalidation.svg [ Failure ] # display-locking crbug.com/591099 wpt_internal/display-lock/css-content-visibility/matchable/content-visibility-matchable-005.html [ Failure ] # 10/02/2019 Mark tests as failing. Mostly shapes, slight image differences external/wpt/css/CSS2/text/white-space-bidirectionality-001.xht [ Failure ] -external/wpt/css/css-shapes/spec-examples/shape-outside-018.html [ Failure ] external/wpt/css/css-text/shaping/shaping-024.html [ Failure ] external/wpt/css/css-text/shaping/shaping-025.html [ Failure ] external/wpt/css/css-text/white-space/seg-break-transformation-018.tentative.html [ Failure ] @@ -1220,7 +1156,6 @@ virtual/text-antialias/zwnj-disables-kerning.html [ Failure ] virtual/text-antialias/international/shape-across-elements-simple.html [ Failure ] paint/invalidation/overflow/float-overflow.html [ Failure ] -scrollingcoordinator/non-fast-scrollable-transform-changed.html [ Crash ] svg/zoom/text/zoom-svg-float-border-padding.xml [ Failure ] virtual/forced-high-contrast-colors/fast/css/forced-colors-mode/forced-colors-mode-15.html [ Failure ] virtual/forced-high-contrast-colors/fast/css/forced-colors-mode/backplate/forced-colors-mode-backplate-07.html [ Failure ] @@ -1262,15 +1197,12 @@ crbug.com/1035582 paint/invalidation/outline/transform-focus-ring-repaint.html [ Failure ] crbug.com/1035582 paint/invalidation/scroll/invalidate-caret-in-composited-scrolling-container.html [ Failure ] crbug.com/1035582 paint/invalidation/scroll/invalidate-caret-in-non-composited-scrolling-container.html [ Failure ] -crbug.com/1035582 paint/invalidation/svg/focus-element.html [ Failure ] crbug.com/1035582 paint/invalidation/svg/scrolling-embedded-svg-file-image-repaint-problem.html [ Failure ] crbug.com/1035582 paint/invalidation/table/caret-contenteditable-content-after.html [ Failure ] crbug.com/1035582 external/wpt/css/css-text-decor/text-decoration-subelements-001.html [ Failure ] crbug.com/1035582 paint/background/background-clip-text-descendants.html [ Failure ] crbug.com/1035582 tables/mozilla/bugs/bug2479-3.html [ Failure ] -crbug.com/1035582 fast/hidpi/scrollbar-appearance-increase-device-scale-factor.html [ Failure ] crbug.com/1035582 paint/invalidation/overflow/float-overflow-right.html [ Failure ] -crbug.com/1035582 virtual/prefer_compositing_to_lcd_text/scrollbars/listbox-scrollbar-combinations.html [ Failure ] crbug.com/1035582 virtual/scalefactor150/fast/hidpi/static/calendar-picker-appearance.html [ Failure Timeout ] crbug.com/1035582 http/tests/devtools/sources/debugger-breakpoints/disable-breakpoints.js [ Failure Timeout ] crbug.com/1035582 paint/invalidation/forms/checkbox-focus-by-mouse-then-keydown.html [ Failure ] @@ -1298,9 +1230,6 @@ crbug.com/1074752 external/wpt/css/css-pseudo/active-selection-053.html [ Failure ] crbug.com/1074752 external/wpt/css/css-pseudo/active-selection-054.html [ Failure ] -# Very small layout shift seen, only with LayoutNG disabled. -crbug.com/1100711 external/wpt/layout-instability/ignore-fixed-and-sticky.html [ Failure ] - # TODO(masonfreed) These were previously skipped by the [Skip] on several virtual suites (e.g. controls-refresh/*). crbug.com/1034611 fast/forms/color-scheme/text-selection-outside-control.html [ Skip ] crbug.com/1034611 fast/forms/color-scheme/date/date-appearance-basic.html [ Skip ] @@ -1524,7 +1453,6 @@ crbug.com/591099 external/wpt/css/css-flexbox/abspos/position-absolute-015.html [ Failure ] ### external/wpt/css/css-grid/ -crbug.com/591099 external/wpt/css/css-grid/grid-items/percentage-size-indefinite-replaced.html [ Failure ] crbug.com/667785 external/wpt/css/css-grid/table-grid-item-005.html [ Failure ] ### external/wpt/css/css-highlight-api/ @@ -1551,9 +1479,6 @@ crbug.com/591099 external/wpt/html/links/manifest/mime-type-text-json-manual.html [ Failure ] crbug.com/591099 external/wpt/html/links/manifest/wrong-mime-type-text-plain-manual.html [ Failure ] -### external/wpt/html/semantics/interactive-elements/the-popup-element/ -crbug.com/1178754 external/wpt/html/semantics/interactive-elements/the-popup-element/popup-light-dismiss.tentative.html [ Crash ] - ### external/wpt/layout-instability crbug.com/829028 external/wpt/layout-instability/multicol-000.html [ Failure ] crbug.com/829028 external/wpt/layout-instability/multicol-001.html [ Failure ] @@ -1598,9 +1523,7 @@ crbug.com/591099 external/wpt/appmanifest/shortcuts-member/shortcuts-member-cors-manual.sub.html [ Failure ] crbug.com/591099 external/wpt/appmanifest/shortcuts-member/shortcuts-member-csp-fail-manual.sub.html [ Failure ] crbug.com/591099 external/wpt/appmanifest/shortcuts-member/shortcuts-member-csp-manual.sub.html [ Failure ] -crbug.com/591099 external/wpt/css/css-display/display-contents-dynamic-fieldset-legend-001.html [ Failure ] crbug.com/591099 external/wpt/css/css-flexbox/table-as-item-inflexible-in-column-1.html [ Failure ] -crbug.com/591099 external/wpt/css/css-flexbox/table-as-item-inflexible-in-row-2.html [ Failure ] crbug.com/591099 external/wpt/css/css-flexbox/table-as-item-narrow-content-2.html [ Failure ] crbug.com/591099 external/wpt/css/css-flexbox/table-as-item-stretch-cross-size-2.html [ Failure ] crbug.com/591099 external/wpt/css/css-writing-modes/alt-display-vertical-001-manual.html [ Failure ] @@ -1637,9 +1560,6 @@ crbug.com/591099 external/wpt/css/css-ui/box-sizing-024.html [ Failure ] crbug.com/591099 external/wpt/css/css-ui/box-sizing-025.html [ Failure ] crbug.com/591099 external/wpt/css/cssom/idlharness.html [ Failure ] -crbug.com/591099 external/wpt/scroll-to-text-fragment/iframes.sub.html [ Crash ] -crbug.com/591099 external/wpt/webcodecs/video-decoder.https.any.html [ Failure ] -crbug.com/591099 external/wpt/webcodecs/video-decoder.https.any.worker.html [ Failure ] crbug.com/591099 external/wpt/webcodecs/video-encoder-config.https.any.html [ Failure ] crbug.com/591099 external/wpt/webcodecs/video-encoder-config.https.any.worker.html [ Failure ] crbug.com/591099 fast/replaced/table-percent-width.html [ Failure ] @@ -1647,7 +1567,6 @@ crbug.com/591099 fast/writing-mode/border-image-vertical-lr.html [ Failure ] crbug.com/591099 media/audio-controls-rendering.html [ Failure ] crbug.com/591099 media/media-document-audio-repaint.html [ Failure ] -crbug.com/591099 paint/invalidation/svg/tspan-pattern-update.html [ Failure ] crbug.com/591099 paint/markers/document-markers-font-64px.html [ Failure ] crbug.com/591099 paint/markers/ellipsis-ltr-text-in-ltr-flow-with-markers.html [ Failure ] crbug.com/591099 paint/markers/ellipsis-ltr-text-in-rtl-flow-with-markers.html [ Failure ] @@ -1691,7 +1610,6 @@ crbug.com/591099 fast/forms/time/time-appearance-basic.html [ Failure ] crbug.com/591099 virtual/prerender/wpt_internal/prerender/restriction-encrypted-media.https.html [ Failure ] -crbug.com/591099 virtual/prerender/wpt_internal/prerender/restriction-media-auto-play-attribute.html [ Failure ] crbug.com/591099 virtual/prerender/wpt_internal/prerender/restriction-media-play.html [ Failure ] # unblock wpt-importer @@ -1708,7 +1626,6 @@ crbug.com/591099 external/wpt/css/css-sizing/aspect-ratio/flex-aspect-ratio-028.html [ Failure ] crbug.com/591099 external/wpt/css/css-sizing/aspect-ratio/flex-aspect-ratio-029.html [ Failure ] crbug.com/591099 external/wpt/css/css-sizing/aspect-ratio/flex-aspect-ratio-030.html [ Failure ] -crbug.com/591099 http/tests/devtools/webaudio/graphview-test.js [ Failure ] #unblock wpt-importer crbug.com/591099 external/wpt/css/css-overflow/scrollable-overflow-input-001.html [ Failure ] @@ -1769,7 +1686,6 @@ crbug.com/626703 external/wpt/css/CSS2/borders/border-right-width-applies-to-014.xht [ Failure ] # Failures when enabling CompositeAfterPaint -crbug.com/591099 fast/block/float/float-change-composited-scrolling.html [ Failure ] crbug.com/591099 svg/dom/viewspec-aspectparams.html [ Failure ] crbug.com/591099 svg/dom/viewspec-transformparams.html [ Failure ] crbug.com/591099 svg/dom/viewspec-viewboxparams.html [ Failure ] @@ -1829,12 +1745,9 @@ external/wpt/html/interaction/focus/focusgroup/tentative/grid-navigation/col-wrap-and-row-flow.html [ Failure ] external/wpt/html/interaction/focus/focusgroup/tentative/grid-navigation/col-wrap-only.html [ Failure ] external/wpt/html/interaction/focus/focusgroup/tentative/grid-navigation/css-table.html [ Failure ] -external/wpt/html/interaction/focus/focusgroup/tentative/grid-navigation/css-table-not-focusgroup.html [ Failure ] -external/wpt/html/interaction/focus/focusgroup/tentative/grid-navigation/does-not-wrap-or-flow.html [ Failure ] external/wpt/html/interaction/focus/focusgroup/tentative/grid-navigation/empty-spaces.html [ Failure ] external/wpt/html/interaction/focus/focusgroup/tentative/grid-navigation/flows-in-both-axes.html [ Failure ] external/wpt/html/interaction/focus/focusgroup/tentative/grid-navigation/moves-across-table-sections.html [ Failure ] -external/wpt/html/interaction/focus/focusgroup/tentative/grid-navigation/non-table.html [ Failure ] external/wpt/html/interaction/focus/focusgroup/tentative/grid-navigation/relayout-before-navigation.html [ Failure ] external/wpt/html/interaction/focus/focusgroup/tentative/grid-navigation/row-flow-only.html [ Failure ] external/wpt/html/interaction/focus/focusgroup/tentative/grid-navigation/rowspan.html [ Failure ]
diff --git a/third_party/blink/web_tests/FlagExpectations/disable-site-isolation-trials b/third_party/blink/web_tests/FlagExpectations/disable-site-isolation-trials index 76565c83..98e8c78a 100644 --- a/third_party/blink/web_tests/FlagExpectations/disable-site-isolation-trials +++ b/third_party/blink/web_tests/FlagExpectations/disable-site-isolation-trials
@@ -41,9 +41,6 @@ virtual/fenced-frame-mparch/http/tests/inspector-protocol/fenced-frame/fenced-frame-in-oopif-auto-attach.js [ Skip ] # Fix to unblock wpt-importer -crbug.com/1209223 http/tests/inspector-protocol/fetch/mime-type-sniffing.js [ Failure ] - -# Fix to unblock wpt-importer crbug.com/1209223 external/wpt/html/browsers/browsing-the-web/navigating-across-documents/javascript-url-security-check-multi-globals.sub.html [ Failure ] crbug.com/1209223 external/wpt/html/browsers/browsing-the-web/navigating-across-documents/javascript-url-security-check-same-origin-domain.sub.html [ Failure ] @@ -75,7 +72,6 @@ crbug.com/626703 external/wpt/webrtc/RTCConfiguration-iceTransportPolicy.html [ Timeout ] crbug.com/626703 external/wpt/webrtc-stats/rtp-stats-creation.html [ Crash Failure ] crbug.com/626703 external/wpt/domxpath/xpath-evaluate-crash.html [ Crash ] -crbug.com/626703 virtual/prerender/external/wpt/speculation-rules/prerender/media-autoplay.html [ Failure Timeout ] crbug.com/626703 virtual/prerender/external/wpt/speculation-rules/prerender/restrictions.html [ Failure Timeout ] crbug.com/626703 virtual/system-color-compute/external/wpt/css/css-color/oklch-008.html [ Failure ] crbug.com/626703 external/wpt/css/css-masking/mask-image/mask-composite-1c.html [ Crash Failure ]
diff --git a/third_party/blink/web_tests/FlagExpectations/enable-percent-based-scrolling b/third_party/blink/web_tests/FlagExpectations/enable-percent-based-scrolling deleted file mode 100644 index f437c480..0000000 --- a/third_party/blink/web_tests/FlagExpectations/enable-percent-based-scrolling +++ /dev/null
@@ -1,56 +0,0 @@ -# tags: [ Android Fuchsia Linux Mac Mac10.12 Mac10.13 Win Win7 Win10 ] -# tags: [ Release Debug ] -# results: [ Timeout Crash Pass Failure Slow Skip ] - -# Scrolling tests that are failing when percent-based scrolling feature is enabled - -# external/wpt/css/css-overscroll-behavior -crbug.com/1204176 external/wpt/css/css-overscroll-behavior/overscroll-behavior.html [ Failure ] - -# fast/events/wheel -crbug.com/1204176 fast/events/wheel/wheel-in-scrollbar.html [ Failure ] -crbug.com/1204176 fast/events/wheel/wheelevent-ctrl.html [ Failure ] -# Timeout only for compositor-threaded -crbug.com/1204176 fast/events/wheel/wheel-latched-scroll-node-removed.html [ Pass Timeout ] - -# fast/scrolling -crbug.com/1204176 fast/scrolling/wheel-and-touch-scroll-use-count.html [ Failure ] -crbug.com/1204176 fast/scrolling/fractional-scroll-offset-document.html [ Failure ] -crbug.com/1204176 fast/scrolling/scroll-animation-on-by-default.html [ Failure ] -crbug.com/1204176 fast/scrolling/wheel-scroll-latching-on-scrollbar.html [ Failure ] - -# fast/scrolling/events -crbug.com/1204176 fast/scrolling/events/overscroll-event-fired-to-element-with-overscroll-behavior.html [ Failure Timeout ] -crbug.com/1204176 fast/scrolling/events/overscroll-event-fired-to-scrolled-element.html [ Failure Timeout ] -crbug.com/1204176 fast/scrolling/events/overscroll-event-fired-to-window.html [ Failure Timeout ] - -# fast/scroll-snap/ -crbug.com/1204176 fast/scroll-snap/snaps-after-touchpad-scrolling.html [ Failure ] -# Timeout only for main-threaded -crbug.com/1204176 fast/scroll-snap/snaps-after-scrollbar-scrolling-arrow.html [ Timeout ] - -# http/tests/navigation -crbug.com/1204176 http/tests/navigation/same-document-scroll-position-restore.html [ Timeout ] - -# paint/paintlayer -crbug.com/1204176 paint/paintlayer/scrolling_issues.html [ Failure ] - -# synthetic_gestures -crbug.com/1204176 synthetic_gestures/animated-wheel-tiny-delta.html [ Failure ] -crbug.com/1204176 synthetic_gestures/smooth-scroll-tiny-delta.html [ Failure ] - -# virtual/percent-based-scrolling -crbug.com/1204176 virtual/percent-based-scrolling/max-percent-delta-cross-origin-iframes.html [ Timeout ] - -# fast/hidpi/static -crbug.com/1204176 fast/hidpi/static/gesture-scroll-amount.html [ Failure ] -crbug.com/1204176 fast/hidpi/static/mousewheel-scroll-amount.html [ Failure ] - -# virtual/threaded/fast/events/pinch -crbug.com/1204176 virtual/threaded/fast/events/pinch/gesture-pinch-zoom-scroll-bubble.html [ Timeout ] -crbug.com/1204176 virtual/threaded/fast/events/pinch/pinch-zoom-pan-position-fixed.html [ Failure ] -crbug.com/1204176 virtual/threaded/fast/events/pinch/pinch-zoom-pan-within-zoomed-viewport.html [ Failure ] - -# virtual/threaded-prefer-compositing/fast/scroll-behavior -# Failure only for main-threaded -crbug.com/1204176 virtual/threaded-prefer-compositing/fast/scroll-behavior/first-scroll-runs-on-compositor.html [ Failure Pass ]
diff --git a/third_party/blink/web_tests/FlagExpectations/enable-threaded-compositing b/third_party/blink/web_tests/FlagExpectations/enable-threaded-compositing deleted file mode 100644 index e7a41ba1..0000000 --- a/third_party/blink/web_tests/FlagExpectations/enable-threaded-compositing +++ /dev/null
@@ -1,6 +0,0 @@ -# tags: [ Android Fuchsia Linux Mac Mac10.12 Mac10.13 Win Win7 Win10 ] -# tags: [ Release Debug ] -# results: [ Timeout Crash Pass Failure Slow Skip ] - -# Expectations for EnableThreadedCompositing -[ Debug Linux ] virtual/threaded/external/wpt/web-animations/timing-model/animations/update-playback-rate-zero.html [ Failure ]
diff --git a/third_party/blink/web_tests/FlagExpectations/force-renderer-accessibility b/third_party/blink/web_tests/FlagExpectations/force-renderer-accessibility index de8e037..4a10abed 100644 --- a/third_party/blink/web_tests/FlagExpectations/force-renderer-accessibility +++ b/third_party/blink/web_tests/FlagExpectations/force-renderer-accessibility
@@ -4,37 +4,6 @@ # Expectations for --force-renderer-accessibility # crbug.com/1138028 tracks the removal of these failure expectations -# Crashes -crbug.com/1225856 virtual/focusless-spat-nav/fast/spatial-navigation/focusless/snav-focusless-display-none-editable.html [ Crash ] -virtual/offsetparent-old-behavior/external/wpt/css/css-contain/content-visibility/detach-locked-slot-children-crash.html [ Crash ] - -# Slow -crbug.com/1225893 crbug.com/1126305 virtual/prerender/external/wpt/speculation-rules/prerender/about-blank-iframes.html [ Timeout ] -crbug.com/1225893 crbug.com/1126305 virtual/prerender/external/wpt/speculation-rules/prerender/activation-start.html [ Timeout ] -crbug.com/1225893 crbug.com/1126305 virtual/prerender/external/wpt/speculation-rules/prerender/cross-origin-isolated.https.html [ Timeout ] -crbug.com/1225893 crbug.com/1126305 virtual/prerender/wpt_internal/prerender/purpose-prefetch-header.https.html [ Timeout ] -crbug.com/1225893 crbug.com/1126305 virtual/prerender/wpt_internal/prerender/session-history-subframe-navigation.https.html [ Timeout ] -crbug.com/1225893 crbug.com/1126305 virtual/prerender/wpt_internal/prerender/session-history-subframe-reload.https.html [ Timeout ] -crbug.com/1225893 crbug.com/1126305 virtual/prerender/wpt_internal/prerender/unload-on-prerender-cross-origin-subframe-navigation.html [ Timeout ] -crbug.com/1225893 crbug.com/1126305 virtual/prerender/wpt_internal/prerender/unload-on-prerender-remove-subframe.html [ Timeout ] -crbug.com/1225893 crbug.com/1126305 virtual/prerender/wpt_internal/prerender/unload-on-prerender-same-origin-subframe-navigation.html [ Timeout ] -crbug.com/1225893 crbug.com/1126305 virtual/prerender/wpt_internal/prerender/windowclient-navigate-to-cross-origin-url-on-iframe.https.html [ Timeout ] -crbug.com/1225893 crbug.com/1126305 virtual/prerender/wpt_internal/prerender/windowclient-navigate-to-same-origin-url-on-iframe.https.html [ Timeout ] - -# Intentional failures for focusless spatial navigation. -# Focusless spatial navigation is intentionally disabled when accessibility is turned on. -# * On bots without --force-renderer-accessibility, the tests are able to reset the accessibility context -# and run without any accessibility, in which case the tests pass. -# See https://crrev.com/c/1620345. -# * On bots with --force-rendferer-accessibiity, the tests will fail because of the check in -# IsInAccessibilityMode() In spatial_navigation_controller.cc. -# As this is intentional it is good to test as well via --force-renderer-accessibility. -virtual/focusless-spat-nav/fast/spatial-navigation/focusless/snav-focusless-basic-movement.html [ Failure ] -virtual/focusless-spat-nav/fast/spatial-navigation/focusless/snav-focusless-dont-send-keyboard-events.html [ Failure ] -virtual/focusless-spat-nav/fast/spatial-navigation/focusless/snav-focusless-enter-exit-focus.html [ Failure ] -crbug.com/985520 virtual/focusless-spat-nav/fast/spatial-navigation/focusless/snav-focusless-enter-from-interest.html [ Failure ] -virtual/focusless-spat-nav/fast/spatial-navigation/focusless/snav-focusless-navigate-from-focus.html [ Failure ] - # Unintentional failure external/wpt/accessibility/crashtests/serialize-with-no-document.html [ Skip ] external/wpt/css/css-contain/content-visibility/detach-locked-slot-children-crash.html [ Skip ]
diff --git a/third_party/blink/web_tests/FlagExpectations/highdpi b/third_party/blink/web_tests/FlagExpectations/highdpi index ccc749b..13e86cec 100644 --- a/third_party/blink/web_tests/FlagExpectations/highdpi +++ b/third_party/blink/web_tests/FlagExpectations/highdpi
@@ -1339,10 +1339,8 @@ crbug.com/1107570 tables/mozilla/bugs/bug12910-2.html [ Failure ] crbug.com/1107570 tables/mozilla/bugs/bug157890.html [ Failure ] crbug.com/1107570 fast/writing-mode/english-lr-text.html [ Failure ] -crbug.com/1107570 fast/block/crash-when-element-becomes-positioned-and-doesnt-clear-floating-objects.html [ Failure ] crbug.com/1107570 fast/block/float/floats-offset-image-strict.html [ Failure ] crbug.com/1107570 fast/block/float/logical-bottom-exceeds-layoutunit-max.html [ Failure ] -crbug.com/1107570 fast/block/float/sub-pixel-precision-floats.html [ Failure ] crbug.com/1107570 fast/block/margin-collapse/030.html [ Failure ] crbug.com/1107570 fast/block/margin-collapse/031.html [ Failure ] crbug.com/1107570 fast/block/margin-collapse/038.html [ Failure ] @@ -1353,12 +1351,10 @@ crbug.com/1107570 fast/overflow/002.html [ Failure ] crbug.com/1107570 fast/overflow/006.html [ Failure ] crbug.com/1107570 fast/overflow/overflow-clamp-after-transform-related-content-size-change.html [ Failure ] -crbug.com/1107570 fast/overflow/scroll-div-hide-show.html [ Failure ] crbug.com/1107570 fast/overflow/scrollbar-drag-origin.html [ Failure ] crbug.com/1107570 fast/overflow/unreachable-overflow-rtl-bug.html [ Failure ] crbug.com/1117266 editing/caret/bidi_hit_test_caret_consistency.html [ Failure ] -crbug.com/1117266 editing/caret/caret-height.html [ Failure ] crbug.com/1117266 editing/input/editable-container-with-word-wrap-normal.html [ Failure ] crbug.com/1117266 editing/input/reveal-edit-on-input-vertically.html [ Failure ] crbug.com/1117266 editing/inserting/caret-position.html [ Failure ] @@ -1425,11 +1421,9 @@ crbug.com/1191215 fast/backgrounds/background-attachment-fixed-on-abs-pos.html [ Failure ] -crbug.com/1191215 fast/backgrounds/background-attachment-fixed-squashed.html [ Failure ] crbug.com/1191215 fast/backgrounds/background-cover-rounding.html [ Failure ] crbug.com/1191215 fast/backgrounds/background-opaque-clipped-gradients.html [ Failure ] crbug.com/1191215 fast/block/positioning/offsetLeft-offsetTop-multicolumn.html [ Failure ] -crbug.com/1191215 fast/borders/border-image-fill-inline-no-border.html [ Failure ] crbug.com/1191215 fast/borders/border-image-width-rounding.html [ Failure ] crbug.com/1191215 fast/borders/border-width-below-1.html [ Failure ] crbug.com/1191215 fast/box-shadow/image-box-shadow.html [ Failure ] @@ -1483,8 +1477,6 @@ crbug.com/1191215 fast/table/tbody-background-image-fills-tbody.html [ Failure ] crbug.com/1191215 fast/table/tbody-background-image-repeat-y.html [ Failure ] -crbug.com/1179572 editing/caret/in-multicol-child.html [ Failure ] - crbug.com/1179552 fragmentation/nested-repeating-thead-3.html [ Failure ] crbug.com/1179552 fragmentation/repeating-thead-multiple-tables.html [ Failure ] crbug.com/1179552 fragmentation/single-large-cell-with-header.html [ Failure ] @@ -1526,7 +1518,6 @@ crbug.com/1179572 ietestcenter/css3/flexbox/flexbox-align-center-001.htm [ Failure ] crbug.com/1179572 ietestcenter/css3/flexbox/flexbox-align-center-002.htm [ Failure ] -crbug.com/1179556 paint/caret/multicol_inline_children.html [ Failure ] crbug.com/1179556 paint/invalidation/background/background-scaling.html [ Failure ] crbug.com/1179556 paint/invalidation/caret-composited-scrolled.html [ Failure ] crbug.com/1179556 paint/invalidation/caret-scrolled.html [ Failure ] @@ -1538,7 +1529,6 @@ crbug.com/1179556 paint/invalidation/position/fixed-scale.html [ Failure ] crbug.com/1179556 paint/invalidation/position/relayout-fixed-position-after-scale.html [ Failure ] crbug.com/1179556 paint/invalidation/compositing/repaint-squashed-layer-in-rect.html [ Failure ] -crbug.com/1179556 paint/invalidation/svg/image-animation-with-zoom.html [ Failure ] crbug.com/1179556 paint/invalidation/svg/non-scaling-stroke-change-container-transform.html [ Failure ] crbug.com/1179556 paint/invalidation/table/collapsed-border-cell-change-width-composited-row.html [ Failure ] crbug.com/1179556 paint/invalidation/table/collapsed-border-cell-change-width-composited-section.html [ Failure ] @@ -1592,7 +1582,6 @@ crbug.com/1179565 svg/css/max-width-2.html [ Failure ] crbug.com/1179565 svg/custom/anchor-on-use.svg [ Failure ] crbug.com/1179565 svg/custom/focus-ring-2.svg [ Failure ] -crbug.com/1179565 svg/custom/outline-stacking.svg [ Failure ] crbug.com/1179565 svg/custom/rgba-color-outline.svg [ Failure ] crbug.com/1179565 svg/custom/svg-root-padding-border-margin.html [ Failure ] crbug.com/1179565 svg/dom/filter-reference-in-shadow-tree.html [ Failure ] @@ -1602,7 +1591,6 @@ crbug.com/1179565 svg/filters/feOffset-nonuniform-scale.svg [ Failure ] crbug.com/1179565 svg/foreignObject/repaint-rect-coordinates.html [ Failure ] crbug.com/1179565 svg/foreignObject/transformed-text-invalidation.html [ Failure ] -crbug.com/1179565 svg/in-html/inside-inline-block.html [ Failure ] crbug.com/1179565 svg/markers/marker-orientation-02.svg [ Failure ] crbug.com/1179565 svg/stroke/non-scaling-stroke-gradient-text.html [ Failure ] crbug.com/1179565 svg/stroke/non-scaling-stroke-paintserver-same-as-fill.html [ Failure ] @@ -1703,7 +1691,6 @@ crbug.com/1179554 http/tests/document-policy/document-policy-in-xsl.php [ Timeout ] crbug.com/1179554 http/tests/document-policy/document-policy-report-only-in-xsl.php [ Timeout ] crbug.com/1179554 http/tests/misc/destroy-middle-click-locked-target-crash.html [ Timeout ] -crbug.com/1179565 svg/filters/feDisplacementMap.svg [ Timeout ] crbug.com/1179570 virtual/android/fullscreen/video-controls-timeline.html [ Timeout ] crbug.com/1179570 virtual/off-main-thread-css-paint/http/tests/csspaint/invalidation-background-image.html [ Timeout ] crbug.com/1179570 virtual/off-main-thread-css-paint/http/tests/csspaint/invalidation-border-image.html [ Timeout ] @@ -1713,7 +1700,6 @@ crbug.com/1179570 virtual/scroll-unification/fast/forms/suggestion-picker/month-suggestion-picker-mouse-operations.html [ Timeout ] crbug.com/1179570 virtual/scroll-unification/fast/forms/suggestion-picker/time-suggestion-picker-mouse-operations.html [ Timeout ] crbug.com/1179570 virtual/scroll-unification/fast/forms/suggestion-picker/week-suggestion-picker-mouse-operations.html [ Timeout ] -crbug.com/1179570 virtual/scroll-unification/fast/events/wheel/wheelevent-ctrl.html [ Timeout ] crbug.com/1179570 virtual/scroll-unification/fast/events/wheel/wheelevent-in-scrolling-div.html [ Timeout ] crbug.com/1179570 fast/forms/select-popup/popup-menu-appearance-coarse.html [ Timeout ]
diff --git a/third_party/blink/web_tests/FlagExpectations/layout-ng-fragment-item b/third_party/blink/web_tests/FlagExpectations/layout-ng-fragment-item index 77e9dbc66..2fea8b5 100644 --- a/third_party/blink/web_tests/FlagExpectations/layout-ng-fragment-item +++ b/third_party/blink/web_tests/FlagExpectations/layout-ng-fragment-item
@@ -2,5 +2,3 @@ # results: [ Timeout Crash Pass Failure Slow Skip ] # tags: [ Release Debug ] -crbug.com/982194 external/wpt/webrtc/protocol/video-codecs.https.html [ Failure ] -crbug.com/982194 virtual/webrtc-wpt-plan-b/external/wpt/webrtc/protocol/video-codecs.https.html [ Failure ]
diff --git a/third_party/blink/web_tests/LeakExpectations b/third_party/blink/web_tests/LeakExpectations index 54172128..c6defb3 100644 --- a/third_party/blink/web_tests/LeakExpectations +++ b/third_party/blink/web_tests/LeakExpectations
@@ -15,135 +15,29 @@ crbug.com/786995 virtual/threaded/http/tests/devtools/tracing/timeline-style/timeline-style-recalc-all-invalidator-types.js [ Skip ] -# Requests with keepalive specified will be kept alive even when the frame is -# detached, which means leaks reported by the leak detector are by design. -# Ignore them. -crbug.com/755625 external/wpt/beacon/beacon-error.window.html [ Failure ] -crbug.com/651742 external/wpt/content-security-policy/connect-src/connect-src-beacon-allowed.sub.html [ Failure ] - -crbug.com/1003224 external/wpt/clipboard-apis/async-write-image-read-image.html [ Failure ] - -# These tests crash with the leak detector enabled. Previously, crashes inside -# leak detection were incorrectly hidden with the test passing. -# See https://chromium-review.googlesource.com/c/chromium/src/+/2252943 -crbug.com/867532 external/wpt/workers/modules/dedicated-worker-import-data-url.any.worker.html [ Crash ] -crbug.com/867532 external/wpt/workers/modules/dedicated-worker-import.any.worker.html [ Crash ] -crbug.com/867532 http/tests/workers/worker-usecounter.html [ Crash ] -crbug.com/1098106 virtual/off-main-thread-css-paint/http/tests/csspaint/invalidation-border-image.html [ Crash ] -crbug.com/1098106 virtual/off-main-thread-css-paint/http/tests/csspaint/invalidation-background-image.html [ Crash ] -crbug.com/1098106 virtual/off-main-thread-css-paint/http/tests/csspaint/invalidation-content-image.html [ Crash ] - -# Random timeout -crbug.com/1151861 [ Linux ] external/wpt/workers/semantics/multiple-workers/003.html [ Timeout Crash ] - # ----------------------------------------------------------------- # Flakily leaks # ----------------------------------------------------------------- -crbug.com/780386 external/wpt/html/dom/reflection-grouping.html [ Failure Pass ] - -crbug.com/860117 [ Linux ] editing/pasteboard/drag-drop-iframe-refresh-crash.html [ Pass Failure ] - -crbug.com/809609 [ Linux ] editing/pasteboard/drop-file-svg.html [ Pass Failure ] -crbug.com/809609 [ Linux ] editing/inserting/insert_div_with_style.html [ Pass Failure ] crbug.com/1181667 [ Linux ] external/wpt/css/selectors/focus-visible-011.html [ Failure Pass ] -# ----------------------------------------------------------------- -# Sheriff 2018-04-23 -# ----------------------------------------------------------------- -crbug.com/836278 [ Linux ] external/wpt/html/canvas/offscreen/manual/convert-to-blob/offscreencanvas.convert.to.blob.html [ Pass Failure ] - # Sheriff 2018-08-17 crbug.com/847114 [ Linux ] http/tests/devtools/tracing/decode-resize.js [ Pass Failure ] -# Sheriff 2018-08-29 -crbug.com/878724 [ Linux ] editing/selection/modify_extend/extend_by_character.html [ Pass Failure ] -crbug.com/878724 [ Linux ] editing/selection/modify_move/move_right_word_09_ltr_multi_line.html [ Pass Failure ] - crbug.com/733494 [ Linux ] media/autoplay/document-user-activation.html [ Pass Failure ] -# Sheriff 2019-08-21 -crbug.com/996235 [ Linux ] media/controls/doubletap-to-jump-backwards-at-start.html [ Pass Failure ] - -# Only times out on the leak bots. -crbug.com/998399 [ Linux ] virtual/plz-dedicated-worker/external/wpt/service-workers/service-worker/worker-interception.https.html [ Pass Timeout ] - -crbug.com/769885 [ Linux ] virtual/android/fullscreen/full-screen-frameset.html [ Failure ] crbug.com/769885 [ Linux ] virtual/android/fullscreen/video-scrolled-iframe.html [ Failure ] -# Sheriff 2019-09-04 -crbug.com/1000768 [ Linux ] external/wpt/web-locks/idlharness.tentative.https.any.html [ Pass Failure ] -crbug.com/1000768 [ Linux ] external/wpt/geolocation-API/idlharness.window.html [ Pass Failure ] -crbug.com/1000768 [ Linux ] external/wpt/web-share/idlharness.https.window.html [ Pass Failure ] -crbug.com/1000768 [ Linux ] external/wpt/storage/idlharness.https.any.html [ Pass Failure ] - -# Sheriff 2020-04-06 -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-classic.http-rp/no-referrer/worker-module.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-classic.http-rp/origin/worker-classic.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-classic.http-rp/strict-origin/worker-classic.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-classic.http-rp/strict-origin/worker-module.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-classic.http-rp/unsafe-url/worker-module.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-module.http-rp/no-referrer-when-downgrade/worker-module.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-module.http-rp/no-referrer/worker-classic.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-module.http-rp/no-referrer/worker-module.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-module.http-rp/origin-when-cross-origin/worker-module.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-module.http-rp/same-origin/worker-module.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-module.http-rp/strict-origin-when-cross-origin/worker-module.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-module.http-rp/strict-origin/worker-module.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-classic.http-rp/same-origin/worker-classic.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] virtual/plz-dedicated-worker/external/wpt/referrer-policy/gen/worker-classic.http-rp/strict-origin-when-cross-origin/worker-classic.http.html [ Pass Timeout ] - -# Sheriff 2020-04-23 -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-module.http-rp/same-origin/worker-classic.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-module.http-rp/origin/worker-module.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-module.http-rp/unsafe-url/worker-module.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-classic.http-rp/origin/worker-module.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-classic.http-rp/no-referrer-when-downgrade/worker-module.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-classic.http-rp/unset/worker-module.http.html [ Pass Timeout ] - -# Sheriff 2020-05-06 -crbug.com/1078769 [ Linux ] external/wpt/wasm/jsapi/idlharness.any.html [ Pass Failure ] - -# Sheriff 2020-06-24 -# Also crbug.com/867532 -crbug.com/1098782 [ Linux ] virtual/plz-dedicated-worker/external/wpt/workers/modules/dedicated-worker-import.any.worker.html [ Pass Timeout Crash ] - -# Sheriff 2020-07-14 -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-module.http-rp/strict-origin-when-cross-origin/worker-classic.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-module.http-rp/unsafe-url/worker-classic.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-module.http-rp/unset/worker-module.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-module.http-rp/no-referrer-when-downgrade/worker-classic.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-module.http-rp/origin-when-cross-origin/worker-classic.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-module.http-rp/strict-origin/worker-classic.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-classic.http-rp/strict-origin-when-cross-origin/worker-module.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] virtual/plz-dedicated-worker/external/wpt/referrer-policy/gen/worker-classic.http-rp/unset/worker-classic.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-module.http-rp/origin/worker-classic.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-classic.http-rp/same-origin/worker-module.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-classic.http-rp/origin-when-cross-origin/worker-classic.http.html [ Pass Timeout ] - -# Sheriff 2020-07-15 -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-classic.http-rp/origin-when-cross-origin/worker-module.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-classic.http-rp/no-referrer/worker-classic.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-classic.http-rp/no-referrer-when-downgrade/worker-classic.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-classic.http-rp/unsafe-url/worker-classic.http.html [ Pass Timeout ] -crbug.com/1068175 [ Linux ] external/wpt/referrer-policy/gen/worker-module.http-rp/unset/worker-classic.http.html [ Pass Timeout ] - # This test triggers existing leaky behavior, but this test also catches # a prior crash. crbug.com/1103082 [ Linux ] fast/forms/select/select-change-layout-object-crash.html [ Failure ] -# Sheriff 2020-10-08 -crbug.com/1136690 [ Linux ] http/tests/inspector-protocol/service-worker/service-worker-fetch-async-stacks.js [ Pass Timeout ] - # Sheriff 2021-02-25 crbug.com/1182675 [ Linux ] dom/attr/id-update-map-crash.html [ Failure Pass ] # Sheriff 2021-03-02 crbug.com/1183788 [ Linux ] external/wpt/pointerevents/pointerevent_fractional_coordinates.html?touch [ Pass Failure ] -# Sheriff 2021-05-03 -crbug.com/1197465 [ Linux ] virtual/scroll-unification/fast/events/mouse-cursor-no-mousemove.html [ Pass Failure ] - # Started failing after field trial testing configs were enabled. crbug.com/1219915 [ Linux ] editing/selection/context-menu-text-selection.html [ Failure ] crbug.com/1219915 [ Linux ] editing/selection/readonly-disabled-hittest.html [ Failure ]
diff --git a/third_party/blink/web_tests/MSANExpectations b/third_party/blink/web_tests/MSANExpectations index a1fbbde..1b1f9190 100644 --- a/third_party/blink/web_tests/MSANExpectations +++ b/third_party/blink/web_tests/MSANExpectations
@@ -20,46 +20,22 @@ crbug.com/700795 [ Linux ] http/tests/devtools/animation/animation-transition-setTiming-crash.js [ Skip ] -crbug.com/454267 [ Linux ] virtual/gpu/fast/canvas/canvas-arc-360-winding.html [ Crash ] -crbug.com/454267 [ Linux ] virtual/gpu/fast/canvas/canvas-ellipse-360-winding.html [ Crash ] -crbug.com/522315 [ Linux ] virtual/gpu/fast/canvas/quadraticCurveTo.xml [ Crash ] - crbug.com/708175 [ Linux ] external/wpt/IndexedDB/interleaved-cursors-small.html [ Timeout ] crbug.com/708175 [ Linux ] external/wpt/IndexedDB/interleaved-cursors-large.html [ Timeout ] -crbug.com/701433 [ Linux ] crypto/subtle/worker-subtle-crypto-concurrent.html [ Timeout Pass ] -crbug.com/701563 [ Linux ] external/wpt/svg/interfaces.html [ Timeout Pass ] - - # Times out on MSAN crbug.com/462190 [ Linux ] inspector-protocol/heap-profiler/heap-samples-in-snapshot.js [ Timeout ] -crbug.com/751906 [ Linux ] http/tests/devtools/console/console-correct-suggestions.js [ Timeout Pass ] -crbug.com/811820 [ Linux ] http/tests/devtools/tracing-session-id.js [ Timeout Pass ] - -crbug.com/736370 [ Linux ] external/wpt/editing/run/removeformat.html [ Timeout ] crbug.com/810960 [ Linux ] external/wpt/IndexedDB/nested-cloning-large.html [ Timeout ] crbug.com/736554 [ Linux ] external/wpt/IndexedDB/nested-cloning-large-multiple.html [ Timeout ] -crbug.com/810963 [ Linux ] external/wpt/dom/interfaces.html [ Timeout ] - -# Intentionally failed allocations, via partitionAllocGenericFlags() -crbug.com/577889 [ Linux ] fast/js/typed-array-allocation-failure.html [ Crash ] - # These tests use OpenGl, which crashes on MSAN builds due to missing instrumentation crbug.com/555703 [ Linux ] virtual/media-gpu-accelerated/* [ Skip ] -crbug.com/769729 [ Linux ] paint/invalidation/video-paint-invalidation.html [ Crash ] - # These tests are just a tad bit too slow on MSAN bots and time out. Setting # them as "Slow" doesn't seem to help the problem (see discussion on bug), so # marking them as "Timeout" while crbug.com/729136 is worked out. -crbug.com/729136 [ Linux ] external/wpt/mimesniff/mime-types/parsing.any.html [ Timeout ] -crbug.com/729136 [ Linux ] external/wpt/mimesniff/mime-types/parsing.any.worker.html [ Timeout ] crbug.com/729136 [ Linux ] fast/css/css-selector-deeply-nested.html [ Timeout ] -crbug.com/729136 [ Linux ] http/tests/devtools/forced-layout-in-microtask.js [ Timeout ] -crbug.com/729136 [ Linux ] http/tests/devtools/tracing/timeline-xhr-response-type-blob-event.js [ Timeout ] -crbug.com/729136 [ Linux ] http/tests/devtools/elements/styles-4/styles-should-not-force-sync-style-recalc.js [ Timeout ] crbug.com/729136 [ Linux ] webaudio/mixing.html [ Timeout ] # Tests timing out on WebKit Linux Trusty MSAN @@ -78,50 +54,18 @@ # The following test is flaky and timing out on chromium.webkit/WebKit Linux Trusty MSAN. crbug.com/851497 http/tests/devtools/tracing/timeline-style/timeline-style-recalc-all-invalidator-types.js [ Pass Timeout ] -crbug.com/862750 [ Linux ] inspector-protocol/memory/sampling-native-profile-blink-gc.js [ Pass Crash ] - crbug.com/813547 [ Linux ] webaudio/BiquadFilter/tail-time-lowpass.html [ Pass Failure Timeout ] crbug.com/856601 [ Linux ] fast/css/visited-link-hang.html [ Pass Timeout ] -crbug.com/856601 [ Linux ] http/tests/devtools/elements/styles-4/styles-inline-element-style-changes-should-not-force-style-recalc.js [ Pass Timeout ] -crbug.com/856601 [ Linux ] external/wpt/event-timing/retrievability.html [ Pass Timeout ] # Flaky-timeout on MSAN; incorrectly attributed to crbug.com/856601 -crbug.com/856601 [ Linux ] external/wpt/dom/nodes/Element-classlist.html [ Pass Timeout ] crbug.com/856601 [ Linux ] fast/js/toString-stack-overflow.html [ Pass Timeout ] -crbug.com/856601 [ Linux ] external/wpt/import-maps/fallback.sub.tentative.html [ Pass Timeout ] - -# Disabled by sheriff due to test crash -crbug.com/896068 [ Linux ] webaudio/AudioBuffer/huge-buffer.html [ Crash ] -crbug.com/896068 [ Linux ] webaudio/dom-exceptions.html [ Pass Crash ] - -# Sheriff 2018-11-22 -crbug.com/856601 [ Linux ] http/tests/devtools/elements/elements-save-to-temp-var.js [ Pass Timeout ] - -# Sheriff 2018-12-13 -crbug.com/914900 [ Linux ] http/tests/devtools/network/preview-searchable.js [ Pass Timeout ] # Sheriff 2019-02-13 crbug.com/931660 [ Linux ] fast/history/replacestate-nocrash.html [ Pass Timeout ] -# Sheriff 2019-06-27 -crbug.com/856601 [ Linux ] external/wpt/IndexedDB/nested-cloning-large-multiple.any.html [ Pass Timeout ] -crbug.com/856601 [ Linux ] external/wpt/IndexedDB/nested-cloning-large-multiple.any.serviceworker.html [ Pass Timeout ] -crbug.com/856601 [ Linux ] external/wpt/IndexedDB/nested-cloning-large-multiple.any.sharedworker.html [ Pass Timeout ] -crbug.com/856601 [ Linux ] external/wpt/IndexedDB/nested-cloning-large-multiple.any.worker.html [ Pass Timeout ] -crbug.com/856601 [ Linux ] external/wpt/IndexedDB/nested-cloning-large.any.html [ Pass Timeout ] -crbug.com/856601 [ Linux ] external/wpt/IndexedDB/nested-cloning-large.any.serviceworker.html [ Pass Timeout ] -crbug.com/856601 [ Linux ] external/wpt/IndexedDB/nested-cloning-large.any.sharedworker.html [ Pass Timeout ] -crbug.com/856601 [ Linux ] external/wpt/IndexedDB/nested-cloning-large.any.worker.html [ Pass Timeout ] -crbug.com/856601 [ Linux ] external/wpt/IndexedDB/nested-cloning-small.any.serviceworker.html [ Pass Timeout ] - -# Sheriff 2019-06-28 -crbug.com/856601 [ Linux ] http/tests/devtools/indexeddb/live-update-indexeddb-content.js [ Pass Timeout ] -crbug.com/856601 [ Linux ] http/tests/devtools/indexeddb/live-update-indexeddb-list.js [ Pass Timeout ] - # Time out on MSAN crbug.com/856601 [ Linux ] webaudio/Analyser/realtimeanalyser-freq-data.html [ Pass Timeout ] -crbug.com/993953 [ Linux ] http/tests/devtools/wasm-isolated-code-cache/wasm-cache-test.js [ Pass Timeout ] # Sheriff 2019-11-11 @@ -131,41 +75,18 @@ # Sheriff 2020-01-10 crbug.com/1041052 [ Linux ] external/wpt/html/canvas/offscreen/manual/filter/offscreencanvas.filter.w.html [ Timeout ] -crbug.com/1041052 [ Linux ] external/wpt/html/canvas/element/fill-and-stroke-styles/canvas_colorsandstyles_createlineargradient_001.htm [ Timeout ] # Sheriff 2020-02-10 crbug.com/1050559 [ Linux ] external/wpt/WebCryptoAPI/derive_bits_keys/hkdf.https.any.worker.html?1-1000 [ Skip ] -# Sheriff 2020-10-05 -crbug.com/1134580 [ Linux ] virtual/eye-dropper/http/tests/eye-dropper/color-picker-show-eye-dropper.html [ Pass Timeout ] - -# Sheriff 2020-11-25 -crbug.com/1152088 [ Linux ] fast/dom/cssTarget-crash.html [ Pass Timeout ] - # Flaky timeouts on MSan. crbug.com/1174822 [ Linux ] http/tests/mojo/bindings-lite-sw.https.html [ Pass Timeout ] -# Sheriff 2021-02-11 -crbug.com/1177358 [ Linux ] http/tests/devtools/console/console-viewport-indices.js [ Pass Timeout ] -crbug.com/1177358 [ Linux ] http/tests/devtools/console/console-search-reveals-messages.js [ Pass Timeout ] - # Sheriff 2021-02-18 -crbug.com/1179829 [ Linux ] http/tests/devtools/a11y-axe-core/sources/scope-pane-a11y-test.js [ Pass Timeout ] -crbug.com/1179829 [ Linux ] http/tests/devtools/console/console-log-linkify-stack-in-errors.js [ Pass Timeout ] crbug.com/1179829 [ Linux ] http/tests/devtools/sources/debugger-pause/pause-on-elements-panel.js [ Pass Timeout ] -# Sheriff 2021-03-05 -crbug.com/1179829 [ Linux ] http/tests/devtools/console/console-viewport-control.js [ Pass Timeout ] -crbug.com/1179829 [ Linux ] http/tests/devtools/console/viewport-testing/console-stick-to-bottom-expand-object.js [ Pass Timeout ] -crbug.com/1179829 [ Linux ] http/tests/devtools/console/console-viewport-selection.js [ Pass Timeout ] - # Sheriff 2021-03-22 -crbug.com/1179829 [ Linux ] http/tests/devtools/console/console-format.js [ Pass Timeout ] crbug.com/1179829 [ Linux ] http/tests/devtools/tracing/console-timeline.js [ Pass Timeout ] -crbug.com/1179829 [ Linux ] http/tests/devtools/console/console-viewport-stick-to-bottom-onload.js [ Pass Timeout ] - -# Sheriff 2021-04-22 -crbug.com/1201807 [ Linux ] virtual/feature-policy-permissions/external/wpt/mediacapture-streams/MediaStreamTrack-MediaElement-disabled-video-is-black.https.html [ Pass Timeout ] # Sheriff 2021-05-31 crbug.com/1214884 [ Linux ] external/wpt/html/webappapis/scripting/events/event-handler-attributes-body-window.html [ Pass Timeout ] @@ -173,8 +94,6 @@ # Sheriff 2021-06-02 crbug.com/1215390 [ Linux ] external/wpt/pointerevents/pointerevent_pointerId_scope.html [ Pass Failure Timeout ] -crbug.com/1215632 [ Linux ] external/wpt/html/webappapis/scripting/events/event-handler-attributes-frameset-window.html [ Pass Timeout ] -crbug.com/1215632 [ Linux ] external/wpt/html/webappapis/scripting/events/event-handler-attributes-windowless-body.html [ Pass Timeout ] # Flaking on WebKit Linux MSAN crbug.com/1126305 [ Linux ] virtual/prerender/external/wpt/speculation-rules/prerender/fetch-blob.html [ Skip ]
diff --git a/third_party/blink/web_tests/SlowTests b/third_party/blink/web_tests/SlowTests index dc08da3..78a384c 100644 --- a/third_party/blink/web_tests/SlowTests +++ b/third_party/blink/web_tests/SlowTests
@@ -64,8 +64,6 @@ crbug.com/451577 [ Debug ] fast/dom/gc-treescope.html [ Slow ] crbug.com/451577 [ Debug ] fast/frames/calculate-round.html [ Slow ] -crbug.com/237245 [ Debug Win7 ] editing/selection/programmatic-selection-on-mac-is-directionless.html [ Slow ] - # Most DevTools tests are slow in Debug. webkit.org/b/90488 [ Debug ] http/tests/devtools/* [ Slow ] webkit.org/b/90488 [ Debug ] inspector-protocol/* [ Slow ] @@ -77,9 +75,6 @@ # DevTools tests cause flakes on slow hardware in Release as well. crbug.com/1063051 [ Release ] http/tests/devtools/* [ Slow ] crbug.com/420008 virtual/threaded/http/tests/devtools/tracing/* [ Slow ] -crbug.com/902685 virtual/not-split-http-cache-not-site-per-process/http/tests/devtools/isolated-code-cache/* [ Slow ] -crbug.com/902685 virtual/wasm-site-isolated-code-cache/http/tests/devtools/wasm-isolated-code-cache/wasm-cache-test.js [ Slow ] -crbug.com/902685 virtual/split-http-cache-not-site-per-process/http/tests/devtools/isolated-code-cache/* [ Slow ] # Misc DevTools tests that are slow crbug.com/243492 inspector-protocol/injected-script-discard.js [ Slow ] crbug.com/678482 http/tests/devtools/debugger/fetch-breakpoints.js [ Slow ] @@ -133,8 +128,6 @@ crbug.com/504703 inspector-protocol/debugger/debugger-step-into-dedicated-worker.js [ Slow ] -crbug.com/419993 [ Debug ] fast/css/giant-stylesheet-crash.html [ Slow ] - crbug.com/331186 [ Debug ] css3/flexbox/position-absolute-child.html [ Slow ] crbug.com/362509 [ Debug ] fast/parser/xml-error-adopted.xml [ Slow ] @@ -155,10 +148,6 @@ crbug.com/606649 fast/dom/gc-dom-tree-lifetime.html [ Slow ] -# Slow on Win Debug in part due to incremental linking. -crbug.com/647192 [ Debug Win ] fast/css3-text/css3-word-break/word-break-all-ascii.html [ Slow ] -crbug.com/948670 [ Debug Mac10.13 ] fast/css3-text/css3-word-break/word-break-all-ascii.html [ Slow ] - # Slow on many platforms. crbug.com/866165 webexposed/global-interface-listing.html [ Slow ] @@ -267,8 +256,6 @@ crbug.com/866850 [ Mac ] virtual/gpu/fast/canvas/canvas-blending-color-over-pattern.html [ Slow ] crbug.com/866850 [ Linux ] virtual/gpu/fast/canvas/canvas-blending-gradient-over-image.html [ Slow ] crbug.com/866850 [ Mac ] virtual/gpu/fast/canvas/canvas-blending-gradient-over-image.html [ Slow ] -crbug.com/866850 [ Linux ] virtual/gpu/fast/canvas/canvas-blending-gradient-over-pattern.html [ Slow ] -crbug.com/866850 [ Mac ] virtual/gpu/fast/canvas/canvas-blending-gradient-over-pattern.html [ Slow ] crbug.com/866850 [ Linux ] virtual/gpu/fast/canvas/canvas-blending-image-over-gradient.html [ Slow ] crbug.com/866850 [ Mac ] virtual/gpu/fast/canvas/canvas-blending-image-over-gradient.html [ Slow ] crbug.com/866850 [ Linux ] virtual/gpu/fast/canvas/canvas-blending-image-over-image.html [ Slow ] @@ -354,7 +341,6 @@ crbug.com/874695 fast/webgl/canvas-toDataURL-crash.html [ Slow ] crbug.com/874695 fast/webgl/texImage-imageBitmap-from-blob-resize.html [ Slow ] crbug.com/874695 fast/webgl/texImage-imageBitmap-from-canvas-resize.html [ Slow ] -crbug.com/874695 fast/webgl/texImage-imageBitmap-from-imageData-resize.html [ Slow ] crbug.com/874695 fast/webgl/texImage-imageBitmap-from-offscreen-canvas-resize.html [ Slow ] crbug.com/874695 fast/webgl/texImage-imageBitmap-from-video-resize.html [ Slow ] crbug.com/874695 fast/webgl/webgl-composite-modes.html [ Slow ] @@ -497,11 +483,6 @@ crbug.com/874695 virtual/threaded/synthetic_gestures/synthetic-pinch-zoom-gesture-touchpad-zoom-in-slow.html [ Slow ] crbug.com/874695 virtual/threaded/synthetic_gestures/synthetic-pinch-zoom-gesture-touchscreen-zoom-in-slow-desktop.html [ Slow ] crbug.com/874695 virtual/threaded/synthetic_gestures/synthetic-pinch-zoom-gesture-touchscreen-zoom-in-slow.html [ Slow ] -crbug.com/874695 wpt_internal/bluetooth/server/connect/garbage-collection-ran-during-error.html [ Slow ] -crbug.com/874695 wpt_internal/bluetooth/server/disconnect/disconnect-fires-event.html [ Slow ] -crbug.com/874695 wpt_internal/bluetooth/server/getPrimaryService/gen-device-goes-out-of-range.html [ Slow ] -crbug.com/874695 wpt_internal/bluetooth/server/getPrimaryService/gen-reconnect-during-error.html [ Slow ] -crbug.com/874695 wpt_internal/bluetooth/server/getPrimaryServices/gen-delayed-discovery-service-found-with-uuid.html [ Slow ] crbug.com/868956 virtual/gpu/fast/canvas/canvas-composite-video-shadow.html [ Slow ] @@ -514,8 +495,6 @@ crbug.com/914981 [ Mac ] media/controls/overflow-menu-pointer-selection.html [ Slow ] crbug.com/914981 [ Mac ] fast/events/no-fake-mousemove.html [ Slow ] -crbug.com/951895 [ Debug Mac ] transforms/2d/transform-2d.html [ Slow ] - crbug.com/980804 virtual/threaded-prefer-compositing/fast/scrolling/scrollbars/mouse-autoscrolling-on-scrollbar.html [ Slow ] crbug.com/983642 virtual/gpu/fast/canvas/canvas-composite-alpha.html [ Slow ] @@ -589,7 +568,6 @@ crbug.com/983788 http/tests/cookies/same-site/popup-cross-site.https.html [ Slow ] crbug.com/1081237 [ Mac ] virtual/threaded-prefer-compositing/fast/scrolling/events/overscroll-event-fired-to-element-with-overscroll-behavior.html [ Slow ] crbug.com/1049641 http/tests/devtools/sources/debugger/debugger-disable-enable.js [ Slow ] -crbug.com/665577 virtual/threaded-prefer-compositing/fast/scroll-behavior/overflow-scroll-root-frame-animates.html [ Slow ] crbug.com/947951 [ Win ] external/wpt/pointerevents/pointerevent_touch-action-inherit_child-auto-child-none_touch.html [ Slow ] crbug.com/626703 [ Mac ] external/wpt/preload/preload-with-type.html [ Slow ] crbug.com/626703 [ Mac ] external/wpt/html/semantics/embedded-content/media-elements/track/track-element/track-mode.html [ Slow ] @@ -601,8 +579,6 @@ #crbug.com/765738 [ Linux Win Mac ] http/tests/wasm/wasm_remote_postMessage_test.https.html [ Slow ] crbug.com/678346 [ Debug ] fast/dom/shadow/selections-in-shadow.html [ Slow ] crbug.com/678346 [ Debug Mac ] storage/indexeddb/index-cursor.html [ Slow ] -crbug.com/678346 [ Debug Win7 ] storage/indexeddb/index-cursor.html [ Slow ] -crbug.com/757955 [ Debug Win7 ] http/tests/devtools/sources/debugger-pause/pause-on-elements-panel.js [ Slow ] crbug.com/799619 [ Debug ] http/tests/devtools/profiler/heap-snapshot-inspect-dom-wrapper.js [ Slow ] ###crbug.com/849979 media/video-layer-crash.html [ Slow ] crbug.com/831673 http/tests/devtools/reveal-objects.js [ Slow ] @@ -618,7 +594,6 @@ crbug.com/945774 external/wpt/content-security-policy/frame-ancestors/frame-ancestors-nested-cross-in-same-star-allow.html [ Slow ] crbug.com/946714 [ Release ] http/tests/devtools/elements/styles-4/styles-live-locations-leak.js [ Slow ] crbug.com/947383 inspector-protocol/css/reattach-after-editing-styles.js [ Slow ] -crbug.com/947023 external/wpt/fetch/sec-metadata/report.tentative.https.sub.html [ Slow ] crbug.com/949167 external/wpt/html/semantics/links/links-created-by-a-and-area-elements/target_blank_implicit_noopener.html [ Slow ] crbug.com/949207 external/wpt/html/semantics/links/links-created-by-a-and-area-elements/target_blank_implicit_noopener_base.html [ Slow ] #crbug.com/959002 crbug.com/959042 http/tests/devtools/elements/styles-1/color-aware-property-value-edit.js [ Slow ] @@ -636,14 +611,12 @@ crbug.com/981331 fast/forms/form-submission-create-crash.xhtml [ Slow ] crbug.com/982290 [ Win ] http/tests/devtools/elements/styles-4/styles-do-not-detach-sourcemap-on-edits.js [ Slow ] crbug.com/986477 [ Win ] external/wpt/cookies/path/match.html [ Slow ] -crbug.com/989014 [ Debug Linux ] external/wpt/cookie-store/serviceworker_cookiechange_eventhandler_single_subscription.tentative.https.any.serviceworker.html [ Slow ] crbug.com/991243 [ Linux ] external/wpt/workers/semantics/multiple-workers/003.html [ Slow ] crbug.com/999799 [ Mac ] external/wpt/html/rendering/dimension-attributes.html [ Slow ] crbug.com/999799 [ Linux ] external/wpt/html/rendering/dimension-attributes.html [ Slow ] crbug.com/990900 external/wpt/cookie-store/idlharness.tentative.https.any.serviceworker.html [ Slow ] crbug.com/1014327 [ Mac ] external/wpt/preload/onerror-event.html [ Slow ] crbug.com/1017626 [ Linux ] external/wpt/compat/idlharness.window.html [ Slow ] -crbug.com/925325 [ Win ] storage/indexeddb/index-population.html [ Slow ] crbug.com/1019662 external/wpt/html/dom/idlharness.worker.html [ Slow ] crbug.com/1032451 virtual/threaded-no-composited-antialiasing/animations/stability/animation-iteration-event-destroy-renderer.html [ Slow ] crbug.com/1026712 [ Mac ] fast/forms/time-multiple-fields/time-multiple-fields-stepup-stepdown-from-renderer-hour.html [ Slow ] @@ -654,7 +627,6 @@ crbug.com/1044715 [ Linux ] external/wpt/pointerevents/pointerevent_touch-action-inherit_parent-none_touch.html [ Slow ] crbug.com/1044715 [ Win ] external/wpt/pointerevents/pointerevent_touch-action-inherit_child-pan-x-child-pan-x_touch.html [ Slow ] crbug.com/1044715 [ Linux ] external/wpt/pointerevents/pointerevent_touch-action-inherit_child-pan-x-child-pan-x_touch.html [ Slow ] -crbug.com/989665 [ Win ] virtual/plz-dedicated-worker/external/wpt/resource-timing/resource_timing_buffer_full_eventually.html [ Slow ] crbug.com/1043396 http/tests/devtools/network/network-eventsource.js [ Slow ] crbug.com/1043381 [ Release Win ] http/tests/devtools/elements/highlight/highlight-node-scroll.js [ Slow ] crbug.com/1043381 [ Mac Release ] http/tests/devtools/elements/highlight/highlight-node-scroll.js [ Slow ] @@ -673,7 +645,6 @@ crbug.com/1043785 [ Release ] http/tests/devtools/elements/edit/switch-panels-while-editing-as-html.js [ Slow ] crbug.com/1043792 [ Release Win ] http/tests/devtools/template-content-inspect-crash.js [ Slow ] crbug.com/1043792 [ Mac Release ] http/tests/devtools/template-content-inspect-crash.js [ Slow ] -crbug.com/1043893 [ Debug Mac10.13 ] webexposed/global-interface-listing-dedicated-worker.html [ Slow ] crbug.com/1043893 [ Release ] webexposed/global-interface-listing-dedicated-worker.html [ Slow ] crbug.com/1043920 [ Release Win ] http/tests/devtools/stylesheet-source-mapping.js [ Slow ] crbug.com/1043920 [ Mac Release ] http/tests/devtools/stylesheet-source-mapping.js [ Slow ] @@ -746,7 +717,6 @@ crbug.com/1176802 [ Debug ] external/wpt/feature-policy/feature-policy-frame-policy-timing.https.sub.html [ Slow ] crbug.com/1176802 [ Debug ] external/wpt/permissions-policy/permissions-policy-frame-policy-timing.https.sub.html [ Slow ] crbug.com/1044825 http/tests/devtools/network/resource-priority.js [ Slow ] -crbug.com/1097810 [ Debug Mac10.13 ] external/wpt/editing/other/white-spaces-after-execCommand-delete.tentative.html [ Slow ] crbug.com/1105270 [ Mac10.15 ] fast/events/open-window-from-another-frame.html [ Slow ] crbug.com/1046784 http/tests/devtools/sources/source-frame-toolbar-items.js [ Slow ] crbug.com/1046784 http/tests/devtools/profiler/cpu-profiler-bottom-up-large-tree-search.js [ Slow ] @@ -755,7 +725,6 @@ crbug.com/1145424 [ Linux ] http/tests/devtools/sources/debugger-ui/reveal-execution-line.js [ Slow ] crbug.com/1145424 [ Win ] http/tests/devtools/sources/debugger-ui/reveal-execution-line.js [ Slow ] crbug.com/1145641 external/wpt/requestidlecallback/callback-invoked.html [ Slow ] -crbug.com/1146221 [ Linux ] http/tests/devtools/sources/debugger-ui/debugger-inline-values.js [ Slow ] crbug.com/1182691 external/wpt/webcodecs/audio-encoder.https.any.html [ Slow ] crbug.com/1182691 external/wpt/webcodecs/video-encoder.https.any.html [ Slow ] crbug.com/1182691 external/wpt/webcodecs/video-encoder.https.any.worker.html [ Slow ] @@ -767,8 +736,6 @@ crbug.com/1186753 virtual/threaded-prefer-compositing/fast/scroll-snap/snaps-after-scrollbar-scrolling-tap.html [ Slow ] crbug.com/1186753 virtual/threaded-prefer-compositing/fast/scroll-snap/animate-fling-to-snap-points-2.html [ Slow ] -crbug.com/1198043 fast/multicol/nested-very-tall-inside-short-crash.html [ Slow ] - # Mac11 IDB timeouts crbug.com/1195814 [ Mac11 ] external/wpt/clear-site-data/storage.https.html [ Slow ] crbug.com/1195814 [ Mac11 ] external/wpt/file-system-access/local_FileSystemBaseHandle-IndexedDB-manual.https.html [ Slow ] @@ -782,11 +749,7 @@ crbug.com/1195814 [ Mac11 ] external/wpt/IndexedDB/idbindex_getAll.html [ Slow ] crbug.com/1195814 [ Mac11 ] external/wpt/IndexedDB/idbindex_getAllKeys.html [ Slow ] crbug.com/1195814 [ Mac11 ] external/wpt/IndexedDB/idbindex-query-exception-order.html [ Slow ] -crbug.com/1195814 [ Mac11 ] external/wpt/IndexedDB/idbindex-rename-errors.html [ Slow ] crbug.com/1195814 [ Mac11 ] external/wpt/IndexedDB/idbindex_tombstones.any.html [ Slow ] -crbug.com/1195814 [ Mac11 ] external/wpt/IndexedDB/idbindex_tombstones.any.worker.html [ Slow ] -crbug.com/1195814 [ Mac11 ] external/wpt/IndexedDB/idbobjectstore_putall.tentative.any.html [ Slow ] -crbug.com/1195814 [ Mac11 ] external/wpt/IndexedDB/idbobjectstore_putall.tentative.any.worker.html [ Slow ] crbug.com/1195814 [ Mac11 ] external/wpt/IndexedDB/idbtransaction_objectStoreNames.html [ Slow ] crbug.com/1195814 [ Mac11 ] external/wpt/IndexedDB/keygenerator-explicit.html [ Slow ] crbug.com/1195814 [ Mac11 ] external/wpt/IndexedDB/key-generators/reading-autoincrement-indexes.any.html [ Slow ] @@ -796,9 +759,7 @@ crbug.com/1195814 [ Mac11 ] external/wpt/IndexedDB/key-generators/reading-autoincrement-indexes-cursors.any.worker.html [ Slow ] crbug.com/1195814 [ Mac11 ] external/wpt/IndexedDB/key-generators/reading-autoincrement-store.any.serviceworker.html [ Slow ] crbug.com/1195814 [ Mac11 ] external/wpt/IndexedDB/keypath-special-identifiers.htm [ Slow ] -crbug.com/1195814 [ Mac11 ] storage/indexeddb/dispatch-events.html [ Slow ] crbug.com/1195814 [ Mac11 ] storage/indexeddb/key-generator.html [ Slow ] -crbug.com/1195814 [ Mac11 ] storage/indexeddb/odd-strings.html [ Slow ] crbug.com/1263580 editing/deleting/delete-many-lines-of-text.html [ Slow ]
diff --git a/third_party/blink/web_tests/TestExpectations b/third_party/blink/web_tests/TestExpectations index 34ed594..26c210c 100644 --- a/third_party/blink/web_tests/TestExpectations +++ b/third_party/blink/web_tests/TestExpectations
@@ -44,13 +44,6 @@ # WPT HTTP/2 is not fully supported by run_web_tests. crbug.com/1048761 external/wpt/infrastructure/server/http2-websocket.sub.h2.any.html [ Failure ] -crbug.com/1048761 [ Fuchsia ] external/wpt/infrastructure/server/http2-websocket.sub.h2.any.worker.html [ Failure ] -crbug.com/1048761 [ Linux ] external/wpt/infrastructure/server/http2-websocket.sub.h2.any.worker.html [ Failure ] -crbug.com/1048761 [ Mac10.12 ] external/wpt/infrastructure/server/http2-websocket.sub.h2.any.worker.html [ Failure ] -crbug.com/1048761 [ Mac10.13 ] external/wpt/infrastructure/server/http2-websocket.sub.h2.any.worker.html [ Failure ] -crbug.com/1048761 [ Mac10.14 ] external/wpt/infrastructure/server/http2-websocket.sub.h2.any.worker.html [ Failure ] -crbug.com/1048761 [ Mac10.15 ] external/wpt/infrastructure/server/http2-websocket.sub.h2.any.worker.html [ Failure ] -crbug.com/1048761 [ Mac11 ] external/wpt/infrastructure/server/http2-websocket.sub.h2.any.worker.html [ Failure ] crbug.com/1048761 [ Win ] external/wpt/infrastructure/server/http2-websocket.sub.h2.any.worker.html [ Failure ] crbug.com/1048761 external/wpt/infrastructure/server/wpt-server-wpt-flags.sub.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/infrastructure/server/wpt-server-wpt-flags.sub.html?wpt_flags=https [ Failure ] @@ -61,7 +54,6 @@ crbug.com/1048761 external/wpt/websockets/constructor/002.html?wss [ Failure Pass ] crbug.com/1048761 external/wpt/websockets/cookies/001.html [ Failure Pass ] crbug.com/1048761 external/wpt/websockets/cookies/004.html [ Failure Pass ] -crbug.com/1048761 external/wpt/websockets/cookies/004.html?wss [ Failure Pass ] crbug.com/1048761 external/wpt/websockets/cookies/005.html [ Failure Pass ] crbug.com/1048761 external/wpt/websockets/interfaces/WebSocket/close/close-connecting.html?wss [ Failure Pass ] crbug.com/1048761 external/wpt/websockets/interfaces/WebSocket/close/close-nested.html?wss [ Failure Pass ] @@ -155,7 +147,6 @@ crbug.com/1254945 external/wpt/html/semantics/embedded-content/media-elements/loading-the-media-resource/resource-selection-invoke-set-src-not-in-document.html [ Failure Pass ] crbug.com/1254945 external/wpt/html/semantics/embedded-content/media-elements/loading-the-media-resource/resource-selection-invoke-set-src.html [ Failure Pass ] crbug.com/1254945 external/wpt/html/semantics/embedded-content/media-elements/loading-the-media-resource/resource-selection-remove-source.html [ Failure Pass ] -crbug.com/1254945 external/wpt/html/semantics/embedded-content/media-elements/loading-the-media-resource/resource-selection-remove-src.html [ Failure Pass ] crbug.com/1254945 external/wpt/html/semantics/embedded-content/media-elements/track/track-element/track-selection-metadata.html [ Failure Pass ] crbug.com/1254945 external/wpt/html/semantics/embedded-content/media-elements/track/track-element/track-cues-cuechange.html [ Failure ] crbug.com/1254945 external/wpt/html/semantics/embedded-content/media-elements/track/track-element/track-cues-enter-exit.html [ Failure Pass ] @@ -345,50 +336,23 @@ crbug.com/1093709 external/wpt/html/canvas/offscreen/manual/the-offscreen-canvas/offscreencanvas.resize.html [ Failure Pass ] crbug.com/1243128 [ Win ] external/wpt/html/canvas/element/wide-gamut-canvas/2d.color.space.p3.fillText.html [ Failure ] crbug.com/1243128 [ Win ] external/wpt/html/canvas/element/wide-gamut-canvas/2d.color.space.p3.fillText.shadow.html [ Failure ] -crbug.com/1170062 [ Linux ] external/wpt/html/canvas/element/manual/shadows/canvas_shadows_001.htm [ Pass Timeout ] -crbug.com/1170062 [ mac ] external/wpt/html/canvas/element/manual/shadows/canvas_shadows_001.htm [ Pass Timeout ] crbug.com/1170337 [ Mac ] external/wpt/html/canvas/element/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.small.html [ Pass Timeout ] -crbug.com/1170337 [ Mac ] external/wpt/html/canvas/offscreen/text/2d.text.draw.fill.maxWidth.NaN.html [ Pass Timeout ] -crbug.com/1170337 [ Mac ] external/wpt/html/canvas/offscreen/text/2d.text.draw.fill.maxWidth.small.html [ Pass Timeout ] -crbug.com/1170337 [ Mac ] external/wpt/html/canvas/offscreen/text/2d.text.draw.fill.maxWidth.zero.html [ Pass Timeout ] crbug.com/1170337 [ Mac ] external/wpt/html/canvas/offscreen/text/2d.text.draw.fill.maxWidth.small.worker.html [ Pass Timeout ] -crbug.com/1170337 [ Mac ] external/wpt/html/canvas/offscreen/text/2d.text.draw.fill.maxWidth.negative.html [ Pass Timeout ] -crbug.com/1170337 [ Mac ] external/wpt/html/canvas/element/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.fillText.html [ Pass Timeout ] crbug.com/1170337 [ Mac ] external/wpt/html/canvas/element/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.NaN.html [ Pass Timeout ] crbug.com/1170337 [ Mac ] external/wpt/html/canvas/element/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.negative.html [ Pass Timeout ] -crbug.com/1170337 [ Mac ] external/wpt/html/canvas/offscreen/text/2d.text.draw.fill.maxWidth.negative.worker.html [ Pass Timeout ] crbug.com/1170337 [ Mac ] external/wpt/html/canvas/element/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.zero.html [ Pass Timeout ] -crbug.com/1170337 [ Linux ] external/wpt/html/canvas/element/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.small.html [ Pass Timeout ] -crbug.com/1170337 [ Linux ] external/wpt/html/canvas/offscreen/text/2d.text.draw.fill.maxWidth.NaN.html [ Pass Timeout ] -crbug.com/1170337 [ Linux ] external/wpt/html/canvas/offscreen/text/2d.text.draw.fill.maxWidth.small.html [ Pass Timeout ] -crbug.com/1170337 [ Linux ] external/wpt/html/canvas/offscreen/text/2d.text.draw.fill.maxWidth.zero.html [ Pass Timeout ] -crbug.com/1170337 [ Linux ] external/wpt/html/canvas/offscreen/text/2d.text.draw.fill.maxWidth.small.worker.html [ Pass Timeout ] -crbug.com/1170337 [ Linux ] external/wpt/html/canvas/offscreen/text/2d.text.draw.fill.maxWidth.negative.html [ Pass Timeout ] -crbug.com/1170337 [ Linux ] external/wpt/html/canvas/element/fill-and-stroke-styles/2d.gradient.interpolate.zerosize.fillText.html [ Pass Timeout ] -crbug.com/1170337 [ Linux ] external/wpt/html/canvas/element/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.NaN.html [ Pass Timeout ] -crbug.com/1170337 [ Linux ] external/wpt/html/canvas/element/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.negative.html [ Pass Timeout ] -crbug.com/1170337 [ Linux ] external/wpt/html/canvas/offscreen/text/2d.text.draw.fill.maxWidth.negative.worker.html [ Pass Timeout ] -crbug.com/1170337 [ Linux ] external/wpt/html/canvas/element/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.zero.html [ Pass Timeout ] -crbug.com/1170337 [ Mac10.13 ] external/wpt/html/canvas/offscreen/text/2d.text.draw.fill.maxWidth.NaN.worker.html [ Timeout ] crbug.com/1170337 [ Mac10.13 ] external/wpt/html/canvas/offscreen/text/2d.text.draw.fill.maxWidth.zero.worker.html [ Skip Timeout ] -crbug.com/1302790 external/wpt/html/canvas/offscreen/text/2d.text.font.parse.system.worker.html [ Failure Pass ] crbug.com/1315282 [ Mac ] external/wpt/html/canvas/element/drawing-text-to-the-canvas/direction-inherit-rtl.html [ Failure ] crbug.com/1315282 [ Mac ] external/wpt/html/canvas/element/drawing-text-to-the-canvas/direction-rtl.html [ Failure ] # Off by one pixel error on ref test crbug.com/1259367 [ Mac ] printing/offscreencanvas-webgl-printing.html [ Failure ] -# Subpixel differences due to compositing on Mac10.14+. -crbug.com/997202 [ Mac10.14 ] external/wpt/svg/extensibility/foreignObject/foreign-object-scale-scroll.html [ Failure ] -crbug.com/997202 [ Mac10.15 ] external/wpt/svg/extensibility/foreignObject/foreign-object-scale-scroll.html [ Failure ] -crbug.com/997202 [ Mac11 ] external/wpt/svg/extensibility/foreignObject/foreign-object-scale-scroll.html [ Failure ] - # This test depends on synchronous focus() which does not exist (anymore?). crbug.com/1074482 external/wpt/html/interaction/focus/the-autofocus-attribute/update-the-rendering.html [ Failure ] crbug.com/1074482 external/wpt/clipboard-apis/feature-policy/clipboard-read/clipboard-read-enabled-by-feature-policy-cross-origin-tentative.https.sub.html [ Failure Pass ] crbug.com/1074482 external/wpt/clipboard-apis/feature-policy/clipboard-read/clipboard-read-enabled-by-feature-policy-attribute-cross-origin-tentative.https.sub.html [ Failure Pass ] crbug.com/1074482 external/wpt/clipboard-apis/feature-policy/clipboard-write/clipboard-write-enabled-by-feature-policy-cross-origin-tentative.https.sub.html [ Failure Pass ] -crbug.com/1074482 external/wpt/clipboard-apis/feature-policy/clipboard-write/clipboard-write-enabled-by-feature-policy-attribute-cross-origin-tentative.https.sub.html [ Failure Pass ] crbug.com/1105278 external/wpt/clipboard-apis/feature-policy/clipboard-write/clipboard-write-enabled-on-self-origin-by-feature-policy.tentative.https.sub.html [ Failure Pass ] crbug.com/1104125 external/wpt/clipboard-apis/feature-policy/clipboard-read/clipboard-read-enabled-on-self-origin-by-feature-policy.tentative.https.sub.html [ Failure Pass ] @@ -411,8 +375,6 @@ crbug.com/730267 [ Mac11 ] virtual/gpu-rasterization/images/yuv-decode-eligible/webp-no-color-profile-lossy.html [ Failure Pass Timeout ] # Flaky virtual/threaded/fast/scrolling tests -crbug.com/841567 virtual/threaded-prefer-compositing/fast/scrolling/absolute-position-behind-scrollbar.html [ Failure Pass ] -crbug.com/841567 virtual/threaded-prefer-compositing/fast/scrolling/fixed-position-behind-scrollbar.html [ Failure Pass ] crbug.com/841567 virtual/threaded-prefer-compositing/fast/scrolling/listbox-wheel-event.html [ Failure Pass Timeout ] crbug.com/841567 virtual/threaded-prefer-compositing/fast/scrolling/overflow-scrollability.html [ Failure Pass Timeout ] crbug.com/841567 virtual/threaded-prefer-compositing/fast/scrolling/same-page-navigate.html [ Failure Pass ] @@ -647,7 +609,6 @@ # that should be investigated (see crbug.com/780700) crbug.com/1242416 [ Linux ] external/wpt/css/CSS2/backgrounds/background-position-201.xht [ Failure Pass ] crbug.com/1242416 [ Mac10.14 ] external/wpt/css/CSS2/backgrounds/background-position-201.xht [ Failure Pass ] -crbug.com/1242416 [ Debug Mac10.15 ] external/wpt/css/CSS2/backgrounds/background-position-201.xht [ Failure Pass ] crbug.com/492187 external/wpt/css/CSS2/backgrounds/background-intrinsic-004.xht [ Failure ] crbug.com/492187 external/wpt/css/CSS2/backgrounds/background-intrinsic-006.xht [ Failure ] crbug.com/767352 external/wpt/css/css-backgrounds/border-image-width-008.html [ Failure ] @@ -658,9 +619,6 @@ # No emoji flag symbols available in the Windows system emoji font. crbug.com/1272436 [ Win10.20h2 ] external/wpt/css/CSS2/text/bidi-flag-emoji-02.html [ Failure ] -# LayoutNGBlockInInline -crbug.com/1288784 [ Mac ] editing/selection/click-after-nested-block.html [ Failure ] - # ==== Regressions introduced by BlinkGenPropertyTrees ===== # Reflection / mask ordering issue crbug.com/767318 compositing/reflections/nested-reflection-mask-change.html [ Failure ] @@ -709,7 +667,6 @@ # Needs rebaseline on Fuchsia. crbug.com/1267498 [ Fuchsia ] paint/invalidation/svg/animated-svg-as-image-transformed-offscreen.html [ Failure ] crbug.com/1267498 [ Fuchsia ] compositing/layer-creation/fixed-position-out-of-view.html [ Failure ] -crbug.com/1267498 [ Fuchsia ] fast/inline/inline-focus-ring.html [ Failure ] crbug.com/1267498 [ Fuchsia ] transforms/transformed-caret.html [ Failure ] # WebGPU tests are only run on GPU bots, so they are skipped by default and run @@ -891,9 +848,6 @@ # Minor pixel differences crbug.com/1056492 external/wpt/svg/painting/reftests/marker-path-001.svg [ Failure ] -# Slightly flaky timeouts (about 1 in 30) -crbug.com/1050993 [ Linux ] virtual/gpu-rasterization/images/drag-image-descendant-painting-sibling.html [ Crash Pass Timeout ] - # Flaky test. crbug.com/1054894 [ Mac ] http/tests/images/image-decode-in-frame.html [ Failure Pass ] @@ -925,7 +879,6 @@ # ====== Paint team owned tests to here ====== # WPT speculative-parsing tests failing -crbug.com/1144176 [ Mac11 ] external/wpt/html/syntax/speculative-parsing/generated/document-write/svg-script-src.tentative.sub.html [ Failure ] crbug.com/1144176 external/wpt/html/syntax/speculative-parsing/generated/document-write/link-rel-alternate-stylesheet.tentative.sub.html [ Crash Failure ] crbug.com/1144176 external/wpt/html/syntax/speculative-parsing/generated/document-write/link-rel-stylesheet-nomatch-media.tentative.sub.html [ Failure ] crbug.com/1144176 external/wpt/html/syntax/speculative-parsing/generated/page-load/link-rel-alternate-stylesheet.tentative.html [ Failure ] @@ -1010,14 +963,6 @@ #### Unprefix and update the implementation for text-emphasis crbug.com/666433 external/wpt/css/css-text-decor/text-emphasis-color-001.xht [ Failure ] -crbug.com/666433 external/wpt/css/css-text-decor/text-emphasis-position-above-left-001.xht [ Failure ] -crbug.com/666433 external/wpt/css/css-text-decor/text-emphasis-position-above-left-002.xht [ Failure ] -crbug.com/666433 external/wpt/css/css-text-decor/text-emphasis-position-above-right-001.xht [ Failure ] -crbug.com/666433 external/wpt/css/css-text-decor/text-emphasis-position-above-right-002.xht [ Failure ] -crbug.com/666433 external/wpt/css/css-text-decor/text-emphasis-position-below-left-001.xht [ Failure ] -crbug.com/666433 external/wpt/css/css-text-decor/text-emphasis-position-below-left-002.xht [ Failure ] -crbug.com/666433 external/wpt/css/css-text-decor/text-emphasis-position-below-right-001.xht [ Failure ] -crbug.com/666433 external/wpt/css/css-text-decor/text-emphasis-position-below-right-002.xht [ Failure ] crbug.com/666433 external/wpt/css/css-text-decor/text-emphasis-position-over-left-001.xht [ Failure ] crbug.com/666433 external/wpt/css/css-text-decor/text-emphasis-position-over-left-002.xht [ Failure ] crbug.com/666433 external/wpt/css/css-text-decor/text-emphasis-position-over-right-001.xht [ Failure ] @@ -1269,7 +1214,6 @@ crbug.com/591099 external/wpt/css/css-ui/text-overflow-015.html [ Failure ] # Various issues related to the 'appearance' property: crbug.com/1284269 external/wpt/css/css-ui/compute-kind-widget-fallback-props-revert-001.html [ Failure ] -crbug.com/1284270 [ Fuchsia ] external/wpt/css/css-ui/compute-kind-widget-no-fallback-props-001.html [ Failure ] crbug.com/1284270 [ Linux ] external/wpt/css/css-ui/compute-kind-widget-no-fallback-props-001.html [ Failure ] crbug.com/1284270 [ Mac10.12 ] external/wpt/css/css-ui/compute-kind-widget-no-fallback-props-001.html [ Failure Timeout ] crbug.com/1284270 [ Mac10.13 ] external/wpt/css/css-ui/compute-kind-widget-no-fallback-props-001.html [ Failure ] @@ -1424,7 +1368,6 @@ crbug.com/1270480 external/wpt/css/css-lists/marker-webkit-text-fill-color.html [ Failure ] crbug.com/1270483 external/wpt/css/css-lists/li-value-counter-reset-001.html [ Failure ] crbug.com/947844 external/wpt/css/css-lists/list-item-definition.html [ Failure ] -crbug.com/1270481 [ Win7 ] external/wpt/css/css-lists/content-property/marker-text-matches-armenian.html [ Failure ] # [css-counter-styles-3] crbug.com/1176323 external/wpt/css/css-counter-styles/counter-style-at-rule/prefix-suffix-syntax.html [ Failure ] @@ -1445,9 +1388,6 @@ crbug.com/481430 external/wpt/css/css-fonts/font-language-override-01.html [ Failure ] crbug.com/481430 external/wpt/css/css-fonts/font-language-override-02.html [ Failure ] -# Non standard -webkit-<generic font family name> values are web exposed -crbug.com/1065468 [ Mac10.15 ] external/wpt/css/css-fonts/generic-family-keywords-002.html [ Failure Timeout ] - # Comparing variable font rendering to static font rendering fails on systems that use FreeType for variable fonts crbug.com/1067242 [ Win7 ] external/wpt/css/css-text-decor/text-underline-position-from-font-variable.html [ Failure ] crbug.com/1067242 [ Mac10.12 ] external/wpt/css/css-text-decor/text-underline-position-from-font-variable.html [ Failure ] @@ -1469,7 +1409,6 @@ # external/wpt/css/css-fonts/... tests triaged away from the default WPT bug ID crbug.com/1211460 external/wpt/css/css-fonts/alternates-order.html [ Failure ] -crbug.com/1204775 [ Linux ] external/wpt/css/css-fonts/animations/font-stretch-interpolation.html [ Failure ] crbug.com/1240186 [ Mac ] external/wpt/css/css-fonts/font-family-name-025.html [ Failure ] crbug.com/443467 external/wpt/css/css-fonts/font-feature-settings-descriptor-01.html [ Failure ] crbug.com/819816 external/wpt/css/css-fonts/font-kerning-03.html [ Failure ] @@ -1497,8 +1436,6 @@ crbug.com/716567 external/wpt/css/css-fonts/font-variant-alternates-18.html [ Failure ] crbug.com/1212668 external/wpt/css/css-fonts/font-variant-descriptor-01.html [ Failure ] crbug.com/1240186 [ Mac ] external/wpt/css/css-fonts/font-variant-ligatures-11.html [ Failure ] -crbug.com/1212668 external/wpt/css/css-fonts/font-variant-position-02.html [ Failure ] -crbug.com/1212668 external/wpt/css/css-fonts/font-variant-position-03.html [ Failure ] crbug.com/1212668 external/wpt/css/css-fonts/font-variant-position.html [ Failure ] crbug.com/1240186 [ Mac10.12 ] external/wpt/css/css-fonts/matching/range-descriptor-reversed.html [ Failure ] crbug.com/1240186 [ Mac ] external/wpt/css/css-fonts/standard-font-family.html [ Failure ] @@ -1620,14 +1557,6 @@ crbug.com/1212254 external/wpt/css/css-writing-modes/available-size-003.html [ Failure ] crbug.com/1212254 external/wpt/css/css-writing-modes/available-size-014.html [ Failure ] crbug.com/1212254 external/wpt/css/css-writing-modes/available-size-013.html [ Failure ] -crbug.com/1212254 [ Mac11-arm64 ] external/wpt/css/css-writing-modes/caption-side-vrl-002.xht [ Failure Pass ] -crbug.com/1212254 [ Mac11-arm64 ] external/wpt/css/css-writing-modes/float-vrl-002.xht [ Failure Pass ] -crbug.com/1212254 [ Mac11-arm64 ] external/wpt/css/css-writing-modes/margin-collapse-vlr-037.xht [ Failure Pass ] -crbug.com/1212254 [ Mac11-arm64 ] external/wpt/css/css-writing-modes/margin-collapse-vrl-008.xht [ Failure Pass ] -crbug.com/1212254 [ Mac11-arm64 ] external/wpt/css/css-writing-modes/text-align-vrl-012.xht [ Failure Pass ] -crbug.com/1212254 [ Mac11-arm64 ] external/wpt/css/css-writing-modes/margin-collapse-vrl-014.xht [ Failure Pass ] -crbug.com/1212254 [ Mac11-arm64 ] external/wpt/css/css-writing-modes/float-vlr-011.xht [ Failure Pass ] -crbug.com/1212254 [ Mac11-arm64 ] external/wpt/css/css-writing-modes/text-align-vlr-017.xht [ Failure Pass ] crbug.com/717862 [ Mac ] external/wpt/css/css-writing-modes/mongolian-orientation-002.html [ Failure ] crbug.com/717862 external/wpt/css/css-writing-modes/mongolian-orientation-001.html [ Failure ] crbug.com/750992 external/wpt/css/css-writing-modes/sizing-orthog-vlr-in-htb-008.xht [ Failure ] @@ -1636,7 +1565,6 @@ crbug.com/750992 external/wpt/css/css-writing-modes/sizing-orthog-vrl-in-htb-020.xht [ Failure ] ### With LayoutNGFragmentItem enabled -crbug.com/982194 [ Win7 ] external/wpt/css/css-text/white-space/seg-break-transformation-018.tentative.html [ Failure ] crbug.com/982194 [ Win10.20h2 ] fast/writing-mode/border-image-vertical-lr.html [ Failure Pass ] ### Tests failing with LayoutNGFlexFragmentation enabled: @@ -1658,10 +1586,6 @@ virtual/layout_ng_table_frag/external/wpt/css/css-break/table/table-cell-expansion-003.html [ Pass ] ### Tests failing with LayoutNGTableFragmentation enabled: -crbug.com/1295905 [ Mac11-arm64 ] virtual/layout_ng_table_frag/external/wpt/css/css-break/table/break-inside-cell-000.html [ Failure ] -crbug.com/1295905 [ Mac11-arm64 ] virtual/layout_ng_table_frag/external/wpt/css/css-break/table/break-inside-cell-001.html [ Failure ] -crbug.com/1295905 [ Mac10.12 ] virtual/layout_ng_table_frag/external/wpt/css/css-break/table/sections-and-captions-mixed-order.html [ Failure ] -crbug.com/1295905 [ Mac10.13 ] virtual/layout_ng_table_frag/external/wpt/css/css-break/table/sections-and-captions-mixed-order.html [ Failure ] crbug.com/1295905 [ Mac11-arm64 ] virtual/layout_ng_table_frag/external/wpt/css/css-break/table/sections-and-captions-mixed-order.html [ Failure ] crbug.com/1078927 virtual/layout_ng_table_frag/external/wpt/css/css-multicol/table/balance-table-with-border-spacing.html [ Failure ] crbug.com/1078927 virtual/layout_ng_table_frag/external/wpt/css/css-multicol/table/multicol-table-cell-height-002.xht [ Failure ] @@ -1671,7 +1595,6 @@ crbug.com/1121942 virtual/layout_ng_printing/printing/block-with-overflow-in-bottom-aligned-fixedpos.html [ Crash Failure ] crbug.com/1121942 virtual/layout_ng_printing/printing/fixed-positioned-but-static-headers-and-footers.html [ Crash Failure ] -crbug.com/1121942 virtual/layout_ng_printing/printing/fixed-positioned-child-repeats-even-when-html-and-body-are-zero-height.html [ Crash Failure Pass ] crbug.com/1121942 virtual/layout_ng_printing/printing/fixed-positioned-child-shouldnt-print.html [ Crash Failure Pass ] crbug.com/1121942 virtual/layout_ng_printing/printing/fixed-positioned-composited.html [ Crash Failure ] crbug.com/1121942 virtual/layout_ng_printing/printing/fixed-positioned-headers-and-footers-absolute-covering-some-pages.html [ Crash Failure ] @@ -1908,8 +1831,6 @@ crbug.com/1068610 external/wpt/css/css-color/display-p3-004.html [ Failure ] crbug.com/1068610 external/wpt/css/css-color/display-p3-005.html [ Failure ] crbug.com/1068610 external/wpt/css/css-color/display-p3-006.html [ Failure ] -crbug.com/1068610 [ Mac11-arm64 ] external/wpt/css/css-color/parsing/relative-color-computed.html [ Crash Failure ] -crbug.com/1068610 [ Mac11-arm64 ] virtual/system-color-compute/external/wpt/css/css-color/parsing/relative-color-valid.html [ Crash Failure ] crbug.com/1068610 external/wpt/css/css-color/oklab-001.html [ Failure ] crbug.com/1068610 external/wpt/css/css-color/oklab-002.html [ Failure ] crbug.com/1068610 external/wpt/css/css-color/oklab-003.html [ Failure ] @@ -1943,12 +1864,10 @@ crbug.com/1068610 [ Linux ] external/wpt/css/css-color/t422-rgba-a0.6-a.xht [ Failure ] crbug.com/1068610 external/wpt/css/css-color/t32-opacity-basic-0.6-a.xht [ Failure ] crbug.com/1068610 [ Linux ] external/wpt/css/css-color/t425-hsla-basic-a.xht [ Failure ] -crbug.com/1068610 [ Linux ] virtual/system-color-compute/external/wpt/css/css-color/color-function-parsing.html [ Failure ] crbug.com/1068610 [ Mac ] external/wpt/css/css-color/color-function-parsing.html [ Failure ] crbug.com/1068610 [ Linux ] external/wpt/css/css-color/t422-rgba-onscreen-multiple-boxes-c.xht [ Failure ] crbug.com/1068610 [ Linux ] external/wpt/css/css-color/t425-hsla-onscreen-multiple-boxes-c.xht [ Failure ] crbug.com/1068610 [ Linux ] external/wpt/css/css-color/t425-hsla-onscreen-b.xht [ Failure ] -crbug.com/1068610 [ Win ] external/wpt/css/css-color/t425-hsla-onscreen-b.xht [ Failure ] crbug.com/1068610 external/wpt/css/css-color/at-color-profile-001.html [ Failure ] crbug.com/1299585 [ Mac11 ] external/wpt/css/css-color-adjust/inheritance.html [ Failure ] @@ -2016,7 +1935,6 @@ crbug.com/1234199 [ Linux ] external/wpt/html/semantics/embedded-content/the-object-element/object-events.html [ Skip ] crbug.com/1234199 [ Mac ] external/wpt/html/semantics/embedded-content/the-object-element/object-events.html [ Skip ] crbug.com/1232504 [ Mac11 ] external/wpt/html/semantics/embedded-content/media-elements/interfaces/TextTrackCue/endTime.html [ Failure Timeout ] -crbug.com/1232504 [ Mac11 ] external/wpt/html/semantics/embedded-content/media-elements/preserves-pitch.html [ Timeout ] crbug.com/1292852 [ Mac ] external/wpt/html/semantics/interactive-elements/the-dialog-element/dialog-focus-shadow.html [ Failure Pass ] crbug.com/1301716 external/wpt/html/semantics/interactive-elements/the-dialog-element/modal-dialog-in-replaced-renderer.html [ Failure ] @@ -2066,7 +1984,6 @@ crbug.com/1093447 virtual/android/fullscreen/rendering/backdrop-video.html [ Failure ] # gpuBenchmarking.pinchBy is busted on desktops for touchscreen pinch -crbug.com/787615 [ Win ] virtual/threaded/synthetic_gestures/synthetic-pinch-zoom-gesture-touchscreen-zoom-in-slow.html [ Failure Pass ] crbug.com/787615 [ Win ] virtual/threaded/synthetic_gestures/synthetic-pinch-zoom-gesture-touchscreen.html [ Failure Pass ] crbug.com/787615 [ Linux ] virtual/threaded/synthetic_gestures/synthetic-pinch-zoom-gesture-touchscreen.html [ Failure Pass ] @@ -2093,20 +2010,9 @@ # TODO(oshima): Move the event scaling code to eventSender and remove this. crbug.com/567837 virtual/scalefactor200/fast/hidpi/static/gesture-scroll-amount.html [ Failure Timeout ] crbug.com/567837 virtual/scalefactor200/fast/hidpi/static/popup-menu-with-scrollbar-appearance.html [ Failure Timeout ] -crbug.com/567837 [ Linux ] virtual/scalefactor150/fast/hidpi/static/mousewheel-scroll-amount.html [ Failure Timeout ] -crbug.com/567837 [ Win ] virtual/scalefactor150/fast/hidpi/static/mousewheel-scroll-amount.html [ Failure Timeout ] -crbug.com/567837 [ Linux ] virtual/scalefactor150/fast/hidpi/static/gesture-scroll-amount.html [ Failure Timeout ] -crbug.com/567837 [ Win ] virtual/scalefactor150/fast/hidpi/static/gesture-scroll-amount.html [ Failure Timeout ] crbug.com/567837 [ Linux ] virtual/scalefactor150/fast/hidpi/static/popup-menu-with-scrollbar-appearance.html [ Failure Timeout ] crbug.com/567837 [ Win ] virtual/scalefactor150/fast/hidpi/static/popup-menu-with-scrollbar-appearance.html [ Failure Timeout ] -# TODO(ojan): These tests aren't flaky. See crbug.com/517144. -# Release trybots run asserts, but the main waterfall ones don't. So, even -# though this is a non-flaky assert failure, we need to mark it [ Pass Crash ]. -crbug.com/389648 crbug.com/517123 crbug.com/410145 fast/text-autosizing/table-inflation-crash.html [ Crash Pass Timeout ] - -crbug.com/876732 [ Win ] fast/dom/HTMLImageElement/image-srcset-w-onerror.html [ Failure Pass ] - # Only virtual/threaded version of these tests pass (or running them with --enable-threaded-compositing). crbug.com/936891 fast/scrolling/document-level-touchmove-event-listener-passive-by-default.html [ Failure ] crbug.com/936891 virtual/threaded-prefer-compositing/fast/scrolling/document-level-touchmove-event-listener-passive-by-default.html [ Pass ] @@ -2117,7 +2023,6 @@ crbug.com/889952 fast/selectors/selection-window-inactive.html [ Failure Pass ] -crbug.com/731731 inspector-protocol/layers/paint-profiler-load-empty.js [ Failure Pass ] crbug.com/1107923 inspector-protocol/debugger/wasm-streaming-url.js [ Failure Pass Timeout ] # Script let/const redeclaration errors @@ -2172,8 +2077,6 @@ crbug.com/707210 external/wpt/html/rendering/non-replaced-elements/the-page/body-margin-2k.html [ Failure ] crbug.com/707210 external/wpt/html/rendering/non-replaced-elements/the-page/body-margin-2l.html [ Failure ] -crbug.com/860211 [ Mac ] external/wpt/editing/run/delete.html [ Failure ] - crbug.com/821455 editing/pasteboard/drag-files-to-editable-element.html [ Failure ] crbug.com/1170052 external/wpt/mediacapture-streams/MediaStreamTrack-MediaElement-disabled-audio-is-silence.https.html [ Pass Timeout ] @@ -2294,7 +2197,6 @@ crbug.com/73609 http/tests/media/video-play-stall.html [ Pass Timeout ] crbug.com/518987 http/tests/xmlhttprequest/navigation-abort-detaches-frame.html [ Pass Timeout ] crbug.com/538717 [ Win ] http/tests/permissions/chromium/test-request-worker.html [ Pass Timeout ] -crbug.com/802029 [ Debug Mac10.13 ] fast/dom/shadow/focus-controller-recursion-crash.html [ Pass Timeout ] crbug.com/829740 fast/history/history-back-twice-with-subframes-assert.html [ Pass Timeout ] crbug.com/836783 fast/peerconnection/RTCRtpSender-setParameters.html [ Pass Timeout ] @@ -2309,16 +2211,13 @@ crbug.com/846981 fast/webgl/texImage-imageBitmap-from-imageData-resize.html [ Skip ] # crbug.com/1095379: These fail with a timeout, even when they're given extra time (via SlowTests) -crbug.com/846656 external/wpt/css/selectors/focus-visible-002.html [ Pass Timeout ] crbug.com/1135405 http/tests/devtools/sources/debugger-pause/debugger-pause-infinite-loop.js [ Pass Timeout ] crbug.com/1072022 [ Mac ] http/tests/security/frameNavigation/xss-ALLOWED-parent-navigation-change-async.html [ Pass Timeout ] crbug.com/1072022 [ Linux ] http/tests/security/frameNavigation/xss-ALLOWED-parent-navigation-change-async.html [ Pass Timeout ] -crbug.com/1105957 [ Debug Linux ] fast/dom/cssTarget-crash.html [ Pass Timeout ] crbug.com/915903 http/tests/security/inactive-document-with-empty-security-origin.html [ Pass Timeout ] crbug.com/987138 [ Linux ] media/controls/doubletap-to-jump-forwards.html [ Pass Timeout ] crbug.com/987138 [ Win ] media/controls/doubletap-to-jump-forwards.html [ Pass Timeout ] crbug.com/1122742 http/tests/devtools/sources/debugger/source-frame-inline-breakpoint-decorations.js [ Pass Timeout ] -crbug.com/867532 [ Linux ] http/tests/workers/worker-usecounter.html [ Pass Timeout ] crbug.com/1002377 external/wpt/service-workers/service-worker/update-bytecheck.https.html [ Pass Timeout ] crbug.com/1002377 external/wpt/service-workers/service-worker/update-bytecheck-cors-import.https.html [ Pass Timeout ] crbug.com/805756 external/wpt/html/semantics/tabular-data/processing-model-1/span-limits.html [ Pass Timeout ] @@ -2398,14 +2297,6 @@ # Method needs to be renamed. crbug.com/1253323 http/tests/devtools/network/network-persistence-filename-safety.js [ Skip ] -# No support for WPT print-reftests: -crbug.com/1090628 external/wpt/infrastructure/reftest/reftest_match-print.html [ Failure ] -crbug.com/1090628 external/wpt/infrastructure/reftest/reftest_match_fail-print.html [ Failure ] -crbug.com/1090628 external/wpt/html/rendering/the-details-element/details-page-break-after-2-print.html [ Failure ] -crbug.com/1090628 external/wpt/html/rendering/the-details-element/details-page-break-before-2-print.html [ Failure ] -crbug.com/1090628 external/wpt/html/rendering/the-details-element/details-page-break-after-1-print.html [ Failure ] -crbug.com/1090628 external/wpt/html/rendering/the-details-element/details-page-break-before-1-print.html [ Failure ] - crbug.com/1051044 external/wpt/css/filter-effects/effect-reference-feimage-001.html [ Failure Pass ] crbug.com/1051044 external/wpt/css/filter-effects/effect-reference-feimage-003.html [ Failure Pass ] @@ -2543,15 +2434,11 @@ crbug.com/501659 fast/css/stylesheet-candidate-nodes-crash.xhtml [ Failure ] # TODO(chrishtr) uncomment ones marked crbug.com/591500 after fixing crbug.com/665259. -crbug.com/591500 [ Win10.20h2 ] virtual/threaded/printing/fixed-positioned-headers-and-footers-absolute-covering-some-pages.html [ Failure ] crbug.com/591500 [ Win10.20h2 ] virtual/threaded/printing/fixed-positioned-but-static-headers-and-footers.html [ Failure Pass ] crbug.com/591500 [ Win10.20h2 ] virtual/threaded/printing/fixed-positioned-headers-and-footers-larger-than-page.html [ Failure Pass ] -crbug.com/591500 [ Win10.20h2 ] virtual/threaded/printing/fixed-positioned-headers-and-footers.html [ Failure Pass ] crbug.com/591500 [ Win10.20h2 ] virtual/threaded/printing/list-item-with-empty-first-line.html [ Failure ] -crbug.com/591500 [ Win10.20h2 ] virtual/threaded/printing/fixed-positioned-headers-and-footers-clipped.html [ Failure Pass ] - crbug.com/353746 virtual/android/fullscreen/video-specified-size.html [ Failure Pass ] crbug.com/525296 fast/css/font-load-while-styleresolver-missing.html [ Crash Failure Pass ] @@ -2623,16 +2510,12 @@ crbug.com/808834 [ Linux ] external/wpt/css/css-pseudo/first-letter-001.html [ Failure ] crbug.com/808834 [ Win ] external/wpt/css/css-pseudo/first-letter-001.html [ Failure ] -crbug.com/932343 external/wpt/css/css-pseudo/selection-text-shadow-016.html [ Failure ] - crbug.com/723741 virtual/threaded/http/tests/devtools/tracing/idle-callback.js [ Crash Failure Pass Timeout ] # Untriaged failures after https://crrev.com/c/543695/. # These need to be updated but appear not to be related to that change. crbug.com/626703 http/tests/devtools/indexeddb/database-refresh-view.js [ Failure Pass ] crbug.com/626703 crbug.com/946710 http/tests/devtools/extensions/extensions-sidebar.js [ Crash Failure Pass Timeout ] -crbug.com/751952 virtual/text-antialias/international/complex-text-rectangle.html [ Pass Timeout ] -crbug.com/751952 [ Win ] editing/selection/modify_extend/extend_by_character.html [ Failure Pass ] crbug.com/805463 external/wpt/acid/acid3/numbered-tests.html [ Skip ] @@ -2749,19 +2632,15 @@ # needs implementation of test_driver_internal.action_sequence # tests in this group need implementation of keyDown/keyUp -crbug.com/893480 [ Fuchsia ] external/wpt/input-events/input-events-typing.html [ Failure Timeout ] crbug.com/893480 [ Mac ] external/wpt/input-events/input-events-typing.html [ Failure Timeout ] crbug.com/893480 [ Win ] external/wpt/input-events/input-events-typing.html [ Failure Timeout ] -crbug.com/893480 [ Fuchsia ] external/wpt/infrastructure/testdriver/actions/eventOrder.html [ Timeout ] crbug.com/893480 [ Mac ] external/wpt/infrastructure/testdriver/actions/eventOrder.html [ Timeout ] crbug.com/893480 [ Win ] external/wpt/infrastructure/testdriver/actions/eventOrder.html [ Timeout ] crbug.com/893480 external/wpt/infrastructure/testdriver/actions/multiDevice.html [ Failure Timeout ] crbug.com/893480 external/wpt/infrastructure/testdriver/actions/actionsWithKeyPressed.html [ Failure Timeout ] crbug.com/893480 external/wpt/infrastructure/testdriver/actions/textEditCommands.html [ Failure Timeout ] -crbug.com/893480 [ Fuchsia ] external/wpt/input-events/input-events-get-target-ranges.html [ Failure Timeout ] crbug.com/893480 [ Mac ] external/wpt/input-events/input-events-get-target-ranges.html [ Failure Timeout ] crbug.com/893480 [ Win ] external/wpt/input-events/input-events-get-target-ranges.html [ Failure Timeout ] -crbug.com/893480 [ Fuchsia ] external/wpt/input-events/input-events-cut-paste.html [ Failure Timeout ] crbug.com/893480 [ Mac ] external/wpt/input-events/input-events-cut-paste.html [ Failure Timeout ] crbug.com/893480 [ Win ] external/wpt/input-events/input-events-cut-paste.html [ Failure Timeout ] crbug.com/893480 external/wpt/html/semantics/forms/the-input-element/checkable-active-onblur.html [ Failure Timeout ] @@ -2813,8 +2692,6 @@ crbug.com/1299212 [ Linux ] fast/forms/select/menulist-popup-mutation-crash.html [ Failure Pass Timeout ] # These appear to be flaky at least on Linux: crbug.com/1299212 [ Linux ] fast/forms/week/week-picker-ax.html [ Failure Pass ] -crbug.com/1299212 [ Linux ] fast/forms/month/month-picker-ax.html [ Failure Pass ] -crbug.com/1299212 [ Linux ] fast/forms/calendar-picker/date-picker-ax.html [ Failure Pass ] crbug.com/1299212 [ Linux ] fast/forms/select-popup/popup-menu-ax.html [ Failure Pass ] # isInputPending requires threaded compositing and layerized iframes @@ -3067,9 +2944,6 @@ # FontFace object failures detected by WPT test crbug.com/965409 external/wpt/css/css-font-loading/fontface-descriptor-updates.html [ Failure ] -# Linux draws antialiasing differently when overlaying two text layers. -crbug.com/785230 [ Linux ] external/wpt/css/css-text-decor/text-decoration-thickness-ink-skip-dilation.html [ Failure ] - crbug.com/1002514 external/wpt/web-share/share-sharePromise-internal-slot.https.html [ Crash Failure ] crbug.com/1029514 external/wpt/html/semantics/embedded-content/the-video-element/resize-during-playback.html [ Failure Pass ] @@ -3347,7 +3221,6 @@ crbug.com/958381 [ Mac ] external/wpt/css/CSS2/tables/table-anonymous-objects-015.xht [ Failure ] crbug.com/958381 [ Mac ] external/wpt/css/CSS2/tables/table-anonymous-objects-016.xht [ Failure ] crbug.com/958381 [ Mac ] external/wpt/css/CSS2/tables/table-anonymous-objects-017.xht [ Failure ] -crbug.com/958381 [ Mac ] external/wpt/css/CSS2/tables/table-anonymous-objects-018.xht [ Failure ] crbug.com/958381 [ Mac ] external/wpt/css/CSS2/tables/table-anonymous-objects-019.xht [ Failure ] crbug.com/958381 [ Mac ] external/wpt/css/CSS2/tables/table-anonymous-objects-020.xht [ Failure ] crbug.com/958381 [ Mac ] external/wpt/css/CSS2/tables/table-anonymous-objects-177.xht [ Failure ] @@ -3383,8 +3256,6 @@ crbug.com/626703 fast/animation/scroll-animations/scrolltimeline-root-scroller-quirks-mode.html [ Failure ] crbug.com/626703 virtual/plz-dedicated-worker/external/wpt/service-workers/service-worker/navigation-timing-extended.https.html [ Failure ] crbug.com/626703 external/wpt/preload/preload-resource-match.https.html [ Failure ] -crbug.com/626703 [ Linux ] external/wpt/url/a-element-xhtml.xhtml [ Failure ] -crbug.com/626703 [ Linux ] external/wpt/url/failure.html [ Failure ] crbug.com/626703 virtual/prerender/external/wpt/speculation-rules/prerender/workers.html [ Failure ] crbug.com/626703 [ Win ] external/wpt/preload/avoid-delaying-onload-link-modulepreload.html [ Failure ] crbug.com/626703 [ Win ] virtual/prerender/external/wpt/speculation-rules/prerender/restriction-presentation-request.https.html [ Failure ] @@ -3433,54 +3304,25 @@ crbug.com/626703 [ Mac10.12 ] virtual/scroll-unification/external/wpt/dom/events/scrolling/scrollend-event-fired-after-snap.html [ Timeout ] crbug.com/626703 [ Mac10.12 ] virtual/third-party-storage-partitioning/external/wpt/webmessaging/broadcastchannel/cross-partition.https.tentative.html [ Timeout ] crbug.com/626703 [ Mac10.12 ] virtual/fenced-frame-mparch/wpt_internal/fenced_frame/navigate-ancestor-nested-fenced-frame.https.html [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/fetch/private-network-access/redirect.https.window.html [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/fetch/private-network-access/shared-worker.https.window.html [ Timeout ] crbug.com/626703 [ Win10.20h2 ] external/wpt/permissions-policy/reporting/xr-report-only.https.html [ Crash ] -crbug.com/626703 [ Win10.20h2 ] wpt_internal/webxr/xr_view_projection_detached.https.html [ Crash ] crbug.com/626703 [ Mac10.12 ] virtual/fenced-frame-mparch/wpt_internal/fenced_frame/unique-cookie-partition.https.html [ Timeout ] crbug.com/626703 [ Mac10.12 ] virtual/portals/external/wpt/portals/portals-adopt-predecessor.html [ Timeout ] crbug.com/626703 [ Mac11-arm64 ] external/wpt/mixed-content/gen/worker-classic.http-rp/opt-in/websocket.https.html [ Skip Timeout ] crbug.com/626703 [ Mac11-arm64 ] external/wpt/mixed-content/gen/worker-module-data.meta/opt-in/websocket.https.html [ Skip Timeout ] crbug.com/626703 [ Mac11-arm64 ] external/wpt/upgrade-insecure-requests/gen/worker-classic-data.meta/upgrade/websocket.https.html [ Skip Timeout ] crbug.com/626703 [ Mac11-arm64 ] external/wpt/upgrade-insecure-requests/gen/worker-module-data.http-rp/upgrade/websocket.https.html [ Skip Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/Send-0byte-data.any.html?wss [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/Send-0byte-data.any.worker.html?wss [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/Send-binary-arraybufferview-float64.any.html?wss [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/Send-paired-surrogates.any.html?wss [ Timeout ] crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/binary/002.html?wss [ Skip Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/binary/005.html?wss [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/constructor/010.html?wss [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/cookies/third-party-cookie-accepted.https.html [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/interfaces/WebSocket/readyState/006.html?wss [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/opening-handshake/005.html?wss [ Timeout ] crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/stream/tentative/backpressure-send.any.serviceworker.html?wss [ Skip Timeout ] -crbug.com/626703 [ Mac11-arm64 ] virtual/portals/external/wpt/portals/portals-host-exposure.sub.html [ Timeout ] crbug.com/626703 [ Mac10.13 ] external/wpt/webrtc-encoded-transform/RTCPeerConnection-insertable-streams-simulcast.https.html [ Timeout ] crbug.com/626703 virtual/document-transition/wpt_internal/document-transition/content-with-transform-old-image.html [ Failure ] crbug.com/626703 [ Mac10.12 ] external/wpt/content-security-policy/inheritance/history-iframe.sub.html [ Timeout ] crbug.com/626703 [ Mac10.12 ] virtual/portals/external/wpt/portals/history/history-manipulation-inside-portal.html [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/fetch/private-network-access/nested-worker.https.window.html [ Timeout ] -crbug.com/626703 [ Mac10.12 ] virtual/document-transition/wpt_internal/document-transition/new-content-container-writing-modes.html [ Timeout ] crbug.com/626703 [ Mac10.12 ] virtual/split-http-cache/external/wpt/signed-exchange/reporting/sxg-reporting-navigation-cert_fetch_error-downgraded.tentative.html [ Timeout ] crbug.com/626703 [ Mac11-arm64 ] external/wpt/navigation-api/ordering-and-transition/navigate-cross-document-double.html [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/fetch/api/basic/request-upload.h2.any.worker.html [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/loading/early-hints/coep-early-hints-none-final-require-corp.h2.window.html [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/Close-1000-reason.any.html?wpt_flags=h2 [ Failure Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/Close-2999-reason.any.html?wpt_flags=h2 [ Failure Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/Close-delayed.any.html?wpt_flags=h2 [ Timeout ] crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/Create-extensions-empty.any.html?wpt_flags=h2 [ Skip Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/Create-valid-url-protocol-string.any.worker.html?wpt_flags=h2 [ Failure Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/Create-valid-url-protocol.any.worker.html?wpt_flags=h2 [ Failure Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/Send-0byte-data.any.worker.html?wpt_flags=h2 [ Failure Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/Send-unpaired-surrogates.any.html?wpt_flags=h2 [ Failure Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/cookies/003.html?wpt_flags=h2 [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/interfaces/WebSocket/bufferedAmount/bufferedAmount-unicode.html?wpt_flags=h2 [ Failure Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/interfaces/WebSocket/send/009.html?wpt_flags=h2 [ Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/focus/activeelement-after-focusing-different-site-iframe-then-immediately-focusing-back.html [ Failure Timeout ] crbug.com/626703 external/wpt/scroll-to-text-fragment/scroll-to-text-fragment.html [ Failure Skip Timeout ] crbug.com/626703 [ Mac10.12 ] external/wpt/service-workers/service-worker/same-site-cookies.https.html [ Skip Timeout ] crbug.com/626703 [ Mac10.12 ] external/wpt/signed-exchange/subresource/sxg-subresource-header-integrity-mismatch.tentative.html [ Timeout ] -crbug.com/626703 [ Mac10.12 ] virtual/shared-storage-fenced-frame-shadow-dom/wpt_internal/shared_storage/run-url-selection-operation.https.html [ Timeout ] crbug.com/626703 virtual/prerender/wpt_internal/prerender/unload-on-prerender-cross-origin-subframe-navigation.html [ Skip ] crbug.com/626703 virtual/prerender/wpt_internal/prerender/unload-on-prerender-main-frame-navigation.html [ Skip ] crbug.com/626703 virtual/prerender/wpt_internal/prerender/unload-on-prerender-remove-subframe.html [ Skip ] @@ -3504,7 +3346,6 @@ crbug.com/626703 external/wpt/wasm/webapi/esm-integration/wasm-js-cycle.tentative.html [ Timeout ] crbug.com/626703 external/wpt/wasm/webapi/esm-integration/worker-import.tentative.html [ Timeout ] crbug.com/626703 external/wpt/wasm/webapi/esm-integration/worker.tentative.html [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/content-security-policy/inside-worker/serviceworker-connect-src.https.sub.html [ Timeout ] crbug.com/626703 [ Linux ] external/wpt/resource-timing/object-not-found-adds-entry.html [ Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/webrtc-encoded-transform/RTCPeerConnection-insertable-streams-simulcast.https.html [ Timeout ] crbug.com/626703 [ Mac10.14 ] virtual/prerender/external/wpt/speculation-rules/prerender/service-workers.https.html [ Skip Timeout ] @@ -3515,56 +3356,19 @@ crbug.com/626703 [ Mac11 ] virtual/prerender/external/wpt/speculation-rules/prerender/service-workers.https.html [ Failure Skip Timeout ] crbug.com/626703 [ Mac11-arm64 ] virtual/prerender/external/wpt/speculation-rules/prerender/service-workers.https.html [ Failure Skip Timeout ] crbug.com/626703 [ Win ] virtual/prerender/external/wpt/speculation-rules/prerender/service-workers.https.html [ Failure Skip Timeout ] -crbug.com/626703 [ Mac11 ] virtual/plz-dedicated-worker/external/wpt/fetch/api/basic/response-null-body.any.worker.html [ Failure Timeout ] crbug.com/626703 external/wpt/webrtc/RTCConfiguration-iceTransportPolicy.html [ Skip Timeout ] crbug.com/626703 [ Win10.20h2 ] external/wpt/webrtc/RTCDataChannel-bufferedAmount.html [ Crash ] crbug.com/626703 [ Win10.20h2 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCDataChannel-bufferedAmount.html [ Crash ] -crbug.com/626703 [ Mac10.12 ] external/wpt/fetch/api/response/response-clone.any.worker.html [ Timeout ] crbug.com/626703 [ Mac10.12 ] external/wpt/webxr/xrSession_requestReferenceSpace_features.https.html [ Timeout ] crbug.com/626703 [ Mac10.12 ] virtual/portals/external/wpt/portals/no-portal-in-sandboxed-popup.html [ Timeout ] crbug.com/626703 [ Mac10.12 ] virtual/portals/external/wpt/portals/portal-activate-data.html [ Timeout ] crbug.com/626703 [ Mac10.12 ] external/wpt/mediacapture-streams/MediaDevices-enumerateDevices-per-origin-ids.sub.https.html [ Timeout ] crbug.com/626703 external/wpt/css/css-content/quotes-030.html [ Failure ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/fetch/private-network-access/fetch.https.window.html?include=from-public [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/fetch/private-network-access/service-worker.https.window.html [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/fetch/private-network-access/shared-worker-fetch.https.window.html [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/fetch/private-network-access/xhr.window.html [ Timeout ] crbug.com/626703 [ Mac10.12 ] external/wpt/scroll-to-text-fragment/scroll-to-text-fragment-security.sub.html [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] virtual/plz-dedicated-worker/external/wpt/fetch/private-network-access/worker.https.window.html [ Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/webaudio/the-audio-api/the-pannernode-interface/ctor-panner.html [ Crash ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/fetch/data-urls/processing.any.html [ Failure Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/mediacapture-record/MediaRecorder-mimetype.html [ Failure Timeout ] -crbug.com/626703 [ Mac10.13 ] external/wpt/wasm/jsapi/constructor/instantiate-bad-imports.any.html [ Timeout ] -crbug.com/626703 [ Mac10.13 ] external/wpt/wasm/jsapi/constructor/instantiate-bad-imports.any.worker.html [ Timeout ] -crbug.com/626703 [ Mac10.14 ] external/wpt/video-rvfc/request-video-frame-callback-during-xr-session.https.html [ Timeout ] -crbug.com/626703 [ Mac10.14 ] external/wpt/webxr/ar-module/xrSession_interactionMode.https.html [ Timeout ] -crbug.com/626703 [ Mac10.14 ] external/wpt/web-share/share-url-invalid.https.html [ Timeout ] -crbug.com/626703 [ Mac10.14 ] external/wpt/webxr/depth-sensing/cpu/depth_sensing_cpu_staleView.https.html [ Timeout ] crbug.com/626703 [ Mac10.14 ] virtual/portals/external/wpt/portals/no-portal-in-sandboxed-popup.html [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/fetch/private-network-access/fetch.window.html [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] wpt_internal/bluetooth/characteristic/getDescriptors/blocklisted-descriptors-not-present.https.html [ Crash Failure ] -crbug.com/626703 [ Mac11-arm64 ] wpt_internal/css/css-transforms/raster-scale-perspective-001.html [ Crash Failure ] -crbug.com/626703 [ Mac11-arm64 ] wpt_internal/css/selectors/focus-visible-select-001.html [ Crash Failure ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/fetch/private-network-access/fetch.https.window.html?include=from-treat-as-public [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] virtual/plz-dedicated-worker/external/wpt/fetch/private-network-access/fetch.window.html [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/content-security-policy/inside-worker/dedicatedworker-script-src.html [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] virtual/plz-dedicated-worker/external/wpt/content-security-policy/inside-worker/serviceworker-report-only.https.sub.html [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/css/CSS2/normal-flow/width-081.xht [ Crash Failure ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/fetch/api/basic/status.h2.any.worker.html [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/infrastructure/server/http2-websocket.sub.h2.any.worker.html [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/Close-1000-reason.any.worker.html?wpt_flags=h2 [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/Close-server-initiated-close.any.worker.html?wpt_flags=h2 [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/Create-valid-url-array-protocols.any.worker.html?wpt_flags=h2 [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/Send-binary-arraybufferview-float64.any.html?wpt_flags=h2 [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/Send-binary-arraybufferview-int16-offset.any.html?wpt_flags=h2 [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/Send-binary-arraybufferview-int16-offset.any.worker.html?wpt_flags=h2 [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/Send-binary-arraybufferview-uint32-offset.any.html?wpt_flags=h2 [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/Send-unpaired-surrogates.any.worker.html?wpt_flags=h2 [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/bufferedAmount-unchanged-by-sync-xhr.any.sharedworker.html?wpt_flags=h2 [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/constructor/022.html?wpt_flags=h2 [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/interfaces/WebSocket/events/018.html?wpt_flags=h2 [ Timeout ] crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/unload-a-document/005.html?wpt_flags=h2 [ Skip Timeout ] -crbug.com/626703 [ Mac11-arm64 ] virtual/background-svg-in-lcp/external/wpt/largest-contentful-paint/toJSON.html [ Crash ] crbug.com/626703 external/wpt/css/css-values/cap-unit-001.html [ Failure ] crbug.com/626703 [ Win10.20h2 ] external/wpt/navigation-timing/nav2_test_response_end_and_duration_before_during_and_after_load_event.html [ Timeout ] crbug.com/626703 external/wpt/selection/textcontrols/onselectionchange-content-attribute.html [ Timeout ] @@ -3582,25 +3386,17 @@ crbug.com/626703 [ Win10.20h2 ] external/wpt/mediacapture-streams/MediaDevices-enumerateDevices-per-origin-ids.sub.https.html [ Failure Timeout ] crbug.com/626703 [ Win10.20h2 ] virtual/feature-policy-permissions/external/wpt/mediacapture-streams/MediaDevices-enumerateDevices-per-origin-ids.sub.https.html [ Failure Timeout ] crbug.com/626703 [ Mac10.12 ] external/wpt/websockets/constructor/009.html?wpt_flags=h2 [ Crash Failure ] -crbug.com/626703 [ Mac10.13 ] external/wpt/scroll-to-text-fragment/scroll-to-text-fragment-security.sub.html [ Timeout ] crbug.com/626703 external/wpt/resource-timing/entries-for-network-errors.sub.https.html [ Timeout ] crbug.com/626703 virtual/plz-dedicated-worker/external/wpt/resource-timing/entries-for-network-errors.sub.https.html [ Timeout ] crbug.com/626703 [ Mac11-arm64 ] external/wpt/webrtc/RTCDataChannel-close.html [ Skip Timeout ] crbug.com/626703 [ Mac11-arm64 ] external/wpt/webrtc/RTCPeerConnection-capture-video.https.html [ Skip Timeout ] crbug.com/626703 [ Mac11-arm64 ] external/wpt/webrtc/RTCPeerConnection-iceConnectionState.https.html [ Skip Timeout ] crbug.com/626703 [ Mac11-arm64 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCDataChannel-send.html [ Skip Timeout ] -crbug.com/626703 [ Mac11-arm64 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCPeerConnection-onsignalingstatechanged.https.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] external/wpt/streams/piping/abort.any.html [ Failure Timeout ] -crbug.com/626703 [ Mac10.15 ] external/wpt/streams/piping/abort.any.sharedworker.html [ Crash Failure ] crbug.com/626703 [ Mac11-arm64 ] virtual/css-calc-infinity-and-nan-disabled/external/wpt/css/css-values/ch-unit-011.html [ Failure ] crbug.com/626703 [ Mac11-arm64 ] external/wpt/navigation-timing/nav2_test_response_end_and_duration_before_during_and_after_load_event.html [ Timeout ] crbug.com/1270841 [ Mac ] external/wpt/media-capabilities/encodingInfo.any.worker.html [ Crash ] -crbug.com/626703 [ Mac11 ] virtual/plz-dedicated-worker/external/wpt/workers/constructors/SharedWorker/setting-port-members.html [ Failure Timeout ] crbug.com/626703 [ Mac11 ] virtual/forced-high-contrast-colors/external/wpt/forced-colors-mode/forced-colors-mode-19.html [ Timeout ] -crbug.com/626703 [ Mac11 ] virtual/plz-dedicated-worker/external/wpt/fetch/metadata/redirect/multiple-redirect-https-downgrade-upgrade.sub.html [ Timeout ] crbug.com/626703 [ Mac11 ] virtual/scroll-unification-unified-autoplay/external/wpt/feature-policy/feature-policy-header-policy-declined.https.sub.html [ Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/secure-payment-confirmation/authentication-accepted.https.html [ Failure Timeout ] -crbug.com/626703 [ Mac10.15 ] external/wpt/page-visibility/minimize.html [ Failure Timeout ] crbug.com/626703 [ Win10.20h2 ] external/wpt/web-locks/bfcache/abort.tentative.https.html [ Failure Timeout ] crbug.com/626703 [ Mac11-arm64 ] external/wpt/webrtc/RTCPeerConnection-getStats.https.html [ Skip Timeout ] crbug.com/626703 [ Mac11-arm64 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCPeerConnection-createDataChannel.html [ Skip Timeout ] @@ -3610,63 +3406,15 @@ crbug.com/626703 [ Mac10.15 ] external/wpt/WebCryptoAPI/generateKey/successes_RSA-OAEP.https.any.html?1-10 [ Skip Timeout ] crbug.com/626703 [ Mac10.15 ] external/wpt/WebCryptoAPI/generateKey/successes_RSA-OAEP.https.any.worker.html?141-150 [ Skip Timeout ] crbug.com/626703 [ Mac10.15 ] external/wpt/WebCryptoAPI/import_export/ec_importKey.https.any.html [ Skip Timeout ] -crbug.com/626703 [ Mac10.15 ] external/wpt/accelerometer/Accelerometer-enabled-by-feature-policy.https.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] external/wpt/accessibility/crashtests/activedescendant-crash.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] external/wpt/navigation-api/currentchange-event/navigation-updateCurrentEntry.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] external/wpt/navigation-api/navigate-event/navigate-meta-refresh.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] external/wpt/navigation-api/navigate-event/navigateerror-ordering-location-api.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] external/wpt/navigation-api/navigation-methods/disambigaute-forward.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] external/wpt/beacon/headers/header-referrer-no-referrer-when-downgrade.https.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] external/wpt/bluetooth/characteristic/readValue/characteristic-is-removed.https.window.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/split-http-cache/external/wpt/signed-exchange/reporting/sxg-reporting-prefetch-mi_error.tentative.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/threaded-prefer-compositing/external/wpt/css/cssom-view/CaretPosition-001.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/web-bluetooth-new-permissions-backend/external/wpt/bluetooth/characteristic/notifications/service-is-removed.https.window.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/web-bluetooth-new-permissions-backend/external/wpt/bluetooth/characteristic/writeValue/write-succeeds.https.window.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/web-bluetooth-new-permissions-backend/external/wpt/bluetooth/requestDevice/canonicalizeFilter/empty-services-member.https.window.html [ Timeout ] -crbug.com/626703 [ Mac11 ] virtual/web-bluetooth-new-permissions-backend/external/wpt/bluetooth/requestDevice/canonicalizeFilter/max-length-name-unicode.https.window.html [ Crash ] -crbug.com/626703 [ Mac10.15 ] virtual/web-bluetooth-new-permissions-backend/external/wpt/bluetooth/service/getCharacteristics/characteristics-found-with-uuid.https.window.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/web-bluetooth-new-permissions-backend/external/wpt/bluetooth/service/getCharacteristics/gen-reconnect-during-with-uuid.https.window.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/web-bluetooth-new-permissions-backend/wpt_internal/bluetooth/characteristic/getDescriptors/gen-descriptor-disconnect-called-during-error-with-uuid.https.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/web-bluetooth-new-permissions-backend/wpt_internal/bluetooth/characteristic/getDescriptors/gen-descriptor-garbage-collection-ran-during-success.https.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/web-bluetooth-new-permissions-backend/wpt_internal/bluetooth/characteristic/notifications/notification-after-disconnection.https.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/web-bluetooth-new-permissions-backend/wpt_internal/bluetooth/characteristic/readValue/gen-gatt-op-garbage-collection-ran-during-success.https.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/web-bluetooth-new-permissions-backend/wpt_internal/bluetooth/characteristic/writeValueWithoutResponse/blocklisted-characteristic.https.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/web-bluetooth-new-permissions-backend/wpt_internal/bluetooth/server/getPrimaryService/gen-device-disconnects-during-success.https.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/web-bluetooth-new-permissions-backend/wpt_internal/bluetooth/server/getPrimaryServices/gen-device-disconnects-before-with-uuid.https.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/web-bluetooth-new-permissions-backend/wpt_internal/bluetooth/server/getPrimaryServices/gen-device-disconnects-invalidates-objects.https.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/web-bluetooth-new-permissions-backend/wpt_internal/bluetooth/service/getCharacteristic/gen-device-goes-out-of-range.https.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/web-bluetooth-new-permissions-backend/wpt_internal/bluetooth/service/getCharacteristic/gen-disconnect-called-before.https.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/web-bluetooth-new-permissions-backend/wpt_internal/bluetooth/service/getCharacteristics/correct-characteristics.https.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCPeerConnection-setRemoteDescription-pranswer.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCRtpReceiver-getParameters.html [ Timeout ] crbug.com/626703 [ Mac11-arm64 ] external/wpt/webrtc/RTCIceConnectionState-candidate-pair.https.html [ Skip Timeout ] crbug.com/626703 [ Mac11-arm64 ] external/wpt/webrtc/RTCPeerConnection-ondatachannel.html [ Skip Timeout ] crbug.com/626703 [ Mac11-arm64 ] external/wpt/webrtc/RTCPeerConnection-track-stats.https.html [ Skip Timeout ] crbug.com/626703 [ Mac11-arm64 ] external/wpt/webrtc/protocol/ice-state.https.html [ Skip Timeout ] crbug.com/626703 [ Mac11-arm64 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCPeerConnection-videoDetectorTest.html [ Skip Timeout ] -crbug.com/626703 [ Mac11-arm64 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/protocol/bundle.https.html [ Timeout ] crbug.com/626703 [ Linux ] external/wpt/media-capabilities/encodingInfo.any.worker.html [ Crash ] crbug.com/626703 [ Win10.20h2 ] external/wpt/media-capabilities/encodingInfo.any.worker.html [ Crash ] -crbug.com/626703 [ Mac11-arm64 ] virtual/feature-policy-permissions/external/wpt/mediacapture-streams/MediaStream-finished-add.https.html [ Crash ] crbug.com/626703 [ Mac11-arm64 ] virtual/disable-ua-ch-platform/external/wpt/client-hints/accept-ch-stickiness/same-origin-navigation.https.html [ Crash ] -crbug.com/626703 [ Mac11-arm64 ] virtual/document-domain-disabled-by-default/external/wpt/document-policy/experimental-features/document-domain/document-domain.tentative.sub.html [ Crash ] -crbug.com/626703 [ Mac11-arm64 ] virtual/disable-ua-client-hint/external/wpt/client-hints/http-equiv-accept-ch-non-secure.http.html [ Crash ] -crbug.com/626703 [ Mac11-arm64 ] virtual/feature-policy-permissions/external/wpt/mediacapture-streams/MediaStream-supported-by-feature-policy.html [ Crash ] -crbug.com/626703 [ Mac11-arm64 ] virtual/disable-ua-ch-platform/external/wpt/client-hints/accept-ch-non-secure.http.html [ Crash ] -crbug.com/626703 [ Mac11-arm64 ] virtual/disable-ua-client-hint/wpt_internal/client-hints/accept_ch_feature_policy_allow_legacy_hints.tentative.sub.https.html [ Crash ] -crbug.com/626703 [ Mac11-arm64 ] virtual/disable-ua-client-hint/external/wpt/client-hints/accept-ch-cache-revalidation.https.html [ Crash ] crbug.com/626703 [ Mac11-arm64 ] virtual/forced-high-contrast-colors/external/wpt/forced-colors-mode/backplate/forced-colors-mode-backplate-01.html [ Crash ] -crbug.com/626703 [ Mac11-arm64 ] virtual/forced-high-contrast-colors/external/wpt/forced-colors-mode/forced-colors-mode-03.html [ Crash ] -crbug.com/626703 [ Mac11-arm64 ] virtual/disable-ua-client-hint/external/wpt/client-hints/accept-ch-stickiness/same-origin-iframe.https.html [ Crash ] -crbug.com/626703 [ Mac11-arm64 ] virtual/disable-ua-client-hint/external/wpt/client-hints/service-workers/new-request-critical.https.window.html [ Crash ] -crbug.com/626703 [ Mac11-arm64 ] virtual/disable-ua-client-hint/external/wpt/client-hints/accept-ch-stickiness/same-origin-navigation.https.html [ Crash ] -crbug.com/626703 [ Mac11-arm64 ] virtual/forced-high-contrast-colors/external/wpt/forced-colors-mode/backplate/forced-colors-mode-backplate-11.html [ Crash ] -crbug.com/626703 [ Mac11-arm64 ] virtual/forced-high-contrast-colors/external/wpt/forced-colors-mode/forced-colors-mode-10.html [ Crash ] -crbug.com/626703 [ Mac11-arm64 ] virtual/feature-policy-permissions/external/wpt/mediacapture-streams/MediaStreamTrack-MediaElement-disabled-video-is-black.https.html [ Crash ] -crbug.com/626703 [ Mac11-arm64 ] virtual/fractional-scroll-offsets/external/wpt/css/css-position/sticky/position-sticky-nested-left.html [ Crash ] -crbug.com/626703 [ Mac10.15 ] external/wpt/css/css-sizing/parsing/min-height-invalid.html [ Failure Timeout ] -crbug.com/626703 [ Linux ] virtual/plz-dedicated-worker/external/wpt/xhr/event-loadstart-upload.any.worker.html [ Crash ] -crbug.com/626703 [ Mac10.15 ] virtual/plz-dedicated-worker/external/wpt/xhr/event-loadstart-upload.any.worker.html [ Crash ] crbug.com/626703 external/wpt/workers/interfaces/WorkerUtils/importScripts/blob-url.worker.html [ Failure ] crbug.com/626703 [ Linux ] external/wpt/input-events/input-events-get-target-ranges.html [ Failure Timeout ] crbug.com/626703 [ Linux ] external/wpt/input-events/input-events-get-target-ranges-non-collapsed-selection.tentative.html?TypingA [ Skip Timeout ] @@ -3681,9 +3429,6 @@ crbug.com/626703 external/wpt/editing/run/forwarddelete.html?6001-last [ Failure ] crbug.com/626703 external/wpt/selection/contenteditable/initial-selection-on-focus.tentative.html?div [ Failure ] crbug.com/626703 [ Mac10.14 ] external/wpt/css/css-sizing/aspect-ratio/replaced-element-003.html [ Failure ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/scheduler/post-task-without-signals.any.serviceworker.html [ Crash ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/scheduler/post-task-without-signals.any.worker.html [ Crash ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/scheduler/tentative/current-task-signal.any.serviceworker.html [ Crash ] crbug.com/626703 external/wpt/geolocation-API/non-fully-active.https.html [ Timeout ] crbug.com/626703 [ Linux ] external/wpt/selection/textcontrols/selectionchange-bubble.html [ Timeout ] crbug.com/626703 [ Mac10.13 ] external/wpt/selection/textcontrols/selectionchange-bubble.html [ Timeout ] @@ -3707,7 +3452,6 @@ crbug.com/626703 external/wpt/css/css-content/content-none-table.html [ Failure ] crbug.com/626703 external/wpt/css/css-content/content-none-select-2.html [ Failure ] crbug.com/626703 external/wpt/css/css-content/content-none-span.html [ Failure ] -crbug.com/626703 [ Mac11 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCPeerConnection-onsignalingstatechanged.https.html [ Timeout ] crbug.com/626703 [ Mac11 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/protocol/candidate-exchange.https.html [ Skip Timeout ] crbug.com/626703 external/wpt/css/css-align/self-alignment/self-align-safe-unsafe-flex-002.html [ Failure ] crbug.com/626703 external/wpt/css/css-align/self-alignment/self-align-safe-unsafe-flex-001.html [ Failure ] @@ -3720,22 +3464,16 @@ crbug.com/626703 [ Mac11 ] external/wpt/density-size-correction/image-set-003.html [ Failure ] crbug.com/626703 [ Win ] external/wpt/density-size-correction/image-set-003.html [ Failure ] crbug.com/626703 external/wpt/infrastructure/assumptions/non-local-ports.sub.window.html [ Timeout ] -crbug.com/626703 [ Mac10.15 ] external/wpt/mediacapture-insertable-streams/MediaStreamTrackGenerator-audio.https.html [ Crash ] crbug.com/626703 external/wpt/webrtc-extensions/transfer-datachannel-service-worker.https.html [ Timeout ] crbug.com/626703 external/wpt/webrtc-extensions/transfer-datachannel.html [ Timeout ] crbug.com/626703 [ Win ] external/wpt/websockets/Create-blocked-port.any.worker.html?wpt_flags=h2 [ Failure Timeout ] crbug.com/626703 external/wpt/FileAPI/file/send-file-formdata-controls.any.html [ Pass Timeout ] crbug.com/626703 external/wpt/FileAPI/file/send-file-formdata-controls.any.worker.html [ Pass Timeout ] -crbug.com/626703 [ Mac ] external/wpt/url/url-setters.any.html [ Failure Timeout ] -crbug.com/626703 [ Mac ] external/wpt/url/url-setters.any.worker.html [ Failure Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/css/css-counter-styles/counter-style-at-rule/name-syntax.html [ Failure Timeout ] crbug.com/626703 external/wpt/css/css-sizing/fit-content-length-percentage-015.html [ Failure ] crbug.com/626703 external/wpt/css/css-sizing/fit-content-length-percentage-014.html [ Failure ] crbug.com/626703 external/wpt/css/css-sizing/fit-content-length-percentage-001.html [ Failure ] crbug.com/626703 external/wpt/css/css-sizing/fit-content-length-percentage-010.html [ Failure ] crbug.com/626703 external/wpt/css/css-sizing/fit-content-length-percentage-016.html [ Failure ] -crbug.com/626703 [ Mac11 ] external/wpt/websockets/stream/tentative/constructor.any.sharedworker.html?wss [ Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/websockets/stream/tentative/constructor.any.worker.html?wss [ Timeout ] crbug.com/626703 external/wpt/css/css-grid/grid-model/grid-areas-overflowing-grid-container-009.html [ Failure ] crbug.com/626703 external/wpt/css/css-sizing/fit-content-length-percentage-002.html [ Failure ] crbug.com/626703 [ Mac10.14 ] external/wpt/pointerevents/pointerevent_pointercapture_in_frame.html?pen [ Timeout ] @@ -3754,31 +3492,22 @@ crbug.com/626703 [ Win ] external/wpt/websockets/remove-own-iframe-during-onerror.window.html?wss [ Failure Timeout ] crbug.com/626703 [ Win ] external/wpt/websockets/stream/tentative/constructor.any.serviceworker.html?wss [ Failure Timeout ] crbug.com/626703 [ Win ] external/wpt/websockets/stream/tentative/constructor.any.worker.html?wss [ Failure Timeout ] -crbug.com/626703 [ Win ] external/wpt/content-security-policy/reporting/report-only-in-meta.sub.html [ Failure Timeout ] -crbug.com/626703 [ Win ] virtual/plz-dedicated-worker/external/wpt/service-workers/cache-storage/worker/cache-abort.https.html [ Failure Timeout ] -crbug.com/626703 [ Win ] virtual/plz-dedicated-worker/external/wpt/service-workers/cache-storage/window/cache-abort.https.html [ Failure Timeout ] crbug.com/626703 [ Win ] external/wpt/websockets/basic-auth.any.sharedworker.html?wss [ Failure Timeout ] crbug.com/626703 [ Win ] external/wpt/websockets/stream/tentative/constructor.any.html?wss [ Failure Timeout ] crbug.com/626703 [ Win ] external/wpt/service-workers/cache-storage/serviceworker/cache-abort.https.html [ Failure Timeout ] crbug.com/626703 [ Win ] external/wpt/websockets/remove-own-iframe-during-onerror.window.html [ Failure Timeout ] crbug.com/626703 [ Win ] external/wpt/websockets/stream/tentative/constructor.any.sharedworker.html?wss [ Failure Timeout ] -crbug.com/626703 [ Win ] external/wpt/websockets/basic-auth.any.worker.html?wss [ Failure Timeout ] crbug.com/626703 [ Win ] external/wpt/websockets/constructor/010.html [ Failure Timeout ] crbug.com/626703 [ Win ] external/wpt/websockets/constructor/010.html?wss [ Failure Timeout ] crbug.com/626703 [ Win ] external/wpt/websockets/basic-auth.any.html?wss [ Failure Timeout ] crbug.com/626703 [ Win ] external/wpt/websockets/basic-auth.any.serviceworker.html?wss [ Failure Timeout ] crbug.com/626703 [ Win ] external/wpt/websockets/opening-handshake/005.html [ Failure Timeout ] -crbug.com/626703 [ Win ] external/wpt/websockets/opening-handshake/005.html?wss [ Failure Timeout ] -crbug.com/626703 [ Linux ] external/wpt/websockets/opening-handshake/005.html [ Failure Pass ] -crbug.com/626703 [ Mac10.14 ] external/wpt/webrtc/RTCSctpTransport-maxChannels.html [ Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/webrtc/RTCSctpTransport-maxChannels.html [ Timeout ] crbug.com/626703 [ Mac10.14 ] external/wpt/webrtc/RTCPeerConnection-ondatachannel.html [ Skip Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/webrtc/RTCPeerConnection-ondatachannel.html [ Skip Timeout ] crbug.com/626703 [ Mac10.14 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCDataChannel-send.html [ Skip Timeout ] crbug.com/626703 [ Mac11 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCDataChannel-send.html [ Skip Timeout ] -crbug.com/626703 [ Mac10.14 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/simplecall.https.html [ Timeout ] crbug.com/626703 [ Mac11 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/simplecall.https.html [ Timeout ] -crbug.com/626703 [ Mac11-arm64 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/simplecall.https.html [ Timeout ] crbug.com/626703 [ Mac10.14 ] external/wpt/webrtc/protocol/rtp-clockrate.html [ Skip Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/webrtc/protocol/rtp-clockrate.html [ Skip Timeout ] crbug.com/626703 [ Mac11-arm64 ] external/wpt/webrtc/protocol/rtp-clockrate.html [ Skip Timeout ] @@ -3804,8 +3533,6 @@ crbug.com/626703 [ Mac11 ] external/wpt/webrtc/RTCPeerConnection-track-stats.https.html [ Skip Timeout ] crbug.com/626703 [ Mac10.14 ] external/wpt/webrtc/protocol/ice-state.https.html [ Skip Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/webrtc/protocol/ice-state.https.html [ Skip Timeout ] -crbug.com/626703 [ Mac10.14 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCIceTransport.html [ Timeout ] -crbug.com/626703 [ Mac11 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCIceTransport.html [ Timeout ] crbug.com/626703 [ Mac10.14 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCPeerConnection-videoDetectorTest.html [ Skip Timeout ] crbug.com/626703 [ Mac11 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCPeerConnection-videoDetectorTest.html [ Skip Timeout ] crbug.com/626703 [ Mac10.14 ] external/wpt/webrtc/RTCDataChannel-bufferedAmount.html [ Skip Timeout ] @@ -3813,14 +3540,10 @@ crbug.com/626703 [ Mac11-arm64 ] external/wpt/webrtc/RTCDataChannel-bufferedAmount.html [ Skip Timeout ] crbug.com/626703 [ Mac10.14 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCPeerConnection-iceConnectionState-disconnected.https.html [ Skip Timeout ] crbug.com/626703 [ Mac11 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCPeerConnection-iceConnectionState-disconnected.https.html [ Skip Timeout ] -crbug.com/626703 [ Mac10.14 ] external/wpt/webrtc-stats/getStats-remote-candidate-address.html [ Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/webrtc-stats/getStats-remote-candidate-address.html [ Timeout ] crbug.com/626703 [ Mac10.14 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCDataChannel-iceRestart.html [ Skip Timeout ] crbug.com/626703 [ Mac11 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCDataChannel-iceRestart.html [ Skip Timeout ] crbug.com/626703 [ Mac10.14 ] external/wpt/webrtc/RTCDtlsTransport-state.html [ Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/webrtc/RTCDtlsTransport-state.html [ Timeout ] -crbug.com/626703 [ Mac10.14 ] external/wpt/webrtc/RTCIceTransport.html [ Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/webrtc/RTCIceTransport.html [ Timeout ] crbug.com/626703 [ Mac10.14 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/protocol/ice-state.https.html [ Skip Timeout ] crbug.com/626703 [ Mac11 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/protocol/ice-state.https.html [ Skip Timeout ] crbug.com/626703 [ Mac10.14 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCDTMFSender-ontonechange.https.html [ Skip Timeout ] @@ -3828,25 +3551,16 @@ crbug.com/626703 [ Mac10.14 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/protocol/rtp-clockrate.html [ Skip Timeout ] crbug.com/626703 [ Mac11 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/protocol/rtp-clockrate.html [ Skip Timeout ] crbug.com/626703 [ Mac11-arm64 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/protocol/rtp-clockrate.html [ Skip Timeout ] -crbug.com/626703 [ Mac10.14 ] external/wpt/webrtc/simplecall.https.html [ Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/webrtc/simplecall.https.html [ Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/webrtc/protocol/split.https.html [ Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/webrtc/RTCPeerConnection-connectionState.https.html [ Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/webrtc/RTCDataChannel-close.html [ Skip Timeout ] -crbug.com/626703 [ Mac11 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCPeerConnection-connectionState.https.html [ Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/webrtc/protocol/candidate-exchange.https.html [ Skip Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/webrtc/protocol/bundle.https.html [ Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/webrtc/RTCPeerConnection-getStats.https.html [ Skip Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/webrtc/protocol/crypto-suite.https.html [ Timeout ] crbug.com/626703 [ Mac11 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCDataChannel-bufferedAmount.html [ Skip Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/webrtc/RTCPeerConnection-onsignalingstatechanged.https.html [ Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/webrtc/RTCDtlsTransport-getRemoteCertificates.html [ Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/webrtc/no-media-call.html [ Timeout ] crbug.com/626703 [ Mac11 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCPeerConnection-ondatachannel.html [ Skip Timeout ] crbug.com/626703 [ Mac11-arm64 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCPeerConnection-ondatachannel.html [ Skip Timeout ] crbug.com/626703 [ Mac11 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCDataChannel-close.html [ Skip Timeout ] crbug.com/626703 [ Mac11-arm64 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCDataChannel-close.html [ Skip Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/webrtc/promises-call.html [ Timeout ] crbug.com/626703 [ Mac11 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCPeerConnection-createDataChannel.html [ Skip Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/webrtc/RTCPeerConnection-addIceCandidate-connectionSetup.html [ Skip Timeout ] crbug.com/626703 [ Mac11-arm64 ] external/wpt/webrtc/RTCPeerConnection-addIceCandidate-connectionSetup.html [ Skip Timeout ] @@ -3855,7 +3569,6 @@ crbug.com/626703 [ Mac11 ] external/wpt/video-rvfc/request-video-frame-callback-webrtc.https.html [ Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/webrtc/protocol/rtp-demuxing.html [ Skip Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/webrtc/RTCIceConnectionState-candidate-pair.https.html [ Skip Timeout ] -crbug.com/626703 [ Mac11 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/protocol/dtls-fingerprint-validation.html [ Timeout ] crbug.com/1209223 external/wpt/html/syntax/xmldecl/xmldecl-2.html [ Failure ] crbug.com/626703 [ Mac ] editing/pasteboard/drag-selected-image-to-contenteditable.html [ Failure ] crbug.com/626703 [ Mac11 ] external/wpt/webxr/xrSession_requestReferenceSpace_features.https.html [ Timeout ] @@ -3884,57 +3597,25 @@ crbug.com/626703 [ Win ] external/wpt/focus/focus-already-focused-iframe-same-site.html [ Timeout ] crbug.com/626703 external/wpt/focus/focus-already-focused-iframe-deep-different-site.html [ Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/content-security-policy/securitypolicyviolation/source-file-data-scheme.html [ Failure Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/websockets/Create-protocols-repeated-case-insensitive.any.html?wss [ Failure Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/Create-protocols-repeated-case-insensitive.any.html?wss [ Failure Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/websockets/basic-auth.any.worker.html?wpt_flags=h2 [ Failure Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/basic-auth.any.worker.html?wpt_flags=h2 [ Failure Timeout ] -crbug.com/626703 [ Mac10.14 ] external/wpt/worklets/paint-worklet-credentials.https.html [ Failure Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/css/css-images/image-set/image-set-parsing.html [ Failure Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/dom/xslt/transformToFragment.tentative.window.html [ Failure Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/editing/other/editing-around-select-element.tentative.html?insertText [ Failure Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/editing/other/editing-around-select-element.tentative.html?insertText [ Failure Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/fetch/api/basic/request-upload.any.serviceworker.html [ Failure Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/shadow-dom/accesskey.tentative.html [ Failure Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/websockets/basic-auth.any.sharedworker.html?wpt_flags=h2 [ Failure Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/basic-auth.any.sharedworker.html?wpt_flags=h2 [ Failure Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/webvtt/api/VTTCue/constructor.html [ Failure Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/websockets/stream/tentative/backpressure-send.any.worker.html?wpt_flags=h2 [ Crash Failure ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/stream/tentative/backpressure-send.any.worker.html?wpt_flags=h2 [ Crash Failure ] crbug.com/626703 [ Mac11 ] external/wpt/websockets/stream/tentative/backpressure-send.any.html?wpt_flags=h2 [ Failure Timeout ] -crbug.com/626703 [ Mac11-arm64 ] external/wpt/websockets/stream/tentative/backpressure-send.any.html?wpt_flags=h2 [ Failure Timeout ] crbug.com/626703 [ Mac10.15 ] external/wpt/websockets/stream/tentative/backpressure-receive.any.html?wpt_flags=h2 [ Failure Pass ] crbug.com/626703 [ Mac ] external/wpt/websockets/bufferedAmount-unchanged-by-sync-xhr.any.worker.html?wpt_flags=h2 [ Failure Pass ] crbug.com/626703 [ Mac ] external/wpt/websockets/basic-auth.any.html?wpt_flags=h2 [ Failure Pass ] -crbug.com/626703 [ Mac10.15 ] external/wpt/worklets/audio-worklet-credentials.https.html [ Crash Failure ] -crbug.com/626703 [ Mac10.15 ] external/wpt/websockets/stream/tentative/constructor.any.html?wpt_flags=h2 [ Failure Timeout ] crbug.com/626703 [ Win ] external/wpt/websockets/stream/tentative/constructor.any.html?wpt_flags=h2 [ Failure Timeout ] crbug.com/626703 [ Win ] external/wpt/websockets/stream/tentative/backpressure-send.any.html?wpt_flags=h2 [ Failure Timeout ] -crbug.com/626703 [ Mac10.15 ] external/wpt/fetch/api/basic/request-upload.any.serviceworker.html [ Crash Failure Timeout ] -crbug.com/626703 [ Mac10.15 ] external/wpt/editing/other/editing-around-select-element.tentative.html?insertText [ Crash Failure Timeout ] crbug.com/626703 [ Mac ] external/wpt/custom-elements/form-associated/ElementInternals-setFormValue.html [ Crash Pass Timeout ] crbug.com/626703 [ Win ] external/wpt/custom-elements/form-associated/ElementInternals-setFormValue.html [ Pass Timeout ] -crbug.com/626703 [ Mac10.15 ] external/wpt/fetch/api/basic/request-upload.any.sharedworker.html [ Failure Timeout ] -crbug.com/626703 [ Mac10.15 ] external/wpt/mediacapture-image/MediaStreamTrack-getConstraints.https.html [ Crash Failure Timeout ] -crbug.com/626703 [ Mac10.15 ] external/wpt/webvtt/api/VTTCue/constructor.html [ Crash Failure ] -crbug.com/626703 [ Mac10.15 ] external/wpt/dom/xslt/transformToFragment.tentative.window.html [ Crash Failure ] -crbug.com/626703 [ Mac10.15 ] external/wpt/shadow-dom/accesskey.tentative.html [ Failure Timeout ] crbug.com/626703 [ Win10.20h2 ] external/wpt/websockets/stream/tentative/backpressure-send.any.sharedworker.html?wpt_flags=h2 [ Failure Timeout ] -crbug.com/626703 [ Mac10.14 ] external/wpt/websockets/stream/tentative/backpressure-send.any.html?wpt_flags=h2 [ Failure Timeout ] crbug.com/626703 external/wpt/websockets/stream/tentative/close.any.worker.html?wpt_flags=h2 [ Failure Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/plz-dedicated-worker/external/wpt/fetch/api/basic/http-response-code.any.html [ Crash Failure ] -crbug.com/626703 [ Mac10.15 ] external/wpt/fetch/api/basic/http-response-code.any.sharedworker.html [ Crash Failure ] -crbug.com/626703 [ Mac ] external/wpt/FileAPI/file/send-file-formdata-controls.html [ Crash Pass ] -crbug.com/626703 [ Win ] external/wpt/FileAPI/file/send-file-formdata-controls.html [ Crash Pass ] crbug.com/626703 [ Mac ] external/wpt/websockets/stream/tentative/abort.any.serviceworker.html?wpt_flags=h2 [ Crash Failure Pass ] -crbug.com/626703 [ Mac10.15 ] external/wpt/websockets/stream/tentative/abort.any.sharedworker.html?wpt_flags=h2 [ Crash Failure ] -crbug.com/626703 [ Mac10.12 ] external/wpt/websockets/stream/tentative/backpressure-send.any.html?wpt_flags=h2 [ Failure Timeout ] crbug.com/626703 [ Mac10.13 ] external/wpt/websockets/stream/tentative/backpressure-send.any.html?wpt_flags=h2 [ Failure Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/offsetparent-old-behavior/external/wpt/shadow-dom/accesskey.tentative.html [ Crash Failure ] crbug.com/626703 external/wpt/websockets/stream/tentative/close.any.html?wpt_flags=h2 [ Failure Timeout ] crbug.com/626703 external/wpt/websockets/stream/tentative/close.any.sharedworker.html?wpt_flags=h2 [ Failure Timeout ] crbug.com/626703 external/wpt/websockets/stream/tentative/close.any.serviceworker.html?wpt_flags=h2 [ Failure Timeout ] -crbug.com/626703 [ Mac10.13 ] external/wpt/selection/contenteditable/modifying-selection-with-primary-mouse-button.tentative.html [ Crash Failure ] -crbug.com/626703 [ Mac10.15 ] external/wpt/streams/readable-streams/tee.any.worker.html [ Failure ] crbug.com/1191547 external/wpt/html/semantics/forms/the-label-element/proxy-modifier-click-to-associated-element.tentative.html [ Timeout ] crbug.com/626703 external/wpt/websockets/cookies/001.html?wss&wpt_flags=https [ Failure ] crbug.com/626703 external/wpt/websockets/cookies/002.html?wss&wpt_flags=https [ Failure ] @@ -3947,8 +3628,6 @@ crbug.com/626703 external/wpt/uievents/keyboard/modifier-keys-combinations.html [ Timeout ] crbug.com/626703 external/wpt/uievents/keyboard/modifier-keys.html [ Timeout ] crbug.com/626703 [ Mac10.13 ] external/wpt/webxr/xrSession_requestReferenceSpace_features.https.html [ Timeout ] -crbug.com/626703 [ Linux ] external/wpt/webmessaging/with-ports/011.html [ Timeout ] -crbug.com/626703 [ Mac10.13 ] external/wpt/webmessaging/without-ports/011.html [ Timeout ] crbug.com/626703 [ Mac10.13 ] virtual/threaded/external/wpt/web-animations/timing-model/animations/updating-the-finished-state.html [ Skip Timeout ] crbug.com/626703 external/wpt/editing/other/typing-around-link-element-at-non-collapsed-selection.tentative.html?target=ContentEditable&parent=b [ Failure Timeout ] crbug.com/626703 external/wpt/editing/other/typing-around-link-element-at-collapsed-selection.tentative.html?target=ContentEditable [ Failure Timeout ] @@ -3970,13 +3649,6 @@ crbug.com/626703 external/wpt/input-events/input-events-get-target-ranges-deleting-in-list-items.tentative.html?Backspace,ol [ Failure Timeout ] crbug.com/626703 external/wpt/input-events/input-events-get-target-ranges-deleting-in-list-items.tentative.html?Delete,ol [ Failure Timeout ] crbug.com/626703 external/wpt/mediacapture-record/MediaRecorder-stop.html [ Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/fetch/api/response/response-clone.any.worker.html [ Failure Timeout ] -crbug.com/626703 [ Mac11 ] virtual/plz-dedicated-worker/external/wpt/fetch/api/response/response-clone.any.sharedworker.html [ Failure Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/fetch/api/response/response-clone.any.serviceworker.html [ Failure Timeout ] -crbug.com/626703 [ Mac10.15 ] virtual/plz-dedicated-worker/external/wpt/fetch/api/response/response-clone.any.serviceworker.html [ Failure Timeout ] -crbug.com/626703 [ Mac11 ] virtual/plz-dedicated-worker/external/wpt/fetch/api/response/response-clone.any.serviceworker.html [ Failure Timeout ] -crbug.com/626703 [ Mac11 ] external/wpt/fetch/api/response/response-clone.any.html [ Failure Timeout ] -crbug.com/626703 [ Mac11 ] virtual/plz-dedicated-worker/external/wpt/fetch/api/response/response-clone.any.html [ Failure Timeout ] crbug.com/626703 [ Mac ] external/wpt/webxr/xr_viewport_scale.https.html [ Timeout ] crbug.com/626703 external/wpt/editing/other/select-all-and-delete-in-html-element-having-contenteditable.html [ Failure Timeout ] crbug.com/626703 external/wpt/paint-timing/with-first-paint/first-contentful-image.html [ Timeout ] @@ -3984,48 +3656,20 @@ crbug.com/626703 external/wpt/paint-timing/with-first-paint/first-contentful-paint.html [ Timeout ] crbug.com/626703 external/wpt/paint-timing/with-first-paint/child-painting-first-image.html [ Timeout ] crbug.com/626703 external/wpt/paint-timing/with-first-paint/sibling-painting-first-image.html [ Timeout ] -crbug.com/626703 external/wpt/paint-timing/with-first-paint/border-image.html [ Timeout ] crbug.com/626703 external/wpt/infrastructure/testdriver/actions/iframe.html [ Failure Timeout ] crbug.com/626703 external/wpt/infrastructure/testdriver/actions/crossOrigin.sub.html [ Timeout ] crbug.com/626703 external/wpt/input-events/input-events-get-target-ranges-during-and-after-dispatch.tentative.html [ Failure Timeout ] crbug.com/626703 [ Mac11 ] external/wpt/scroll-to-text-fragment/redirects.html [ Skip Timeout ] crbug.com/626703 external/wpt/input-events/input-events-get-target-ranges-non-collapsed-selection.tentative.html?Backspace [ Failure Timeout ] -crbug.com/626703 [ Fuchsia ] external/wpt/input-events/input-events-get-target-ranges-non-collapsed-selection.tentative.html?TypingA [ Failure Timeout ] crbug.com/626703 [ Mac ] external/wpt/input-events/input-events-get-target-ranges-non-collapsed-selection.tentative.html?TypingA [ Failure Timeout ] crbug.com/626703 [ Win ] external/wpt/input-events/input-events-get-target-ranges-non-collapsed-selection.tentative.html?TypingA [ Failure Timeout ] crbug.com/626703 external/wpt/input-events/input-events-get-target-ranges-non-collapsed-selection.tentative.html?Delete [ Failure Timeout ] -crbug.com/626703 external/wpt/screen-capture/feature-policy.https.html [ Timeout ] -crbug.com/626703 [ Fuchsia ] virtual/threaded/external/wpt/animation-worklet/worklet-animation-pause-immediately.https.html [ Failure ] crbug.com/626703 [ Mac ] external/wpt/web-locks/query-ordering.tentative.https.html [ Failure Pass ] crbug.com/626703 external/wpt/fetch/connection-pool/network-partition-key.html [ Failure Timeout ] crbug.com/626703 external/wpt/input-events/input-events-get-target-ranges-backspace.tentative.html [ Failure Timeout ] crbug.com/626703 external/wpt/input-events/input-events-get-target-ranges-forwarddelete.tentative.html [ Failure Timeout ] crbug.com/626703 [ Mac ] external/wpt/dom/events/scrolling/scrollend-event-for-user-scroll.html [ Failure Timeout ] crbug.com/626703 [ Win ] external/wpt/dom/events/scrolling/scrollend-event-for-user-scroll.html [ Failure Timeout ] -crbug.com/626703 external/wpt/workers/Worker-replace-self.any.html [ Timeout ] -crbug.com/626703 external/wpt/cookie-store/cookieStoreManager_getSubscriptions_multiple.tentative.https.any.worker.html [ Timeout ] -crbug.com/626703 external/wpt/cookie-store/serviceworker_oncookiechange_eventhandler_single_subscription.tentative.https.any.html [ Timeout ] -crbug.com/626703 external/wpt/cookie-store/cookieStoreManager_getSubscriptions_single.tentative.https.any.worker.html [ Timeout ] -crbug.com/626703 external/wpt/workers/SharedWorker-replace-EventHandler.any.html [ Timeout ] -crbug.com/626703 external/wpt/workers/SharedWorker-MessageEvent-source.any.html [ Timeout ] -crbug.com/626703 external/wpt/workers/examples/onconnect.any.html [ Timeout ] -crbug.com/626703 external/wpt/service-workers/service-worker/global-serviceworker.https.any.html [ Timeout ] -crbug.com/626703 external/wpt/workers/SharedWorker-replace-EventHandler.any.worker.html [ Timeout ] -crbug.com/626703 external/wpt/cookie-store/serviceworker_cookiechange_eventhandler_mismatched_subscription.tentative.https.any.html [ Timeout ] -crbug.com/626703 external/wpt/workers/interfaces/WorkerGlobalScope/self.any.html [ Timeout ] -crbug.com/626703 external/wpt/cookie-store/cookieStoreManager_getSubscriptions_empty.tentative.https.any.worker.html [ Timeout ] -crbug.com/626703 external/wpt/cookie-store/serviceworker_cookiechange_eventhandler_single_subscription.tentative.https.any.html [ Timeout ] -crbug.com/626703 external/wpt/cookie-store/serviceworker_cookiechange_eventhandler_overlapping_subscriptions.tentative.https.any.html [ Timeout ] -crbug.com/626703 external/wpt/cookie-store/serviceworker_cookiechange_eventhandler_overlapping_subscriptions.tentative.https.any.worker.html [ Timeout ] -crbug.com/626703 external/wpt/cookie-store/serviceworker_cookiechange_eventhandler_mismatched_subscription.tentative.https.any.worker.html [ Timeout ] -crbug.com/626703 external/wpt/cookie-store/cookieStore_subscribe_arguments.tentative.https.any.worker.html [ Timeout ] -crbug.com/626703 external/wpt/workers/SharedWorker-MessageEvent-source.any.worker.html [ Timeout ] -crbug.com/626703 external/wpt/cookie-store/serviceworker_cookiechange_eventhandler_multiple_subscriptions.tentative.https.any.html [ Timeout ] -crbug.com/626703 external/wpt/cookie-store/serviceworker_cookiechange_eventhandler_multiple_subscriptions.tentative.https.any.worker.html [ Timeout ] -crbug.com/626703 external/wpt/cookie-store/serviceworker_cookiechange_eventhandler_single_subscription.tentative.https.any.worker.html [ Timeout ] -crbug.com/626703 external/wpt/service-workers/service-worker/global-serviceworker.https.any.worker.html [ Timeout ] -crbug.com/626703 external/wpt/workers/examples/onconnect.any.worker.html [ Timeout ] -crbug.com/626703 external/wpt/cookie-store/serviceworker_oncookiechange_eventhandler_single_subscription.tentative.https.any.worker.html [ Timeout ] crbug.com/626703 external/wpt/workers/postMessage_block.https.html [ Timeout ] crbug.com/626703 external/wpt/uievents/order-of-events/focus-events/focus-management-expectations.html [ Timeout ] crbug.com/626703 [ Mac10.14 ] external/wpt/preload/onload-event.html [ Skip Timeout ] @@ -4034,18 +3678,9 @@ crbug.com/626703 external/wpt/webrtc/RTCPeerConnection-operations.https.html [ Timeout ] crbug.com/626703 external/wpt/content-dpr/content-dpr-various-elements.html [ Failure ] crbug.com/626703 external/wpt/workers/abrupt-completion.html [ Timeout ] -crbug.com/626703 [ Mac10.12 ] external/wpt/eventsource/eventsource-constructor-url-bogus.any.html [ Failure Timeout ] -crbug.com/626703 [ Mac10.12 ] external/wpt/WebCryptoAPI/derive_bits_keys/hkdf.https.any.html?1-1000 [ Failure Timeout ] -crbug.com/626703 [ Mac10.12 ] external/wpt/css/cssom/CSSStyleSheet-constructable.html [ Failure Timeout ] -crbug.com/626703 [ Mac10.12 ] external/wpt/WebCryptoAPI/derive_bits_keys/hkdf.https.any.worker.html?1001-2000 [ Failure Timeout ] -crbug.com/626703 [ Mac10.13 ] external/wpt/WebCryptoAPI/derive_bits_keys/hkdf.https.any.worker.html?1001-2000 [ Failure Timeout ] -crbug.com/626703 [ Mac10.12 ] external/wpt/WebCryptoAPI/derive_bits_keys/hkdf.https.any.html?3001-last [ Failure Timeout ] -crbug.com/626703 [ Win7 ] external/wpt/content-security-policy/object-src/object-src-no-url-allowed.html [ Timeout ] crbug.com/626703 external/wpt/service-workers/service-worker/ready.https.window.html [ Timeout ] crbug.com/626703 [ Win7 ] external/wpt/pointerevents/pointerevent_touch-action-pan-x-css_touch.html [ Timeout ] crbug.com/626703 [ Win7 ] external/wpt/pointerevents/pointerevent_touch-action-pan-left-css_touch.html [ Timeout ] -crbug.com/626703 [ Mac10.13 ] external/wpt/screen-capture/getdisplaymedia.https.html [ Failure Timeout ] -crbug.com/626703 [ Mac10.14 ] external/wpt/screen-capture/getdisplaymedia.https.html [ Failure Timeout ] crbug.com/626703 external/wpt/fetch/corb/script-resource-with-nonsniffable-types.tentative.sub.html [ Timeout ] crbug.com/626703 [ Win ] external/wpt/webvtt/rendering/cues-with-video/processing-model/embedded_style_media_queries.html [ Failure ] crbug.com/626703 [ Win ] external/wpt/webvtt/rendering/cues-with-video/processing-model/embedded_style_media_queries_resized.html [ Failure ] @@ -4056,17 +3691,13 @@ crbug.com/626703 [ Win7 ] external/wpt/pointerevents/pointerevent_touch-action-pan-y-css_touch.html [ Skip Timeout ] crbug.com/626703 [ Win ] external/wpt/web-animations/timing-model/animation-effects/phases-and-states.html [ Crash ] crbug.com/626703 external/wpt/webvtt/rendering/cues-with-video/processing-model/snap-to-line.html [ Failure ] -crbug.com/626703 [ Win7 ] external/wpt/IndexedDB/structured-clone.any.html [ Timeout ] crbug.com/626703 [ Win7 ] external/wpt/pointerevents/pointerevent_touch-action-svg-none-test_touch.html [ Skip Timeout ] -crbug.com/626703 [ Win7 ] external/wpt/pointerevents/extension/pointerevent_touch-action-pan-right-css_touch.html [ Timeout ] crbug.com/626703 external/wpt/webrtc/RTCPeerConnection-setRemoteDescription-offer.html [ Timeout ] crbug.com/626703 external/wpt/webauthn/idlharness-manual.https.window.js [ Skip ] crbug.com/1004760 [ Mac ] external/wpt/html/semantics/embedded-content/media-elements/ready-states/autoplay-hidden.optional.html [ Timeout ] crbug.com/626703 external/wpt/mediacapture-streams/MediaStream-MediaElement-srcObject.https.html [ Timeout ] crbug.com/626703 [ Mac10.12 ] external/wpt/preload/download-resources.html [ Failure Timeout ] crbug.com/626703 [ Mac10.13 ] external/wpt/preload/download-resources.html [ Failure Timeout ] -crbug.com/626703 [ Mac10.13 ] external/wpt/preload/onload-event.html [ Failure Timeout ] -crbug.com/626703 external/wpt/xhr/abort-after-stop.any.worker.html [ Timeout ] crbug.com/626703 external/wpt/speech-api/SpeechSynthesisUtterance-volume-manual.html [ Skip ] crbug.com/626703 crbug.com/606367 external/wpt/pointerevents/pointerevent_touch-action-pan-x-pan-y-pan-y_touch.html [ Failure Pass Timeout ] crbug.com/626703 crbug.com/606367 external/wpt/pointerevents/pointerevent_touch-action-none-css_touch.html [ Failure Pass Timeout ] @@ -4083,31 +3714,19 @@ crbug.com/626703 external/wpt/css/css-will-change/will-change-abspos-cb-dynamic-001.html [ Failure ] crbug.com/626703 external/wpt/css/css-will-change/will-change-abspos-cb-001.html [ Failure ] crbug.com/626703 [ Linux ] external/wpt/url/a-element.html [ Failure ] -crbug.com/626703 [ Linux ] external/wpt/websockets/Create-protocols-repeated-case-insensitive.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/626703 [ Linux ] external/wpt/websockets/Create-url-with-space.any.html [ Failure ] -crbug.com/626703 [ Linux ] external/wpt/websockets/stream/tentative/abort.any.sharedworker.html?wpt_flags=h2 [ Failure ] -crbug.com/626703 [ Linux ] external/wpt/websockets/stream/tentative/constructor.any.html?wpt_flags=h2 [ Failure ] -crbug.com/626703 [ Linux ] external/wpt/websockets/stream/tentative/constructor.any.sharedworker.html?wpt_flags=h2 [ Failure ] -crbug.com/626703 [ Mac ] external/wpt/websockets/Create-blocked-port.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/626703 [ Win ] external/wpt/websockets/Create-url-with-space.any.html [ Failure ] crbug.com/626703 [ Mac ] external/wpt/webrtc/RTCDTMFSender-ontonechange-long.https.html [ Failure Pass ] crbug.com/626703 [ Mac ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCDTMFSender-ontonechange-long.https.html [ Failure Pass ] crbug.com/626703 [ Mac10.12 ] external/wpt/payment-handler/idlharness.https.any.serviceworker.html [ Failure ] crbug.com/626703 [ Mac10.12 ] external/wpt/payment-request/idlharness.https.window.html [ Failure ] -crbug.com/626703 [ Mac10.12 ] external/wpt/private-click-measurement/idlharness.window.html [ Failure ] crbug.com/626703 [ Mac10.12 ] external/wpt/service-workers/idlharness.https.any.serviceworker.html [ Failure ] crbug.com/626703 [ Mac10.12 ] external/wpt/service-workers/idlharness.https.any.worker.html [ Failure ] -crbug.com/626703 [ Mac10.12 ] external/wpt/streams/idlharness.any.html [ Failure ] -crbug.com/626703 [ Mac10.12 ] external/wpt/streams/idlharness.any.sharedworker.html [ Failure ] crbug.com/626703 [ Mac10.12 ] external/wpt/webhid/idlharness.https.window.html [ Failure ] -crbug.com/626703 [ Mac10.12 ] virtual/plz-dedicated-worker/external/wpt/service-workers/idlharness.https.any.sharedworker.html [ Failure ] -crbug.com/626703 [ Mac10.12 ] virtual/plz-dedicated-worker/external/wpt/service-workers/idlharness.https.any.worker.html [ Failure ] crbug.com/626703 [ Mac10.12 ] virtual/portals/external/wpt/portals/idlharness.window.html [ Failure ] ### virtual/prerender/external/wpt/speculation-rules/prerender crbug.com/1126305 [ Mac10.15 ] virtual/prerender/external/wpt/speculation-rules/prerender/local-storage.html [ Skip Timeout ] crbug.com/1126305 [ Linux ] virtual/prerender/external/wpt/speculation-rules/prerender/local-storage.html [ Skip Timeout ] -crbug.com/1126305 [ Linux ] virtual/prerender/external/wpt/speculation-rules/prerender/media-autoplay.html [ Failure Timeout ] crbug.com/1126305 virtual/prerender/external/wpt/speculation-rules/prerender/restrictions.html [ Skip Timeout ] ### See crbug.com/891427 comment near the top of this file: @@ -4182,13 +3801,10 @@ crbug.com/626703 external/wpt/css/CSS2/text/white-space-mixed-001.xht [ Failure ] crbug.com/626703 external/wpt/css/css-tables/floats/floats-wrap-bfc-006b.xht [ Failure ] crbug.com/626703 external/wpt/css/css-tables/floats/floats-wrap-bfc-006c.xht [ Failure ] -crbug.com/626703 external/wpt/IndexedDB/request-abort-ordering.html [ Failure Pass ] crbug.com/626703 external/wpt/media-source/mediasource-avtracks.html [ Crash Failure ] crbug.com/626703 external/wpt/media-source/mediasource-getvideoplaybackquality.html [ Failure Timeout ] -crbug.com/626703 external/wpt/pointerevents/pointerevent_disabled_form_control-manual.html [ Pass Timeout ] crbug.com/958104 external/wpt/presentation-api/controlling-ua/getAvailability.https.html [ Failure ] crbug.com/626703 external/wpt/screen-orientation/onchange-event-subframe.html [ Timeout ] -crbug.com/626703 virtual/plz-dedicated-worker/external/wpt/xhr/event-readystatechange-loaded.htm [ Failure Timeout ] # Synthetic modules report the wrong location in errors crbug.com/994315 virtual/json-modules/external/wpt/html/semantics/scripting-1/the-script-element/json-module/parse-error.html [ Skip ] @@ -4199,9 +3815,7 @@ # Moved from NeverFixTests. These may be relevant again now that # overlay scrollbars have been fixed (crrev.com/c/3455024). -crbug.com/1296816 [ Win ] virtual/overlay-scrollbar/body-quirk-client-size.html [ Failure ] crbug.com/1296816 [ Win ] virtual/overlay-scrollbar/plugin-overlay-scrollbar-mouse-capture.html [ Failure ] -crbug.com/1296816 [ Win ] virtual/overlay-scrollbar/root-client-size.html [ Failure ] crbug.com/964181 external/wpt/css/css-text/overflow-wrap/overflow-wrap-anywhere-inline-002.html [ Failure ] crbug.com/964181 external/wpt/css/css-text/overflow-wrap/overflow-wrap-anywhere-inline-003.html [ Failure ] @@ -4474,7 +4088,6 @@ crbug.com/1236992 svg/dom/SVGListPropertyTearOff-gccrash.html [ Failure Pass ] # [css-animations] -crbug.com/993365 external/wpt/css/css-transitions/Element-getAnimations.tentative.html [ Failure Pass ] crbug.com/816956 [ Win ] external/wpt/css/css-animations/KeyframeEffect-getKeyframes.tentative.html [ Failure ] crbug.com/664450 http/tests/devtools/console/console-on-animation-worklet.js [ Skip ] @@ -4486,8 +4099,6 @@ crbug.com/825798 external/wpt/html/semantics/embedded-content/media-elements/track/track-element/track-webvtt-non-snap-to-lines.html [ Failure ] -crbug.com/1093188 external/wpt/html/semantics/embedded-content/media-elements/track/track-element/track-webvtt-two-cue-layout-after-first-end.html [ Failure Pass ] - # This test requires a special browser flag and seems not suitable for a wpt test, see bug. crbug.com/691944 external/wpt/service-workers/service-worker/update-after-oneday.https.html [ Skip ] @@ -4524,8 +4135,6 @@ # ====== Random order flaky tests end here ====== # ====== Tests from enabling .any.js/.worker.js tests begin here ====== -crbug.com/709227 external/wpt/console/console-time-label-conversion.any.html [ Failure ] -crbug.com/709227 external/wpt/console/console-time-label-conversion.any.worker.html [ Failure ] crbug.com/709227 external/wpt/html/browsers/history/the-location-interface/per-global.window.html [ Failure ] crbug.com/709227 external/wpt/html/canvas/offscreen/path-objects/2d.path.stroke.prune.arc.worker.html [ Failure ] crbug.com/709227 external/wpt/html/canvas/offscreen/path-objects/2d.path.stroke.prune.closed.worker.html [ Failure ] @@ -4567,8 +4176,6 @@ crbug.com/1157857 virtual/percent-based-scrolling/max-percent-delta-cross-origin-iframes.html [ Failure Pass Timeout ] -crbug.com/683800 [ Debug Win7 ] external/wpt/selection/* [ Failure Pass ] - crbug.com/716320 external/wpt/html/infrastructure/safe-passing-of-structured-data/shared-array-buffers/broadcastchannel-success-and-failure.https.html [ Failure Timeout ] # Test timing out when SharedArrayBuffer is disabled by default. @@ -4598,7 +4205,6 @@ crbug.com/852645 external/wpt/fullscreen/api/element-request-fullscreen-two-iframes-manual.html [ Failure Timeout ] # snav tests fail because of a DCHECK -crbug.com/985520 virtual/focusless-spat-nav/fast/spatial-navigation/focusless/snav-focusless-enter-from-interest-a11y.html [ Crash ] crbug.com/985520 virtual/focusless-spat-nav/fast/spatial-navigation/focusless/snav-focusless-enter-from-interest.html [ Crash ] # User-Agent is not able to be set on XHR/fetch @@ -4623,8 +4229,6 @@ # Sheriff failures 2018-08-15 crbug.com/874837 [ Win ] ietestcenter/css3/bordersbackgrounds/background-attachment-local-scrolling.htm [ Failure Pass ] crbug.com/874837 [ Linux ] ietestcenter/css3/bordersbackgrounds/background-attachment-local-scrolling.htm [ Failure Pass ] -crbug.com/874931 virtual/threaded-prefer-compositing/fast/scroll-behavior/smooth-scroll/mousewheel-scroll.html [ Crash Failure Pass ] -crbug.com/875003 [ Win ] editing/caret/caret-is-hidden-when-no-focus.html [ Failure Pass ] # Sheiff failures 2021-04-09 crbug.com/1197444 [ Linux ] virtual/scroll-unification-prefer_compositing_to_lcd_text/scrollbars/overlay-scrollbar-over-child-layer-nested-2.html [ Crash Failure Pass ] @@ -4679,8 +4283,6 @@ crbug.com/831942 media/webkit-media-controls-webkit-appearance.html [ Failure Pass ] crbug.com/832157 external/wpt/html/semantics/embedded-content/media-elements/track/track-element/track-cue-rendering-after-controls-added.html [ Skip ] crbug.com/832169 media/media-controls-fit-properly-while-zoomed.html [ Failure Pass ] -crbug.com/832447 media/controls/controls-page-zoom-in.html [ Failure Pass ] -crbug.com/832447 media/controls/controls-page-zoom-out.html [ Failure Pass ] crbug.com/849694 [ Mac ] http/tests/media/controls/toggle-class-with-state-source-buffer.html [ Failure Pass ] # Tests currently failing on Windows when run on Swarming @@ -4697,8 +4299,6 @@ crbug.com/757165 [ Win ] fast/spatial-navigation/snav-div-scrollable-but-without-focusable-content.html [ Crash Failure Pass Timeout ] crbug.com/757165 [ Win ] fast/spatial-navigation/snav-fully-aligned-horizontally.html [ Crash Failure Pass Timeout ] crbug.com/757165 [ Win ] fast/spatial-navigation/snav-fully-aligned-vertically.html [ Crash Failure Pass Timeout ] -crbug.com/757165 [ Win ] fast/spatial-navigation/snav-hidden-iframe.html [ Crash Failure Pass Timeout ] -crbug.com/757165 [ Win ] fast/spatial-navigation/snav-hidden-iframe-zero-size.html [ Crash Failure Pass Timeout ] crbug.com/757165 [ Win ] fast/spatial-navigation/snav-iframe-recursive-offset-parent.html [ Crash Failure Pass Timeout ] crbug.com/757165 [ Win ] fast/spatial-navigation/snav-imagemap-area-not-focusable.html [ Crash Failure Pass Timeout ] crbug.com/757165 [ Win ] fast/spatial-navigation/snav-imagemap-area-without-image.html [ Crash Failure Pass Timeout ] @@ -4751,14 +4351,13 @@ crbug.com/757165 [ Win ] virtual/gpu/fast/canvas/canvas-strokeRect-alpha-shadow.html [ Skip ] crbug.com/757165 [ Win ] virtual/gpu/fast/canvas/image-object-in-canvas.html [ Skip ] +# We cannot yet launch Canvas2D staying GPU on readback +crbug.com/1288118 fast/canvas/bug382588.html [ Skip ] +crbug.com/1288118 fast/canvas/canvas-gpu-consistency.html [ Skip ] + # Antialiasing error crbug.com/845973 virtual/display-compositor-pixel-dump/fast/canvas/display-compositor-pixel-dump/OffscreenCanvas-opaque-background-compositing.html [ Failure Pass ] -# Some Windows 7 vm images have a timezone-related registry not populated -# leading this test to fail. -# https://chromium-review.googlesource.com/c/chromium/src/+/1379250/6 -crbug.com/856119 [ Win7 ] fast/js/regress/resolved-timezone-defined.html [ Failure Pass ] - # Tests occasionaly timing out (flaky) on WebKit Win7 dbg builder crbug.com/757955 http/tests/devtools/tracing/timeline-paint/layer-tree.js [ Failure Pass Timeout ] @@ -4800,18 +4399,12 @@ crbug.com/773122 [ Win7 ] virtual/text-antialias/international/unicode-bidi-plaintext-in-textarea.html [ Failure Pass ] crbug.com/773122 [ Win7 ] virtual/text-antialias/whitespace/022.html [ Failure Pass ] -# Sheriff failures 2017-10-13 -crbug.com/774463 [ Debug Win7 ] fast/events/autoscroll-should-not-stop-on-keypress.html [ Failure Pass ] - # Sheriff failures 2017-10-23 crbug.com/772411 http/tests/media/autoplay-crossorigin.html [ Failure Pass Timeout ] # Sheriff failures 2017-10-24 crbug.com/773122 crbug.com/777813 [ Win ] virtual/text-antialias/font-ascent-mac.html [ Failure Pass ] -# Cookie Store API -crbug.com/827231 [ Win ] external/wpt/cookie-store/change_eventhandler_for_document_cookie.tentative.https.window.html [ Failure Pass Timeout ] - # The "Lax+POST" or lax-allowing-unsafe intervention for SameSite-by-default # cookies causes POST tests to fail. crbug.com/990439 external/wpt/cookies/samesite/form-post-blank.https.html [ Failure ] @@ -4915,13 +4508,6 @@ crbug.com/1067477 [ Fuchsia ] fast/media/matchmedium-query-api.html [ Skip ] crbug.com/1067477 [ Fuchsia ] virtual/threaded/synthetic_gestures/synthetic-pinch-zoom-gesture-touchscreen.html [ Skip ] -# These tests are flaky when using Scenic ozone platform. -crbug.com/1047480 [ Fuchsia ] css3/calc/reflection-computed-style.html [ Failure Pass ] -crbug.com/1047480 [ Fuchsia ] external/wpt/web-animations/interfaces/Animation/ready.html [ Failure Pass ] -crbug.com/1047480 [ Fuchsia ] fast/block/float/floats-with-margin-should-not-wrap.html [ Failure Pass ] -crbug.com/1047480 [ Fuchsia ] fast/block/margin-collapse/clear-nested-float-more-than-one-previous-sibling-away.html [ Failure Pass ] -crbug.com/1047480 [ Fuchsia ] virtual/gpu-rasterization/images/drag-image-descendant-painting-sibling.html [ Failure Pass ] - ### See crbug.com/891427 comment near the top of this file: ###crbug.com/816914 [ Mac ] fast/canvas/canvas-drawImage-live-video.html [ Failure Pass ] crbug.com/817167 http/tests/devtools/oopif/oopif-cookies-refresh.js [ Failure Pass Timeout ] @@ -4976,11 +4562,6 @@ # Sheriff 2018-05-31 crbug.com/848398 http/tests/devtools/oopif/oopif-performance-cpu-profiles.js [ Failure Pass Timeout ] -# Flakes 2018-06-02 -crbug.com/841567 fast/scrolling/scrollbar-tickmarks-hittest.html [ Failure Pass ] - -# Flakes 2018-06-04 - # Sheriff 2018-06-07 crbug.com/850358 http/tests/devtools/editor/text-editor-enter-behaviour.js [ Failure Pass Timeout ] crbug.com/849978 http/tests/devtools/elements/styles-4/stylesheet-source-url-comment.js [ Failure Pass Timeout ] @@ -4990,19 +4571,14 @@ # User Activation crbug.com/1066190 external/wpt/html/user-activation/navigation-state-reset-crossorigin.sub.tentative.html [ Failure Timeout ] -# Sheriff 2018-07-05 -crbug.com/861682 [ Win ] external/wpt/css/mediaqueries/device-aspect-ratio-003.html [ Failure Pass ] - # S13N Sheriff 2018-7-11 crbug.com/862643 http/tests/serviceworker/navigation_preload/use-counter.html [ Failure Pass ] # Sheriff 2018-07-30 -crbug.com/868706 external/wpt/css/css-layout-api/auto-block-size-inflow.https.html [ Failure Pass ] crbug.com/873873 external/wpt/service-workers/service-worker/fetch-canvas-tainting-video.https.html [ Pass Timeout ] crbug.com/873873 external/wpt/service-workers/service-worker/fetch-canvas-tainting-video-cache.https.html [ Pass Timeout ] -crbug.com/875884 [ Linux ] lifecycle/background-change-lifecycle-count.html [ Failure Pass ] crbug.com/875884 [ Win ] lifecycle/background-change-lifecycle-count.html [ Failure Pass ] # Sheriff 2018-08-20 @@ -5037,21 +4613,9 @@ # Sheriff 2018-10-15 crbug.com/895257 [ Mac ] external/wpt/css/css-fonts/variations/at-font-face-font-matching.html [ Failure Pass ] -#Sheriff 2018-10-23 -crbug.com/898378 [ Mac10.13 ] fast/scroll-behavior/smooth-scroll/keyboard-scroll.html [ Timeout ] - -# Sheriff 2018-10-29 -crbug.com/766357 [ Win ] virtual/threaded-prefer-compositing/fast/scrolling/wheel-and-touch-scroll-use-count.html [ Failure Pass ] - # Test is flaky under load crbug.com/904389 http/tests/preload/delaying_onload_link_preload_after_discovery.html [ Failure Pass ] -# Flaky crash due to "bad mojo message". -crbug.com/906952 editing/pasteboard/file-drag-to-editable.html [ Crash Pass ] - -#Sheriff 2018-11-22 -crbug.com/907862 [ Mac10.13 ] gamepad/multiple-event-listeners.html [ Failure Pass ] - # Sheriff 2018-11-26 crbug.com/908347 media/autoplay/webaudio-audio-context-resume.html [ Failure Pass ] @@ -5103,10 +4667,7 @@ crbug.com/922951 http/tests/webaudio/autoplay-crossorigin.html [ Crash Failure Pass Timeout ] crbug.com/922951 media/controls/overflow-menu-hide-on-click-outside-stoppropagation.html [ Crash Failure Pass Timeout ] crbug.com/922951 virtual/prefer_compositing_to_lcd_text/scrollbars/resize-scales-with-dpi-150.html [ Crash Failure Pass Timeout ] -crbug.com/922951 [ Linux ] virtual/scalefactor150/fast/events/synthetic-events/tap-on-scaled-screen.html [ Crash Failure Pass Timeout ] -crbug.com/922951 [ Win ] virtual/scalefactor150/fast/events/synthetic-events/tap-on-scaled-screen.html [ Crash Failure Pass Timeout ] crbug.com/922951 virtual/threaded/http/tests/devtools/tracing/frame-model-instrumentation.js [ Crash Failure Pass Timeout ] -crbug.com/922951 virtual/threaded/http/tests/devtools/tracing/timeline-layout/timeline-layout-reason.js [ Crash Failure Pass Timeout ] crbug.com/922951 virtual/threaded/http/tests/devtools/tracing/timeline-misc/timeline-record-reload.js [ Crash Failure Pass Timeout ] crbug.com/922951 virtual/threaded/http/tests/devtools/tracing/timeline-layout/timeline-layout-with-invalidations.js [ Crash Failure Pass Timeout ] @@ -5129,9 +4690,6 @@ # Recently became flaky on multiple platforms (Linux and Windows primarily) crbug.com/927769 fast/webgl/OffscreenCanvas-webgl-preserveDrawingBuffer.html [ Skip ] -# Flaky test. -crbug.com/1084378 external/wpt/webvtt/rendering/cues-with-video/processing-model/dom_override_remove_cue_while_paused.html [ Failure Pass ] - # Sheriff 2019-02-12 crbug.com/1072768 media/video-played-ranges-1.html [ Failure Pass Timeout ] @@ -5150,9 +4708,6 @@ crbug.com/934636 http/tests/security/cross-origin-indexeddb-allowed.html [ Crash Pass ] crbug.com/934818 http/tests/devtools/tracing/decode-resize.js [ Failure Pass ] -# Sheriff 2019-02-26 -crbug.com/936165 media/autoplay-muted.html [ Pass Timeout ] - # Sheriff 2019-02-28 crbug.com/936827 external/wpt/fullscreen/api/element-request-fullscreen-and-remove-manual.html [ Failure Pass ] @@ -5193,17 +4748,10 @@ # Tests using testRunner.useUnfortunateSynchronousResizeMode occasionally timeout, # but the test coverage is still good. -crbug.com/919789 css3/viewport-percentage-lengths/viewport-percentage-lengths-resize.html [ Pass Timeout ] -crbug.com/919789 compositing/transitions/transform-on-large-layer-expected.html [ Pass Timeout ] -crbug.com/919789 fast/autoresize/turn-off-autoresize.html [ Pass Timeout ] -crbug.com/919789 fast/autoresize/basic.html [ Pass Timeout ] crbug.com/919789 fast/dom/viewport/resize-event-fired-window-resized.html [ Pass Timeout ] crbug.com/919789 fast/dom/Window/window-resize-contents.html [ Pass Timeout ] -crbug.com/919789 fast/events/resize-events-count.html [ Pass Timeout ] -crbug.com/919789 virtual/text-antialias/line-break-between-text-nodes-with-inline-blocks.html [ Pass Timeout ] crbug.com/919789 media/controls/overflow-menu-hide-on-resize.html [ Pass Timeout ] crbug.com/919789 [ Linux ] paint/invalidation/resize-iframe-text.html [ Pass Timeout ] -crbug.com/919789 [ Mac10.13 ] paint/invalidation/resize-iframe-text.html [ Pass Timeout ] crbug.com/919789 paint/invalidation/scroll/scrollbar-damage-and-full-viewport-repaint.html [ Pass Timeout ] crbug.com/919789 paint/invalidation/window-resize/* [ Pass Timeout ] @@ -5211,16 +4759,9 @@ crbug.com/1130876 fast/dynamic/window-resize-scrollbars-test.html [ Failure Pass ] # Sheriff 2019-03-28 -crbug.com/946890 external/wpt/html/semantics/embedded-content/media-elements/location-of-the-media-resource/currentSrc.html [ Crash Failure Pass ] crbug.com/946711 http/tests/devtools/editor/text-editor-search-switch-editor.js [ Failure Pass ] crbug.com/946712 [ Release ] http/tests/devtools/elements/styles-2/paste-property.js [ Crash Pass Timeout ] -### external/wpt/fetch/sec-metadata/ -crbug.com/947023 external/wpt/fetch/sec-metadata/font.tentative.https.sub.html [ Failure Pass ] - -# Sheriff 2019-04-02 -crbug.com/947690 [ Debug ] http/tests/history/back-during-beforeunload.html [ Failure Pass ] - # Sheriff 2019-04-09 crbug.com/946335 [ Linux ] fast/filesystem/file-writer-abort-depth.html [ Crash Pass ] crbug.com/946335 [ Mac ] fast/filesystem/file-writer-abort-depth.html [ Crash Pass ] @@ -5237,20 +4778,12 @@ # Sheriff 2019-04-30 crbug.com/948785 fast/events/pointerevents/pointer-event-consumed-touchstart-in-slop-region.html [ Skip ] -# Sheriff 2019-05-01 -crbug.com/958347 [ Linux ] external/wpt/editing/run/removeformat.html [ Crash Pass ] - # This test might need to be removed. crbug.com/954349 fast/forms/autofocus-in-sandbox-with-allow-scripts.html [ Timeout ] -# Sheriff 2019-05-11 -crbug.com/962139 [ Debug Linux ] external/wpt/html/infrastructure/urls/dynamic-changes-to-base-urls/dynamic-urls.sub.html [ Crash Pass ] -crbug.com/962139 [ Debug Linux ] external/wpt/html/infrastructure/urls/dynamic-changes-to-base-urls/historical.sub.xhtml [ Crash Pass ] - # Sheriff 2019-05-13 crbug.com/865432 [ Linux ] external/wpt/workers/modules/dedicated-worker-import-blob-url.any.worker.html [ Pass Timeout ] crbug.com/867532 [ Linux ] external/wpt/workers/modules/dedicated-worker-import-data-url.any.worker.html [ Pass Timeout ] -crbug.com/867532 [ Linux ] external/wpt/workers/modules/dedicated-worker-import.any.worker.html [ Pass Timeout ] # Sheriff 2020-05-18 crbug.com/988248 media/track/track-cue-rendering-position-auto.html [ Failure Pass ] @@ -5297,7 +4830,6 @@ crbug.com/985232 [ Win7 ] external/wpt/html/semantics/scripting-1/the-script-element/module/dynamic-import/dynamic-imports-credentials.sub.html [ Failure Pass ] # Sheriff 2019-07-26 -crbug.com/874866 [ Debug Linux ] media/controls/doubletap-to-jump-backwards.html [ Failure ] crbug.com/988246 external/wpt/cookie-store/serviceworker_cookiechange_eventhandler_mismatched_subscription.tentative.https.any.serviceworker.html [ Skip ] crbug.com/959129 http/tests/devtools/tracing/timeline-script-parse.js [ Failure Pass ] @@ -5321,9 +4853,6 @@ crbug.com/979422 [ Mac ] fast/borders/border-radius-mask-canvas-with-mask.html [ Failure ] crbug.com/979422 [ Mac ] fast/borders/border-radius-mask-canvas-border.html [ Failure ] -# Sheriff 2019-08-01 -crbug.com/989717 [ Fuchsia ] http/tests/preload/avoid_delaying_onload_link_preload.html [ Failure Pass ] - # Expected failures for forced colors mode tests when the corresponding flags # are not enabled. crbug.com/970285 external/wpt/forced-colors-mode/* [ Failure ] @@ -5356,27 +4885,18 @@ # Sheriff 2019-09-09 crbug.com/1001817 external/wpt/css/css-ui/text-overflow-016.html [ Failure Pass ] -# Sheriff 2019-09-10 -crbug.com/1002527 [ Debug ] virtual/text-antialias/large-text-composed-char.html [ Crash Pass ] - # Tests fail because of missing scroll snap for #target and bugs in scrollIntoView crbug.com/1003055 external/wpt/css/css-scroll-snap/scroll-target-align-001.html [ Failure ] crbug.com/1003055 external/wpt/css/css-scroll-snap/scroll-target-align-002.html [ Failure ] crbug.com/1003055 external/wpt/css/css-scroll-snap/scroll-target-snap-001.html [ Failure ] crbug.com/1003055 external/wpt/css/css-scroll-snap/scroll-target-snap-002.html [ Failure ] -# Sheriff 2019-09-20 -crbug.com/1005128 crypto/subtle/abandon-crypto-operation2.html [ Crash Pass ] - # Sheriff 2019-09-30 crbug.com/1003715 [ Win10.20h2 ] http/tests/notifications/serviceworker-notification-properties.html [ Failure Pass Timeout ] # Sheriff 2019-10-01 crbug.com/1010032 [ Win7 ] virtual/text-antialias/fallback-traits-fixup.html [ Failure ] -crbug.com/1010032 [ Win7 ] virtual/text-antialias/international/bold-bengali.html [ Failure ] -crbug.com/1010032 [ Win7 ] virtual/text-antialias/selection/khmer-selection.html [ Failure ] -crbug.com/1010032 [ Win7 ] fast/writing-mode/Kusa-Makura-background-canvas.html [ Failure ] # Sheriff 2019-10-02 crbug.com/1010483 [ Win ] fast/parser/residual-style-dom.html [ Crash Pass ] @@ -5445,10 +4965,6 @@ # Temporary suppression to allow devtools-frontend changes crbug.com/1041830 http/tests/devtools/tracing/timeline-js/timeline-js-line-level-profile.js [ Failure Pass ] -# Sheriff 2019-12-13 -crbug.com/1032451 [ Win7 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/idlharness.https.window.html [ Failure Pass ] -crbug.com/1033852 [ Win7 ] virtual/plz-dedicated-worker/external/wpt/fetch/api/idlharness.any.sharedworker.html [ Failure ] - # Sheriff 2019-12-16 crbug.com/1034374 http/tests/devtools/tracing/timeline-worker-events.js [ Failure Pass ] crbug.com/1034513 [ Win7 ] virtual/stable/fast/dom/Window/window-resize-contents.html [ Failure Pass ] @@ -5491,9 +5007,6 @@ crbug.com/1043675 [ Win ] external/wpt/css/filter-effects/css-filters-animation-opacity.html [ Failure ] crbug.com/1043675 [ Win ] svg/custom/svg-root-with-opacity.html [ Failure ] -crbug.com/989665 [ Mac ] external/wpt/resource-timing/resource_timing_buffer_full_eventually.html [ Crash Pass ] -crbug.com/989665 [ Linux ] virtual/plz-dedicated-worker/external/wpt/resource-timing/resource_timing_buffer_full_eventually.html [ Crash Pass ] - # Sheriff 2020-01-23 crbug.com/1046784 http/tests/inspector-protocol/service-worker/target-reloaded-after-crash.js [ Failure Pass Timeout ] @@ -5523,14 +5036,11 @@ crbug.com/1048149 external/wpt/html/browsers/the-window-object/open-close/open-features-non-integer-innerwidth.html [ Crash Timeout ] crbug.com/1048149 external/wpt/html/browsers/the-window-object/open-close/open-features-non-integer-screeny.html [ Crash Timeout ] crbug.com/1048149 external/wpt/html/browsers/the-window-object/open-close/open-features-non-integer-width.html [ Crash Timeout ] -crbug.com/1048149 [ Mac ] http/tests/inspector-protocol/emulation/emulation-oopifs.js [ Crash ] crbug.com/1048149 [ Mac ] fast/forms/calendar-picker/calendar-picker-appearance.html [ Crash Pass ] -crbug.com/1048149 [ Mac ] fast/forms/calendar-picker/calendar-picker-touch-operations.html [ Crash Pass ] crbug.com/1048149 [ Mac ] fast/forms/calendar-picker/month-picker-appearance.html [ Crash Pass ] crbug.com/1048149 [ Mac ] fast/forms/calendar-picker/month-picker-appearance-step.html [ Crash Pass ] crbug.com/1048149 [ Mac ] fast/forms/color/color-picker-appearance-zoom125.html [ Crash Pass ] crbug.com/1048149 [ Mac ] fast/forms/color/color-picker-top-left-selection-position-after-reopen.html [ Crash Pass ] -crbug.com/1048149 [ Mac ] fast/forms/color/color-picker-zoom150-bottom-edge-no-nan.html [ Crash Pass ] crbug.com/1048149 crbug.com/1050121 [ Mac ] fast/forms/month/month-picker-appearance-zoom150.html [ Crash Failure Pass ] # SwANGLE issues @@ -5595,10 +5105,6 @@ crbug.com/1253630 [ Win ] virtual/scroll-unification-overlay-scrollbar/plugin-overlay-scrollbar-mouse-capture.html [ Failure Pass ] crbug.com/1098383 [ Mac ] fast/events/scrollbar-double-click.html [ Failure Pass ] -# Sheriff 2020-02-07 - -crbug.com/1050039 [ Mac ] fast/events/onbeforeunload-focused-iframe.html [ Failure Pass ] - # DevTools roll crbug.com/1006759 http/tests/devtools/elements/styles-1/edit-value-url-with-color.js [ Skip ] @@ -5647,8 +5153,6 @@ crbug.com/1057822 http/tests/misc/synthetic-gesture-initiated-in-cross-origin-frame.html [ Crash Failure Pass ] crbug.com/1131977 [ Mac ] http/tests/misc/hover-state-recomputed-on-main-frame.html [ Timeout ] -crbug.com/1057351 virtual/threaded-no-composited-antialiasing/animations/responsive/interpolation/offset-rotate-responsive.html [ Failure Pass ] -crbug.com/1057351 virtual/threaded-no-composited-antialiasing/animations/stability/empty-keyframes.html [ Failure Pass ] ### sheriff 2020-03-03 crbug.com/1058073 [ Mac ] http/tests/devtools/service-workers/sw-navigate-useragent.js [ Failure Pass ] @@ -5696,8 +5200,6 @@ crbug.com/1249043 external/wpt/html/cross-origin-embedder-policy/reporting-subresource-corp.https.html [ Pass Timeout ] crbug.com/1249043 external/wpt/html/cross-origin-embedder-policy/reporting-navigation.https.html [ Failure Pass ] crbug.com/1249043 external/wpt/html/cross-origin-embedder-policy/reporting-to-endpoint.https.html [ Failure Pass ] -crbug.com/1249043 external/wpt/html/cross-origin-embedder-policy/reporting-to-frame-owner.html [ Failure Pass ] -crbug.com/1249043 external/wpt/html/cross-origin-embedder-policy/reporting-to-worker-owner.html [ Failure Pass ] crbug.com/1249043 external/wpt/html/cross-origin-embedder-policy/report-only-require-corp.https.html [ Failure Pass ] crbug.com/1287036 external/wpt/html/cross-origin-opener-policy/iframe-popup-same-origin-to-same-origin.https.html [ Skip Timeout ] crbug.com/1287036 [ Win10.20h2 ] external/wpt/html/cross-origin-embedder-policy/cross-origin-isolated-permission.https.html [ Timeout ] @@ -5722,9 +5224,6 @@ crbug.com/1317071 [ Mac10.12 ] virtual/no-auto-wpt-origin-isolation/external/wpt/html/browsers/origin/origin-keyed-agent-clusters/2-iframes/parent-yes-child1-yes-subdomain-child2-yes-subdomain.sub.https.html [ Timeout ] crbug.com/1317071 [ Mac10.12 ] virtual/no-auto-wpt-origin-isolation/external/wpt/html/browsers/origin/origin-keyed-agent-clusters/document-domain.sub.https.html [ Timeout ] -# Sheriff 2020-03-05 -crbug.com/1058073 [ Mac10.14 ] accessibility/content-changed-notification-causes-crash.html [ Failure Pass ] - # Sheriff 2020-03-06 crbug.com/1059262 virtual/threaded/http/tests/worklet/webexposed/global-interface-listing-paint-worklet.html [ Failure Pass ] crbug.com/1059262 [ Mac ] webexposed/global-interface-listing-platform-specific.html [ Failure Pass ] @@ -5733,11 +5232,6 @@ # Sheriff 2020-03-08 crbug.com/1059645 external/wpt/pointerevents/pointerevent_coalesced_events_attributes.html [ Failure Pass ] -# Sheriff 2020-03-13 -crbug.com/1061131 [ Mac ] editing/selection/replaced-boundaries-1.html [ Failure Pass ] - -crbug.com/1058888 [ Linux ] animations/animationworklet/peek-updated-composited-property-on-main.html [ Failure Pass ] - # [virtual/...]external/wpt/web-animation test flakes crbug.com/1064065 virtual/threaded/external/wpt/css/css-animations/event-dispatch.tentative.html [ Failure Pass ] @@ -5755,12 +5249,6 @@ # Stale revalidation shouldn't be blocked: crbug.com/1079188 external/wpt/fetch/stale-while-revalidate/revalidate-not-blocked-by-csp.html [ Timeout ] -# Sheriff 2020-04-22 -# Flaky test. -crbug.com/1073505 [ Mac10.13 ] external/wpt/html/semantics/scripting-1/the-script-element/moving-between-documents/* [ Failure Pass ] -crbug.com/1073505 [ Mac10.13 ] external/wpt/html/semantics/scripting-1/the-script-element/moving-between-documents/before-prepare-iframe-success-external-module.html [ Failure Pass ] -crbug.com/1073505 [ Mac10.13 ] external/wpt/html/semantics/scripting-1/the-script-element/moving-between-documents/before-prepare-iframe-fetch-error-external-module.html [ Failure Pass ] - # the inspector-protocol/media tests only work in the virtual test environment. crbug.com/1074129 inspector-protocol/media/media-player.js [ Timeout ] @@ -5776,12 +5264,8 @@ crbug.com/v8/11992 external/wpt/wasm/jsapi/exception/* [ Skip ] crbug.com/v8/11992 external/wpt/wasm/jsapi/tag/* [ Skip ] -crbug.com/1080609 virtual/threaded/external/wpt/scroll-animations/element-based-offset.html [ Failure Pass ] -crbug.com/1080609 virtual/threaded/external/wpt/scroll-animations/element-based-offset-clamp.html [ Failure Pass ] - # Assorted virtual/threaded/.../wpt/scroll-animations tests crbug.com/1279648 [ Mac ] virtual/threaded/external/wpt/scroll-animations/css/at-scroll-timeline-default-descriptors-iframe.html [ Failure ] -crbug.com/1279648 [ Mac10.15 ] virtual/threaded/external/wpt/scroll-animations/scroll-timelines/current-time-nan.html [ Timeout ] crbug.com/1279648 virtual/threaded/external/wpt/scroll-animations/css/at-scroll-timeline-default-descriptors-quirks-mode.html [ Failure ] crbug.com/1279648 virtual/threaded/external/wpt/scroll-animations/css/at-scroll-timeline-default-descriptors-writing-mode-rl.html [ Failure ] crbug.com/1279648 virtual/threaded/external/wpt/scroll-animations/css/at-scroll-timeline-default-descriptors.html [ Failure ] @@ -5849,17 +5333,13 @@ crbug.com/1083302 media/controls/volumechange-muted-attribute.html [ Failure Pass ] # Sheriff 2020-07-10 -crbug.com/1104135 [ Mac10.14 ] virtual/controls-refresh-hc/fast/forms/color-scheme/range/range-pressed-state.html [ Failure Pass ] crbug.com/1102167 external/wpt/fetch/redirect-navigate/preserve-fragment.html [ Pass Timeout ] # Sheriff 2020-07-13 -crbug.com/1104910 [ Mac ] external/wpt/webaudio/the-audio-api/the-oscillatornode-interface/osc-basic-waveform.html [ Failure Pass ] crbug.com/1104910 fast/peerconnection/RTCPeerConnection-reload-interesting-usage.html [ Failure Pass ] crbug.com/1104910 [ Mac ] editing/selection/selection-background.html [ Failure Pass ] -crbug.com/1104910 [ Linux ] external/wpt/referrer-policy/gen/worker-module.http-rp/unsafe-url/worker-classic.http.html [ Failure Pass ] -crbug.com/1104910 [ Linux ] external/wpt/referrer-policy/gen/worker-module.http-rp/unset/worker-module.http.html [ Failure Pass ] # Sheriff 2020-07-14 @@ -5910,16 +5390,11 @@ # Sheriff 2020-0-21 crbug.com/1120330 virtual/threaded/external/wpt/feature-policy/experimental-features/vertical-scroll-disabled-scrollbar-tentative.html [ Failure Pass ] -crbug.com/1120330 virtual/threaded/external/wpt/permissions-policy/experimental-features/vertical-scroll-disabled-scrollbar-tentative.html [ Failure Pass ] crbug.com/1122582 external/wpt/html/cross-origin-opener-policy/coop-csp-sandbox-navigate.https.html [ Failure Pass ] # Sheriff 2020-09-09 crbug.com/1126709 [ Mac ] virtual/threaded/external/wpt/animation-worklet/worklet-animation-local-time-null-1.https.html [ Failure Pass ] -crbug.com/1126709 [ Win ] virtual/threaded/external/wpt/animation-worklet/worklet-animation-local-time-null-1.https.html [ Failure Pass ] - -# Sheriff 2020-09-21 -crbug.com/1130500 [ Debug Mac10.13 ] virtual/plz-dedicated-worker/external/wpt/xhr/xhr-timeout-longtask.any.worker.html [ Failure Pass ] # Sheriff 2020-09-22 crbug.com/1130533 [ Mac ] external/wpt/xhr/xhr-timeout-longtask.any.html [ Failure Pass ] @@ -5957,10 +5432,6 @@ # Sheriff 2020-10-09 crbug.com/1136687 external/wpt/pointerevents/pointerlock/pointerevent_pointerlock_supercedes_capture.html [ Failure Pass ] -crbug.com/1136726 [ Linux ] virtual/gpu-rasterization/images/imagemap-focus-ring-outline-color-not-inherited-from-map.html [ Failure ] - -# Sheriff 2020-10-14 -crbug.com/1138591 [ Mac10.15 ] http/tests/dom/raf-throttling-out-of-view-cross-origin-page.html [ Failure ] # WebRTC: Payload demuxing times out in Plan B. This is expected. crbug.com/1139052 virtual/webrtc-wpt-plan-b/external/wpt/webrtc/protocol/rtp-demuxing.html [ Skip Timeout ] @@ -5993,13 +5464,6 @@ # Sheriff 2020-11-06 crbug.com/1146560 [ Mac ] fast/canvas/color-space/canvas-createImageBitmap-e_srgb.html [ Failure Pass ] -# Sheriff 2020-11-12 -crbug.com/1148259 [ Mac ] external/wpt/html/browsers/browsing-the-web/navigating-across-documents/javascript-url-return-value-handling-dynamic.html [ Failure ] - -# Sheriff 2020-11-19 -crbug.com/1150700 [ Win ] virtual/plz-dedicated-worker/external/wpt/service-workers/service-worker/registration-updateviacache.https.html [ Failure Pass Timeout ] -crbug.com/1150700 [ Win ] virtual/plz-dedicated-worker/external/wpt/service-workers/service-worker/update-bytecheck-cors-import.https.html [ Pass Timeout ] - # Sheriff 2020-11-16 crbug.com/1149734 http/tests/devtools/sources/debugger-ui/debugger-inline-values-frames.js [ Failure Pass Timeout ] crbug.com/1149734 http/tests/devtools/sources/debugger-ui/reveal-execution-line.js [ Failure Pass Timeout ] @@ -6008,7 +5472,6 @@ crbug.com/1150475 fast/dom/open-and-close-by-DOM.html [ Failure Pass ] #Sheriff 2020-11-23 -crbug.com/1152088 [ Debug Mac10.13 ] fast/dom/cssTarget-crash.html [ Pass Timeout ] # Sheriff 2021-01-22 added Timeout per crbug.com/1046784: crbug.com/1149734 http/tests/devtools/sources/source-frame-toolbar-items.js [ Failure Pass Timeout ] crbug.com/1149734 http/tests/devtools/sources/debugger-frameworks/frameworks-sourcemap.js [ Failure Pass ] @@ -6019,7 +5482,6 @@ crbug.com/1087242 crbug.com/1271141 http/tests/inspector-protocol/service-worker/network-extrainfo-main-request.js [ Pass Timeout ] crbug.com/1149771 [ Linux ] virtual/android/fullscreen/video-scrolled-iframe.html [ Failure Pass Timeout ] crbug.com/1152532 http/tests/devtools/service-workers/user-agent-override.js [ Pass Timeout ] -crbug.com/1134459 accessibility/aom-click-action.html [ Pass Timeout ] #Sheriff 2020-11-26 crbug.com/1032451 virtual/threaded-no-composited-antialiasing/animations/stability/animation-iteration-event-destroy-renderer.html [ Pass Timeout ] @@ -6090,22 +5552,12 @@ # Sheriff 2021-01-27 crbug.com/1171331 [ Mac ] tables/mozilla_expected_failures/bugs/bug89315.html [ Failure Pass ] -crbug.com/1168785 [ Mac ] virtual/threaded-prefer-compositing/fast/scrolling/autoscroll-latch-clicked-node-if-parent-unscrollable.html [ Timeout ] - # flaky test crbug.com/1173956 http/tests/xsl/xslt-transform-with-javascript-disabled.html [ Failure Pass ] -# MediaQueryList tests failing due to incorrect event dispatching. These tests -# will pass because they have -expected.txt, but keep entries here because they -# still need to get fixed. -external/wpt/css/cssom-view/MediaQueryList-addListener-handleEvent-expected.txt [ Failure Pass ] -external/wpt/css/cssom-view/MediaQueryList-extends-EventTarget-interop-expected.txt [ Failure Pass ] - # No support for key combinations like Alt + c in testdriver.Actions for content_shell crbug.com/893480 external/wpt/uievents/interface/keyboard-accesskey-click-event.html [ Timeout ] -# Timing out on Fuchsia -crbug.com/1171283 [ Fuchsia ] virtual/threaded/synthetic_gestures/synthetic-pinch-zoom-gesture-touchscreen-zoom-out-slow.html [ Pass Timeout ] # Sheriff 2021-02-11 crbug.com/1177573 http/tests/inspector-protocol/animation/animation-pause.js [ Failure Pass ] @@ -6178,9 +5630,6 @@ crbug.com/1190905 [ Linux ] http/tests/devtools/indexeddb/live-update-indexeddb-list.js [ Failure Pass ] crbug.com/1190905 [ Win ] http/tests/devtools/indexeddb/live-update-indexeddb-list.js [ Failure Pass ] -# Sheriff 2021-03-23 -crbug.com/1182689 [ Mac ] external/wpt/editing/run/delete.html?6001-last [ Failure ] - # Sheriff 2021-03-31 # Failing tests because of enabling scroll unification flag crbug.com/1194446 virtual/scroll-unification/fast/events/platform-wheelevent-paging-x-in-scrolling-div.html [ Crash Failure Pass Timeout ] @@ -6200,7 +5649,6 @@ crbug.com/476553 virtual/scroll-unification/fast/scroll-snap/animate-fling-to-snap-points-1.html [ Failure Pass ] # Sheriff 2021-04-01 -crbug.com/1167679 accessibility/aom-focus-action.html [ Crash Failure Pass Timeout ] # More failing tests because of enabling scroll unification flag crbug.com/476553 virtual/scroll-unification/fast/events/touch/gesture/gesture-tap-active-state-hidden-iframe.html [ Crash Failure Pass Timeout ] crbug.com/476553 virtual/scroll-unification/fast/events/autoscroll-should-not-stop-on-keypress.html [ Crash Failure Pass Timeout ] @@ -6243,8 +5691,6 @@ crbug.com/1195295 fast/events/touch/multi-touch-timestamp.html [ Failure Pass ] -crbug.com/1197296 [ Mac10.15 ] external/wpt/feature-policy/feature-policy-frame-policy-timing.https.sub.html [ Failure Pass ] - crbug.com/1196745 [ Mac10.15 ] editing/selection/editable-links.html [ Skip ] # Is fixed by PlzDedicatedWorker. @@ -6267,7 +5713,6 @@ crbug.com/1198698 external/wpt/clear-site-data/storage.https.html [ Pass Timeout ] # Sheriff 2021-04-14 -crbug.com/1198828 [ Win ] virtual/scroll-unification/fast/events/mouse-events-on-node-deletion.html [ Failure Pass ] crbug.com/1198828 [ Linux ] virtual/scroll-unification/fast/events/mouse-events-on-node-deletion.html [ Failure Pass ] # Sheriff 2021-04-15 @@ -6277,10 +5722,8 @@ crbug.com/1199528 http/tests/inspector-protocol/css/css-edit-redirected-css.js [ Failure Pass ] crbug.com/1196317 [ Mac ] scrollbars/custom-scrollbar-thumb-width-changed-on-inactive-pseudo.html [ Failure Pass ] -crbug.com/1197444 virtual/scroll-unification-prefer_compositing_to_lcd_text/scrollbars/nested-scroll-overlay-scrollbar.html [ Crash Failure Pass ] # Sheriff 2021-04-21 crbug.com/1201225 external/wpt/pointerevents/pointerlock/pointerevent_pointerrawupdate_in_pointerlock.html [ Failure Pass Timeout ] -crbug.com/1198232 [ Win ] virtual/scroll-unification/fast/events/mouseenter-mouseleave-on-drag.html [ Failure Pass ] crbug.com/1201346 http/tests/origin_trials/webexposed/bfcache-experiment-http-header-origin-trial.php [ Failure Pass ] crbug.com/1201365 virtual/portals/http/tests/inspector-protocol/portals/device-emulation-portals.js [ Pass Timeout ] @@ -6299,19 +5742,7 @@ crbug.com/1202722 [ Linux ] virtual/scroll-unification/fast/events/mouseenter-mouseleave-on-drag.html [ Failure Pass Timeout ] # Sheriff 2021-04-29 -crbug.com/1203963 [ Mac10.14 ] external/wpt/css/css-paint-api/idlharness.html [ Failure Pass Timeout ] -crbug.com/1203963 [ Mac10.14 ] external/wpt/css/css-shapes/parsing/shape-outside-computed.html [ Failure Pass Timeout ] -crbug.com/1203963 [ Mac10.14 ] external/wpt/css/cssom-view/idlharness.html [ Failure Pass Timeout ] -crbug.com/1203963 [ Mac10.14 ] external/wpt/fetch/api/idlharness.any.sharedworker.html [ Failure Pass Timeout ] -crbug.com/1203963 [ Mac10.14 ] external/wpt/gamepad/idlharness.https.window.html [ Failure Pass Timeout ] -crbug.com/1203963 [ Mac10.14 ] external/wpt/input-device-capabilities/idlharness.window.html [ Failure Pass Timeout ] -crbug.com/1203963 [ Mac10.14 ] external/wpt/periodic-background-sync/idlharness.https.any.html [ Failure Pass Timeout ] -crbug.com/1203963 [ Mac10.14 ] external/wpt/storage/idlharness.https.any.html [ Failure Pass Timeout ] -crbug.com/1203963 [ Mac10.14 ] external/wpt/storage/idlharness.https.any.worker.html [ Failure Pass Timeout ] crbug.com/1203963 [ Mac10.14 ] external/wpt/webusb/idlharness.https.any.html [ Failure Pass Timeout ] -crbug.com/1203963 [ Mac10.14 ] external/wpt/xhr/idlharness.any.sharedworker.html [ Failure Pass Timeout ] -crbug.com/1198443 [ Mac10.14 ] virtual/plz-dedicated-worker/external/wpt/fetch/api/basic/request-upload.any.html [ Failure Pass Timeout ] -crbug.com/1198443 [ Mac10.14 ] virtual/plz-dedicated-worker/external/wpt/fetch/api/basic/request-upload.any.worker.html [ Failure Pass Timeout ] # Sheriff 2021-04-30 crbug.com/1204498 [ Linux ] virtual/scroll-unification/fast/events/hit-test-cache-iframes.html [ Failure Pass ] @@ -6329,28 +5760,15 @@ # Sheriff 2021-05-04 crbug.com/1205659 [ Mac ] external/wpt/IndexedDB/key-generators/reading-autoincrement-indexes.any.worker.html [ Pass Timeout ] -crbug.com/1205659 [ Mac ] storage/indexeddb/empty-blob-file.html [ Pass Timeout ] crbug.com/1205673 [ Linux ] virtual/threaded-prefer-compositing/fast/scroll-snap/snaps-after-wheel-scrolling-single-tick.html [ Failure Pass ] -# Sheriff 2021-05-05 -crbug.com/1205796 [ Mac10.12 ] external/wpt/html/dom/idlharness.https.html?include=HTML.* [ Failure ] -crbug.com/1205796 [ Mac10.14 ] external/wpt/html/dom/idlharness.https.html?include=HTML.* [ Failure ] - # Blink_web_tests 2021-05-06 -crbug.com/1205669 [ Mac10.13 ] external/wpt/fetch/api/idlharness.any.sharedworker.html [ Failure ] -crbug.com/1205669 [ Mac10.13 ] external/wpt/gamepad/idlharness.https.window.html [ Failure ] -crbug.com/1205669 [ Mac10.13 ] external/wpt/input-device-capabilities/idlharness.window.html [ Failure ] -crbug.com/1205669 [ Mac10.13 ] external/wpt/periodic-background-sync/idlharness.https.any.html [ Failure ] -crbug.com/1205669 [ Mac10.13 ] external/wpt/storage/idlharness.https.any.worker.html [ Failure ] crbug.com/1205669 [ Mac10.13 ] virtual/threaded/external/wpt/animation-worklet/idlharness.any.worker.html [ Failure ] # Sheriff 2021-05-07 # Some plzServiceWorker and plzDedicatedWorker singled out from generic sheriff rounds above -crbug.com/1207851 virtual/plz-dedicated-worker/external/wpt/service-workers/idlharness.https.any.serviceworker.html [ Failure Pass Timeout ] # Sheriff 2021-05-10 -crbug.com/1207709 [ Mac10.13 ] external/wpt/resource-timing/document-domain-no-impact-opener.html [ Failure Pass ] -crbug.com/1207709 [ Mac10.13 ] virtual/plz-dedicated-worker/external/wpt/resource-timing/document-domain-no-impact-opener.html [ Failure Pass ] crbug.com/1207709 [ Mac10.13 ] external/wpt/pointerevents/pointerevent_contextmenu_is_a_pointerevent.html?touch [ Failure Pass Timeout ] # For SkiaRenderer on MacOS @@ -6395,21 +5813,7 @@ # The wpt_flags=h2 variants of these tests fail, but the other variants pass. We # can't handle this difference with -expected.txt files, so we have to list them # here. -crbug.com/1048761 [ Fuchsia ] external/wpt/websockets/Close-1000-reason.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Linux ] external/wpt/websockets/Close-1000-reason.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.12 ] external/wpt/websockets/Close-1000-reason.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.13 ] external/wpt/websockets/Close-1000-reason.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.14 ] external/wpt/websockets/Close-1000-reason.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.15 ] external/wpt/websockets/Close-1000-reason.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac11 ] external/wpt/websockets/Close-1000-reason.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Win ] external/wpt/websockets/Close-1000-reason.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Fuchsia ] external/wpt/websockets/Close-1000-reason.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Linux ] external/wpt/websockets/Close-1000-reason.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.12 ] external/wpt/websockets/Close-1000-reason.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.13 ] external/wpt/websockets/Close-1000-reason.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.14 ] external/wpt/websockets/Close-1000-reason.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.15 ] external/wpt/websockets/Close-1000-reason.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac11 ] external/wpt/websockets/Close-1000-reason.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Win ] external/wpt/websockets/Close-1000-reason.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Close-1000-verify-code.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Close-1000-verify-code.any.worker.html?wpt_flags=h2 [ Failure ] @@ -6419,13 +5823,6 @@ crbug.com/1048761 external/wpt/websockets/Close-1005-verify-code.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Close-1005.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Close-1005.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Fuchsia ] external/wpt/websockets/Close-2999-reason.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Linux ] external/wpt/websockets/Close-2999-reason.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.12 ] external/wpt/websockets/Close-2999-reason.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.13 ] external/wpt/websockets/Close-2999-reason.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.14 ] external/wpt/websockets/Close-2999-reason.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.15 ] external/wpt/websockets/Close-2999-reason.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac11 ] external/wpt/websockets/Close-2999-reason.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Win ] external/wpt/websockets/Close-2999-reason.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Close-2999-reason.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Close-3000-reason.any.html?wpt_flags=h2 [ Failure ] @@ -6445,17 +5842,9 @@ crbug.com/1048761 external/wpt/websockets/Close-reason-unpaired-surrogates.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Close-reason-unpaired-surrogates.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Close-server-initiated-close.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Fuchsia ] external/wpt/websockets/Close-server-initiated-close.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Linux ] external/wpt/websockets/Close-server-initiated-close.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.12 ] external/wpt/websockets/Close-server-initiated-close.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.13 ] external/wpt/websockets/Close-server-initiated-close.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.14 ] external/wpt/websockets/Close-server-initiated-close.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.15 ] external/wpt/websockets/Close-server-initiated-close.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac11 ] external/wpt/websockets/Close-server-initiated-close.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Win ] external/wpt/websockets/Close-server-initiated-close.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Close-undefined.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Close-undefined.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Fuchsia ] external/wpt/websockets/Create-extensions-empty.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Linux ] external/wpt/websockets/Create-extensions-empty.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Mac10.12 ] external/wpt/websockets/Create-extensions-empty.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Mac10.13 ] external/wpt/websockets/Create-extensions-empty.any.html?wpt_flags=h2 [ Failure ] @@ -6465,46 +5854,20 @@ crbug.com/1048761 [ Win ] external/wpt/websockets/Create-extensions-empty.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Create-extensions-empty.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Create-valid-url-array-protocols.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Fuchsia ] external/wpt/websockets/Create-valid-url-array-protocols.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Linux ] external/wpt/websockets/Create-valid-url-array-protocols.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.12 ] external/wpt/websockets/Create-valid-url-array-protocols.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.13 ] external/wpt/websockets/Create-valid-url-array-protocols.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.14 ] external/wpt/websockets/Create-valid-url-array-protocols.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.15 ] external/wpt/websockets/Create-valid-url-array-protocols.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac11 ] external/wpt/websockets/Create-valid-url-array-protocols.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Win ] external/wpt/websockets/Create-valid-url-array-protocols.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Create-valid-url-binaryType-blob.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Create-valid-url-binaryType-blob.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Create-valid-url-protocol-setCorrectly.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Create-valid-url-protocol-setCorrectly.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Create-valid-url-protocol-string.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Fuchsia ] external/wpt/websockets/Create-valid-url-protocol-string.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Linux ] external/wpt/websockets/Create-valid-url-protocol-string.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.12 ] external/wpt/websockets/Create-valid-url-protocol-string.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.13 ] external/wpt/websockets/Create-valid-url-protocol-string.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.14 ] external/wpt/websockets/Create-valid-url-protocol-string.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.15 ] external/wpt/websockets/Create-valid-url-protocol-string.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac11 ] external/wpt/websockets/Create-valid-url-protocol-string.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Win ] external/wpt/websockets/Create-valid-url-protocol-string.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Create-valid-url-protocol.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Fuchsia ] external/wpt/websockets/Create-valid-url-protocol.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Linux ] external/wpt/websockets/Create-valid-url-protocol.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.12 ] external/wpt/websockets/Create-valid-url-protocol.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.13 ] external/wpt/websockets/Create-valid-url-protocol.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.14 ] external/wpt/websockets/Create-valid-url-protocol.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.15 ] external/wpt/websockets/Create-valid-url-protocol.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac11 ] external/wpt/websockets/Create-valid-url-protocol.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Win ] external/wpt/websockets/Create-valid-url-protocol.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Create-valid-url.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Create-valid-url.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Send-0byte-data.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Fuchsia ] external/wpt/websockets/Send-0byte-data.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Linux ] external/wpt/websockets/Send-0byte-data.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.12 ] external/wpt/websockets/Send-0byte-data.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.13 ] external/wpt/websockets/Send-0byte-data.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.14 ] external/wpt/websockets/Send-0byte-data.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.15 ] external/wpt/websockets/Send-0byte-data.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac11 ] external/wpt/websockets/Send-0byte-data.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Win ] external/wpt/websockets/Send-0byte-data.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Send-65K-data.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Send-65K-data.any.worker.html?wpt_flags=h2 [ Failure ] @@ -6514,30 +5877,9 @@ crbug.com/1048761 external/wpt/websockets/Send-binary-arraybuffer.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Send-binary-arraybufferview-float32.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Send-binary-arraybufferview-float32.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Fuchsia ] external/wpt/websockets/Send-binary-arraybufferview-float64.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Linux ] external/wpt/websockets/Send-binary-arraybufferview-float64.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.12 ] external/wpt/websockets/Send-binary-arraybufferview-float64.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.13 ] external/wpt/websockets/Send-binary-arraybufferview-float64.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.14 ] external/wpt/websockets/Send-binary-arraybufferview-float64.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.15 ] external/wpt/websockets/Send-binary-arraybufferview-float64.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac11 ] external/wpt/websockets/Send-binary-arraybufferview-float64.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Win ] external/wpt/websockets/Send-binary-arraybufferview-float64.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Send-binary-arraybufferview-float64.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Fuchsia ] external/wpt/websockets/Send-binary-arraybufferview-int16-offset.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Linux ] external/wpt/websockets/Send-binary-arraybufferview-int16-offset.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.12 ] external/wpt/websockets/Send-binary-arraybufferview-int16-offset.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.13 ] external/wpt/websockets/Send-binary-arraybufferview-int16-offset.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.14 ] external/wpt/websockets/Send-binary-arraybufferview-int16-offset.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.15 ] external/wpt/websockets/Send-binary-arraybufferview-int16-offset.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac11 ] external/wpt/websockets/Send-binary-arraybufferview-int16-offset.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Win ] external/wpt/websockets/Send-binary-arraybufferview-int16-offset.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Fuchsia ] external/wpt/websockets/Send-binary-arraybufferview-int16-offset.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Linux ] external/wpt/websockets/Send-binary-arraybufferview-int16-offset.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.12 ] external/wpt/websockets/Send-binary-arraybufferview-int16-offset.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.13 ] external/wpt/websockets/Send-binary-arraybufferview-int16-offset.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.14 ] external/wpt/websockets/Send-binary-arraybufferview-int16-offset.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.15 ] external/wpt/websockets/Send-binary-arraybufferview-int16-offset.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac11 ] external/wpt/websockets/Send-binary-arraybufferview-int16-offset.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Win ] external/wpt/websockets/Send-binary-arraybufferview-int16-offset.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Send-binary-arraybufferview-int32.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Send-binary-arraybufferview-int32.any.worker.html?wpt_flags=h2 [ Failure ] @@ -6545,13 +5887,6 @@ crbug.com/1048761 external/wpt/websockets/Send-binary-arraybufferview-int8.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Send-binary-arraybufferview-uint16-offset-length.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Send-binary-arraybufferview-uint16-offset-length.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Fuchsia ] external/wpt/websockets/Send-binary-arraybufferview-uint32-offset.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Linux ] external/wpt/websockets/Send-binary-arraybufferview-uint32-offset.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.12 ] external/wpt/websockets/Send-binary-arraybufferview-uint32-offset.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.13 ] external/wpt/websockets/Send-binary-arraybufferview-uint32-offset.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.14 ] external/wpt/websockets/Send-binary-arraybufferview-uint32-offset.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.15 ] external/wpt/websockets/Send-binary-arraybufferview-uint32-offset.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac11 ] external/wpt/websockets/Send-binary-arraybufferview-uint32-offset.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Win ] external/wpt/websockets/Send-binary-arraybufferview-uint32-offset.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Send-binary-arraybufferview-uint32-offset.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Send-binary-arraybufferview-uint8-offset-length.any.html?wpt_flags=h2 [ Failure ] @@ -6569,21 +5904,7 @@ crbug.com/1048761 external/wpt/websockets/Send-paired-surrogates.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Send-unicode-data.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/Send-unicode-data.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Fuchsia ] external/wpt/websockets/Send-unpaired-surrogates.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Linux ] external/wpt/websockets/Send-unpaired-surrogates.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.12 ] external/wpt/websockets/Send-unpaired-surrogates.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.13 ] external/wpt/websockets/Send-unpaired-surrogates.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.14 ] external/wpt/websockets/Send-unpaired-surrogates.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.15 ] external/wpt/websockets/Send-unpaired-surrogates.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac11 ] external/wpt/websockets/Send-unpaired-surrogates.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Win ] external/wpt/websockets/Send-unpaired-surrogates.any.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Fuchsia ] external/wpt/websockets/Send-unpaired-surrogates.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Linux ] external/wpt/websockets/Send-unpaired-surrogates.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.12 ] external/wpt/websockets/Send-unpaired-surrogates.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.13 ] external/wpt/websockets/Send-unpaired-surrogates.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.14 ] external/wpt/websockets/Send-unpaired-surrogates.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.15 ] external/wpt/websockets/Send-unpaired-surrogates.any.worker.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac11 ] external/wpt/websockets/Send-unpaired-surrogates.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Win ] external/wpt/websockets/Send-unpaired-surrogates.any.worker.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/binaryType-wrong-value.any.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/binaryType-wrong-value.any.worker.html?wpt_flags=h2 [ Failure ] @@ -6595,21 +5916,8 @@ crbug.com/1048761 external/wpt/websockets/interfaces/WebSocket/bufferedAmount/bufferedAmount-arraybuffer.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/interfaces/WebSocket/bufferedAmount/bufferedAmount-blob.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/interfaces/WebSocket/bufferedAmount/bufferedAmount-large.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Fuchsia ] external/wpt/websockets/interfaces/WebSocket/bufferedAmount/bufferedAmount-unicode.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Linux ] external/wpt/websockets/interfaces/WebSocket/bufferedAmount/bufferedAmount-unicode.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.12 ] external/wpt/websockets/interfaces/WebSocket/bufferedAmount/bufferedAmount-unicode.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.13 ] external/wpt/websockets/interfaces/WebSocket/bufferedAmount/bufferedAmount-unicode.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.14 ] external/wpt/websockets/interfaces/WebSocket/bufferedAmount/bufferedAmount-unicode.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.15 ] external/wpt/websockets/interfaces/WebSocket/bufferedAmount/bufferedAmount-unicode.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac11 ] external/wpt/websockets/interfaces/WebSocket/bufferedAmount/bufferedAmount-unicode.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Win ] external/wpt/websockets/interfaces/WebSocket/bufferedAmount/bufferedAmount-unicode.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Fuchsia ] external/wpt/websockets/interfaces/WebSocket/events/018.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Linux ] external/wpt/websockets/interfaces/WebSocket/events/018.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.12 ] external/wpt/websockets/interfaces/WebSocket/events/018.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.13 ] external/wpt/websockets/interfaces/WebSocket/events/018.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.14 ] external/wpt/websockets/interfaces/WebSocket/events/018.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac10.15 ] external/wpt/websockets/interfaces/WebSocket/events/018.html?wpt_flags=h2 [ Failure ] -crbug.com/1048761 [ Mac11 ] external/wpt/websockets/interfaces/WebSocket/events/018.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 [ Win ] external/wpt/websockets/interfaces/WebSocket/events/018.html?wpt_flags=h2 [ Failure ] crbug.com/1048761 external/wpt/websockets/interfaces/WebSocket/send/006.html?wpt_flags=h2 [ Failure ] @@ -6619,19 +5927,12 @@ # Do not retry slow tests that also timeouts crbug.com/1210687 [ Mac10.15 ] fast/events/open-window-from-another-frame.html [ Pass Timeout ] -crbug.com/1210687 [ Mac10.15 ] http/tests/devtools/a11y-axe-core/sources/scope-pane-a11y-test.js [ Pass Timeout ] crbug.com/1210687 [ Mac ] http/tests/permissions/chromium/test-request-worker.html [ Pass Timeout ] crbug.com/1210687 [ Mac10.15 ] storage/websql/sql-error-codes.html [ Pass Timeout ] crbug.com/1210687 [ Mac10.15 ] external/wpt/html/user-activation/propagation-crossorigin.sub.tentative.html [ Pass Timeout ] # Sheriff 2021-06-02 crbug.com/1215575 [ Mac11 ] fast/peerconnection/RTCPeerConnection-applyConstraints-remoteVideoTrack.html [ Pass Timeout ] -crbug.com/1215575 [ Mac11-arm64 ] fast/peerconnection/RTCPeerConnection-applyConstraints-remoteVideoTrack.html [ Pass Timeout ] -crbug.com/1215575 [ Mac11 ] fast/peerconnection/RTCPeerConnection-createDTMFSender.html [ Failure Pass ] -crbug.com/1215575 [ Mac11 ] fast/peerconnection/RTCPeerConnection-datachannel.html [ Pass Timeout ] -crbug.com/1215575 [ Mac11-arm64 ] fast/peerconnection/RTCPeerConnection-datachannel.html [ Pass Timeout ] -crbug.com/1215575 [ Mac11 ] fast/peerconnection/RTCPeerConnection-lifetime.html [ Pass Timeout ] -crbug.com/1215575 [ Mac11-arm64 ] fast/peerconnection/RTCPeerConnection-lifetime.html [ Pass Timeout ] crbug.com/1215584 [ Mac11 ] inspector-protocol/layout-fonts/lang-fallback.js [ Failure Pass ] # Fail with field trial testing config. @@ -6657,28 +5958,18 @@ crbug.com/1147859 [ Linux ] virtual/css-highlight-inheritance/external/wpt/css/css-highlight-api/painting/* [ Failure ] crbug.com/1147859 [ Linux ] paint/custom-highlight-only-inheritance.html [ Failure ] -# Sheriff 2021-06-11 -crbug.com/1218667 [ Win ] virtual/portals/wpt_internal/portals/portals-dangling-markup.sub.html [ Pass Timeout ] -crbug.com/1218714 [ Win ] virtual/scroll-unification/fast/forms/select-popup/popup-menu-scrollbar-button-scrolls.html [ Pass Timeout ] - # Green Mac11 Test -crbug.com/1201406 [ Mac11 ] http/tests/credentialmanagement/credentialscontainer-create-from-nested-frame.html [ Crash Timeout ] crbug.com/1201406 [ Mac11 ] http/tests/credentialmanagement/credentialscontainer-create-origins.html [ Crash Timeout ] crbug.com/1201406 http/tests/credentialmanagement/publickeycredential-same-origin-with-ancestors.html [ Crash Pass Timeout ] -crbug.com/1201406 [ Mac11 ] http/tests/credentialmanagement/register-then-sign.html [ Crash Timeout ] # Sheriff 2021-06-14 crbug.com/1219499 external/wpt/websockets/Create-blocked-port.any.html?wpt_flags=h2 [ Failure Pass Timeout ] crbug.com/1219499 [ Win ] external/wpt/websockets/Create-blocked-port.any.html?wss [ Pass Timeout ] # Sheriff 2021-06-15 -crbug.com/1220317 [ Linux ] external/wpt/media-capabilities/decodingInfoEncryptedMedia.https.html [ Crash Failure Pass ] -crbug.com/1220317 [ Linux ] external/wpt/media-capabilities/decodingInfo.any.html [ Crash Failure Pass ] crbug.com/1220007 [ Linux ] fullscreen/full-screen-iframe-allowed-video.html [ Failure Pass Timeout ] # Sheriff -crbug.com/1223327 wpt_internal/prerender/unload.html [ Pass Timeout ] -crbug.com/1223327 virtual/prerender/wpt_internal/prerender/unload.html [ Pass Timeout ] crbug.com/1222097 external/wpt/mediacapture-image/detached-HTMLCanvasElement.html [ Skip ] crbug.com/1222097 http/tests/canvas/captureStream-on-detached-canvas.html [ Skip ] crbug.com/1222097 virtual/plz-dedicated-worker/external/wpt/html/cross-origin-embedder-policy/blob.https.html [ Skip ] @@ -6695,10 +5986,6 @@ # Flaky on Mac11 Tests crbug.com/1197464 [ Mac ] plugins/refcount-leaks.html [ Failure Pass ] -# Sheriff 2021-06-30 -crbug.com/1216587 [ Win7 ] accessibility/scroll-window-sends-notification.html [ Failure Pass ] -crbug.com/1216587 [ Mac11-arm64 ] accessibility/scroll-window-sends-notification.html [ Failure Pass ] - # Sheriff 2021-07-01 # Now also flakily timing-out. crbug.com/1193920 virtual/threaded-prefer-compositing/fast/scrolling/events/overscroll-event-fired-to-scrolled-element.html [ Failure Pass Timeout ] @@ -6749,7 +6036,6 @@ crbug.com/1228261 http/tests/inspector-protocol/service-worker/network-get-request-body-blob.js [ Crash Failure Pass Skip Timeout ] # Flakes that might be caused or aggravated by PlzServiceWorker -crbug.com/996511 external/wpt/service-workers/cache-storage/frame/cache-abort.https.html [ Crash Failure Pass Timeout ] crbug.com/996511 external/wpt/service-workers/cache-storage/window/cache-abort.https.html [ Crash Failure Pass ] crbug.com/996511 external/wpt/service-workers/service-worker/getregistrations.https.html [ Crash Failure Pass Timeout ] crbug.com/996511 http/tests/inspector-protocol/fetch/fetch-cors-preflight-sw.js [ Crash Failure Pass Timeout ] @@ -6824,7 +6110,6 @@ crbug.com/1239175 http/tests/navigation/same-and-different-back.html [ Failure Pass ] crbug.com/1239164 http/tests/inspector-protocol/network/navigate-iframe-in2in.js [ Failure Pass ] crbug.com/1237909 external/wpt/webrtc-svc/RTCRtpParameters-scalability.html [ Crash Failure Pass Timeout ] -crbug.com/1239161 external/wpt/html/semantics/links/links-created-by-a-and-area-elements/htmlanchorelement_noopener.html [ Failure Pass ] # Sheriff 2021-08-19 crbug.com/1234315 [ Mac ] virtual/threaded/external/wpt/animation-worklet/worklet-animation-with-scroll-timeline-and-overflow-hidden.https.html [ Failure Timeout ] @@ -6871,7 +6156,6 @@ crbug.com/1249071 virtual/composite-clip-path-animation/external/wpt/css/css-masking/clip-path/animations/clip-path-animation-filter.html [ Crash Failure Pass ] # Following tests fail on mac11-arm64 -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/svg/extensibility/foreignObject/foreign-object-scale-scroll.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/density-size-correction/image-set-003.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/css/css-content/quotes-006.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/css/css-content/quotes-020.html [ Failure ] @@ -6879,11 +6163,9 @@ crbug.com/1249176 [ Mac11-arm64 ] css3/blending/svg-blend-multiply.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/html/canvas/element/manual/drawing-images-to-the-canvas/image-orientation/drawImage-from-blob.tentative.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/largest-contentful-paint/image-src-change.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/service-workers/service-worker/clients-matchall-order.https.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] http/tests/images/document-policy-oversized-images-forced-layout.php [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] transforms/transformed-document-element.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/manual/drawing-images-to-the-canvas/image-orientation/drawImage-from-blob.tentative.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] virtual/plz-dedicated-worker/external/wpt/service-workers/service-worker/clients-matchall-order.https.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] virtual/threaded/http/tests/devtools/tracing/timeline-paint/paint-profiler-update.js [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] virtual/threaded/http/tests/devtools/tracing/timeline-time/timeline-usertiming.js [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] webaudio/codec-tests/webm/webm-decode.html [ Failure ] @@ -6891,34 +6173,15 @@ crbug.com/1249176 [ Mac11-arm64 ] webaudio/AudioBufferSource/audiobuffersource-playbackrate-modulation.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] webaudio/Analyser/realtimeanalyser-freq-data.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] webaudio/Oscillator/no-dezippering.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] virtual/overlay-scrollbar/plugin-overlay-scrollbar-mouse-capture.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] virtual/offsetparent-old-behavior/external/wpt/shadow-dom/accesskey.tentative.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] virtual/plz-dedicated-worker/external/wpt/service-workers/idlharness.https.any.worker.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] virtual/plz-dedicated-worker/external/wpt/workers/interfaces/WorkerUtils/importScripts/blob-url.worker.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/editing/other/editing-around-select-element.tentative_insertText.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/editing/run/delete_6001-last.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/editing/run/forwarddelete_6001-last.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/html/semantics/embedded-content/media-elements/interfaces/TextTrackCue/endTime.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/webaudio/the-audio-api/the-convolvernode-interface/realtime-conv.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/shadow-dom/accesskey.tentative.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/service-workers/idlharness.https.any.worker.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/web-share/disabled-by-feature-policy.https.sub.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/dom/xslt/transformToFragment.tentative.window.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/webvtt/api/VTTCue/constructor.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/content-security-policy/securitypolicyviolation/source-file-data-scheme.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/selection/textcontrols/selectionchange.tentative.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/websockets/constructor/002_wss.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/websockets/basic-auth.any.worker_wpt_flags=h2.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/websockets/basic-auth.any.sharedworker_wpt_flags=h2.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/websockets/interfaces/WebSocket/readyState/003_wss.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/websockets/interfaces/WebSocket/close/close-nested_wss.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/websockets/interfaces/WebSocket/close/close-connecting_wss.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/websockets/Create-protocols-repeated-case-insensitive.any_wss.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/websockets/unload-a-document/002_wss.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/websockets/stream/tentative/backpressure-send.any_wpt_flags=h2.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/websockets/stream/tentative/backpressure-send.any.worker_wpt_flags=h2.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] fast/forms/color/color-picker-escape-cancellation-revert.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] fast/css/focus-display-block-inline.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] fast/dom/geometry-interfaces-dom-matrix-rotate.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/css/css-shapes/shape-outside/shape-image/shape-image-021.html [ Failure ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/css/css-shapes/shape-outside/shape-image/shape-image-025.html [ Failure ] @@ -6935,15 +6198,12 @@ crbug.com/1249176 [ Mac11-arm64 ] transforms/3d/general/cssmatrix-3d-zoom.html [ Failure Pass ] crbug.com/1249176 [ Mac11-arm64 ] http/tests/images/document-policy-lossy-images-max-bpp.php [ Failure Pass Timeout ] crbug.com/1249176 [ Mac11-arm64 ] fast/forms/plaintext-mode-2.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] inspector-protocol/timeline/timeline-layout.js [ Failure Pass ] crbug.com/1249176 [ Mac11-arm64 ] http/tests/devtools/tracing/timeline-time/timeline-usertiming.js [ Failure Pass ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/resource-timing/nested-context-navigations-embed.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] http/tests/devtools/tracing/timeline-js/timeline-microtasks.js [ Failure Pass ] crbug.com/1249176 [ Mac11-arm64 ] http/tests/intersection-observer/cross-origin-iframe-with-nesting.html [ Pass Timeout ] crbug.com/1249176 [ Mac11-arm64 ] media/controls/overflow-menu-always-visible.html [ Failure Pass ] crbug.com/1249176 [ Mac11-arm64 ] paint/markers/document-markers-font-8px.html [ Failure Pass ] crbug.com/1249176 [ Mac11-arm64 ] paint/markers/document-markers-zoom-2000.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] http/tests/devtools/tracing/timeline-layout/timeline-layout-reason.js [ Failure Pass ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/resource-timing/nested-context-navigations-object.html [ Failure Pass ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/webvtt/rendering/cues-with-video/processing-model/audio_has_no_subtitles.html [ Failure Pass ] crbug.com/1249176 [ Mac11-arm64 ] http/tests/preload/without_doc_write_evaluator.html [ Failure Pass ] @@ -6956,31 +6216,8 @@ crbug.com/1249176 [ Mac11-arm64 ] http/tests/devtools/tracing/frame-model-instrumentation.js [ Failure Pass ] crbug.com/1249176 [ Mac11-arm64 ] inspector-protocol/layout-fonts/lang-fallback.js [ Failure Pass ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/css/css-position/fixed-z-index-blend.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] http/tests/devtools/tracing/timeline-paint/timeline-pre-paint.js [ Failure Pass ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/layout-instability/recent-input.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] inspector-protocol/performance/perf-metrics.js [ Failure Pass ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/event-timing/event-retarget.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/mimesniff/media/media-sniff.window.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/webcodecs/audio-decoder.crossOriginIsolated.https.any.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/webcodecs/audio-decoder.crossOriginIsolated.https.any.worker.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/webcodecs/audioDecoder-codec-specific.https.any.html?adts_aac [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/webcodecs/audioDecoder-codec-specific.https.any.html?mp4_aac [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/webcodecs/video-decoder.crossOriginIsolated.https.any.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/webcodecs/video-decoder.crossOriginIsolated.https.any.worker.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/webcodecs/videoDecoder-codec-specific.https.any.html?h264_annexb [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/webcodecs/videoDecoder-codec-specific.https.any.html?h264_avc [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/webrtc/RTCRtpTransceiver-setCodecPreferences.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/webrtc/protocol/video-codecs.https.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] fast/mediarecorder/MediaRecorder-ignores-oversize-frames-h264.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/protocol/video-codecs.https.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] wpt_internal/webcodecs/annexb_decoding.https.any.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] wpt_internal/webcodecs/annexb_decoding.https.any.worker.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] wpt_internal/webcodecs/avc_encoder_config.https.any.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] wpt_internal/webcodecs/avc_encoder_config.https.any.worker.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/webcodecs/audioDecoder-codec-specific.https.any.worker.html?adts_aac [ Pass Timeout ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/webcodecs/audioDecoder-codec-specific.https.any.worker.html?mp4_aac [ Pass Timeout ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/webcodecs/videoDecoder-codec-specific.https.any.worker.html?h264_annexb [ Pass Timeout ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/webcodecs/videoDecoder-codec-specific.https.any.worker.html?h264_avc [ Pass Timeout ] crbug.com/1249176 virtual/gpu-rasterization/images/12-55.html [ Skip ] crbug.com/1249176 [ Mac11-arm64 ] fast/forms/file/recover-file-input-in-unposted-form.html [ Failure Pass ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/css/css-shapes/shape-outside/shape-image/shape-image-015.html [ Failure Pass ] @@ -6990,50 +6227,31 @@ crbug.com/1249176 [ Mac11-arm64 ] virtual/scalefactor200/external/wpt/largest-contentful-paint/multiple-redirects-TAO.html [ Failure Pass ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/largest-contentful-paint/multiple-redirects-TAO.html [ Failure Pass ] crbug.com/1249176 [ Mac11-arm64 ] virtual/background-svg-in-lcp/external/wpt/largest-contentful-paint/multiple-redirects-TAO.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/protocol/split.https.html [ Pass Timeout ] # mac-arm CI 10-01-2021 -crbug.com/1249176 [ Mac11-arm64 ] editing/text-iterator/beforematch-async.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/event-timing/click-interactionid.html [ Timeout ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/html/webappapis/update-rendering/child-document-raf-order.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/idle-detection/interceptor.https.html [ Pass Timeout ] crbug.com/1249176 [ Mac11-arm64 ] http/tests/security/opened-document-security-origin-resets-on-navigation.html [ Timeout ] -crbug.com/1249176 [ Mac11-arm64 ] inspector-protocol/runtime/runtime-install-binding.js [ Failure Pass ] # mac-arm CI 10-05-2021 crbug.com/1249176 [ Mac11-arm64 ] virtual/no-alloc-direct-call/fast/canvas/canvas-lost-gpu-context.html [ Failure ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/html/canvas/offscreen/manual/the-offscreen-canvas/offscreencanvas.commit.html [ Failure Pass ] crbug.com/1249176 [ Mac11-arm64 ] virtual/gpu-rasterization/images/directly-composited-image-orientation.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] virtual/scroll-unification/plugins/focus-change-1-no-change.html [ Failure Pass ] crbug.com/1249176 [ Mac11-arm64 ] plugins/plugin-remove-subframe.html [ Crash Pass ] crbug.com/1249176 [ Mac11-arm64 ] fast/replaced/no-focus-ring-object.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] editing/selection/find-in-text-control.html [ Crash ] -crbug.com/1249176 [ Mac11-arm64 ] fast/forms/suggestion-picker/datetimelocal-suggestion-picker-min-max-attribute.html [ Crash ] -crbug.com/1249176 [ Mac11-arm64 ] http/tests/local/stylesheet-and-script-load-order-http.html [ Crash ] -crbug.com/1249176 [ Mac11-arm64 ] http/tests/local/blob/send-sliced-data-blob.html [ Crash ] -crbug.com/1249176 [ Mac11-arm64 ] http/tests/local/formdata/send-form-data-with-empty-name.html [ Crash ] -crbug.com/1249176 [ Mac11-arm64 ] paint/invalidation/selection/invalidation-rect-includes-newline-for-rtl.html [ Crash ] -crbug.com/1249176 [ Mac11-arm64 ] storage/indexeddb/intversion-revert-on-abort.html [ Crash ] crbug.com/1249176 [ Mac11-arm64 ] svg/animations/animate-setcurrenttime.html [ Crash ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/css/css-shapes/shape-outside/shape-image/shape-image-011.html [ Crash Failure Pass ] crbug.com/1249176 [ Mac11-arm64 ] external/wpt/css/css-shapes/shape-outside/shape-image/shape-image-018.html [ Failure Pass ] -crbug.com/1249176 [ Mac11-arm64 ] external/wpt/xhr/send-no-response-event-loadend.htm [ Crash Pass ] crbug.com/1249176 [ Mac11-arm64 ] http/tests/inspector-protocol/network/blocked-cookie-same-site-strict.js [ Crash Pass ] crbug.com/1249176 [ Mac11-arm64 ] http/tests/inspector-protocol/network/xhr-post-replay-cors.js [ Crash Pass ] crbug.com/1249176 [ Mac11-arm64 ] http/tests/security/cross-origin-shared-worker-allowed.html [ Crash Pass ] crbug.com/1249176 [ Mac11-arm64 ] media/autoplay/webaudio-audio-context-init.html [ Crash Pass ] -crbug.com/1249176 [ Mac11-arm64 ] virtual/composite-relative-keyframes/external/wpt/css/css-transforms/animation/transform-interpolation-005.html [ Crash Pass ] # Sheriff 2021-09-16 crbug.com/1250457 [ Mac ] virtual/scroll-unification/plugins/plugin-map-data-to-src.html [ Failure ] crbug.com/1250457 [ Mac ] storage/websql/open-database-set-empty-version.html [ Timeout ] crbug.com/1250457 [ Mac ] virtual/portals/http/tests/devtools/portals/portals-console.js [ Skip Timeout ] crbug.com/1250457 [ Mac ] virtual/prefer_compositing_to_lcd_text/scrollbars/custom-scrollbar-inactive-pseudo.html [ Timeout ] -crbug.com/1250457 [ Mac ] virtual/scalefactor200/css3/filters/filter-animation-multi-hw.html [ Timeout ] crbug.com/1250457 [ Mac ] virtual/scroll-unification/fast/events/space-scroll-textinput-canceled.html [ Timeout ] -crbug.com/1250457 [ Mac ] external/wpt/html/syntax/speculative-parsing/generated/document-write/meta-viewport-link-stylesheet-media.tentative.sub.html [ Failure ] crbug.com/1249622 external/wpt/largest-contentful-paint/initially-invisible-images.html [ Failure ] crbug.com/1249622 virtual/initially-invisible-images-lcp/external/wpt/largest-contentful-paint/initially-invisible-images.html [ Pass ] @@ -7044,12 +6262,8 @@ # FileSystemHandle::move() is temporarily disabled outside of the Origin Private File System crbug.com/1247850 external/wpt/file-system-access/local_FileSystemFileHandle-move-manual.https.html [ Failure ] -crbug.com/1247850 [ Fuchsia ] virtual/fsa-incognito/external/wpt/file-system-access/local_FileSystemFileHandle-move-manual.https.html [ Failure ] crbug.com/1247850 [ Linux ] virtual/fsa-incognito/external/wpt/file-system-access/local_FileSystemFileHandle-move-manual.https.html [ Failure ] crbug.com/1247850 [ Mac10.12 ] virtual/fsa-incognito/external/wpt/file-system-access/local_FileSystemFileHandle-move-manual.https.html [ Failure ] -crbug.com/1247850 [ Mac10.13 ] virtual/fsa-incognito/external/wpt/file-system-access/local_FileSystemFileHandle-move-manual.https.html [ Failure ] -crbug.com/1247850 [ Mac10.14 ] virtual/fsa-incognito/external/wpt/file-system-access/local_FileSystemFileHandle-move-manual.https.html [ Failure ] -crbug.com/1247850 [ Mac10.15 ] virtual/fsa-incognito/external/wpt/file-system-access/local_FileSystemFileHandle-move-manual.https.html [ Failure ] crbug.com/1247850 [ Mac11 ] virtual/fsa-incognito/external/wpt/file-system-access/local_FileSystemFileHandle-move-manual.https.html [ Failure ] crbug.com/1247850 [ Win ] virtual/fsa-incognito/external/wpt/file-system-access/local_FileSystemFileHandle-move-manual.https.html [ Failure ] # FileSystemHandle::move() is temporarily disabled for directory handles @@ -7135,11 +6349,6 @@ crbug.com/1259133 [ Mac10.14 ] virtual/no-alloc-direct-call/external/wpt/html/canvas/offscreen/manual/the-offscreen-canvas/offscreencanvas.commit.html [ Failure Pass ] crbug.com/1259277 [ Linux ] virtual/scroll-unification/fast/events/message-port-multi.html [ Failure Pass ] -# Sheriff 2021-10-13 -crbug.com/1259652 [ Mac10.13 ] external/wpt/streams/readable-streams/tee.any.html [ Failure Pass ] -crbug.com/1259652 [ Mac10.13 ] external/wpt/streams/readable-streams/tee.any.serviceworker.html [ Failure Pass ] -crbug.com/1259652 [ Mac10.13 ] external/wpt/streams/readable-streams/tee.any.sharedworker.html [ Failure Pass ] - # Data URL navigation within Fenced Frames currently crashed in the MPArch implementation. crbug.com/1243568 virtual/fenced-frame-mparch/wpt_internal/fenced_frame/window-data-url-navigation.https.html [ Timeout ] @@ -7160,9 +6369,6 @@ # Sheriff 2021-10-29 crbug.com/1264670 [ Linux ] http/tests/devtools/resource-tree/resource-tree-frame-add.js [ Failure Pass ] -# Sheriff 2021-11-02 -crbug.com/1265924 [ Fuchsia ] synthetic_gestures/smooth-scroll-tiny-delta.html [ Failure Pass ] - # TODO(https://crbug.com/1265311): Make the test behave the same way on all platforms crbug.com/1265311 http/tests/navigation/location-change-repeated-from-blank.html [ Failure Pass ] @@ -7171,19 +6377,14 @@ crbug.com/1266221 [ Mac11-arm64 ] virtual/fsa-incognito/external/wpt/file-system-access/sandboxed_FileSystemFileHandle-create-sync-access-handle.https.tentative.window.html [ Failure Pass ] # Sheriff 2021-11-08 -crbug.com/1267734 [ Win7 ] virtual/plz-dedicated-worker/external/wpt/resource-timing/object-not-found-after-TAO-cross-origin-redirect.html [ Failure Pass ] crbug.com/1267736 [ Win ] http/tests/devtools/bindings/jssourcemap-bindings-overlapping-sources.js [ Failure Pass ] # Sheriff 2021-11-09 crbug.com/1269535 http/tests/misc/resource-timing-sizes-multipart.html [ Failure Pass Timeout ] # This test is flaky on all platforms -crbug.com/1191846 [ Fuchsia ] virtual/prerender/external/wpt/speculation-rules/prerender/local-storage.html [ Failure Pass ] crbug.com/1191846 [ Mac10.12 ] virtual/prerender/external/wpt/speculation-rules/prerender/local-storage.html [ Failure Pass Timeout ] -crbug.com/1191846 [ Mac10.13 ] virtual/prerender/external/wpt/speculation-rules/prerender/local-storage.html [ Failure Pass Timeout ] -crbug.com/1191846 [ Mac10.14 ] virtual/prerender/external/wpt/speculation-rules/prerender/local-storage.html [ Failure Pass Timeout ] crbug.com/1191846 [ Mac11 ] virtual/prerender/external/wpt/speculation-rules/prerender/local-storage.html [ Failure Pass Timeout ] -crbug.com/1191846 [ Mac11-arm64 ] virtual/prerender/external/wpt/speculation-rules/prerender/local-storage.html [ Failure Pass Timeout ] crbug.com/1191846 [ Win ] virtual/prerender/external/wpt/speculation-rules/prerender/local-storage.html [ Failure Pass ] # Sheriff 2021-11-10 @@ -7262,17 +6463,11 @@ crbug.com/1275967 [ Linux ] external/wpt/permissions-policy/permissions-policy-frame-policy-timing.https.sub.html [ Failure Pass ] crbug.com/1275944 [ Mac ] http/tests/devtools/sources/debugger-ui/reveal-not-skipped.js [ Failure Pass ] crbug.com/1275944 [ Win7 ] http/tests/devtools/sources/debugger-ui/reveal-not-skipped.js [ Failure Pass ] -crbug.com/1276199 [ Linux ] external/wpt/fetch/private-network-access/secure-context.https.window.html [ Pass Timeout ] -crbug.com/1276199 [ Linux ] virtual/plz-dedicated-worker/external/wpt/fetch/private-network-access/secure-context.https.window.html [ Pass Timeout ] crbug.com/1276206 http/tests/inspector-protocol/network/blocked-cookie-same-party.js [ Failure Pass Timeout ] crbug.com/1276207 virtual/gpu-rasterization/images/color-profile-image-object-fit.html [ Failure Pass ] crbug.com/1276208 [ Mac ] virtual/oopr-canvas2d/fast/canvas/canvas-fillPath-alpha-shadow.html [ Pass Timeout ] crbug.com/1276290 [ Mac ] wpt_internal/mediastream/mediastreamtrackprocessor-transfer-to-worker.html [ Skip ] -# Tests for absence of SDES that will fail because Fuchsia is allowed to use SDES -crbug.com/804275 [ Fuchsia ] fast/peerconnection/RTCPeerConnection-sdes-constraint.html [ Failure ] -crbug.com/804275 [ Fuchsia ] external/wpt/webrtc/protocol/sdes-dont-dont-dont.html [ Failure ] - # Sheriff 2021-12-03 crbug.com/1198781 [ Linux ] virtual/scroll-unification-layout_ng_block_frag/fast/forms/fieldset/fieldset-custom-scrollbar.html [ Failure Pass ] @@ -7291,14 +6486,12 @@ crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/compositing/2d.composite.canvas.source-out.html [ Crash Pass ] crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/compositing/2d.composite.clip.xor.html [ Crash Pass ] crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/compositing/2d.composite.operation.darker.html [ Crash Pass ] -crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/compositing/2d.composite.uncovered.pattern.copy.html [ Crash Pass ] crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/compositing/2d.composite.uncovered.pattern.source-in.html [ Crash Pass ] crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/drawing-images-to-the-canvas/2d.drawImage.null.html [ Crash Pass ] crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/drawing-images-to-the-canvas/2d.drawImage.wrongtype.html [ Crash Pass ] crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/drawing-rectangles-to-the-canvas/2d.clearRect.path.html [ Crash Pass ] crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/drawing-rectangles-to-the-canvas/2d.fillRect.zero.html [ Crash Pass ] crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/drawing-text-to-the-canvas/2d.text.draw.fill.maxWidth.large-manual.html [ Crash Pass ] -crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/fill-and-stroke-styles/2d.fillStyle.parse.hsl-1.html [ Crash Pass ] crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/fill-and-stroke-styles/2d.fillStyle.parse.hsla-clamp-4.html [ Crash Pass ] crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/fill-and-stroke-styles/2d.fillStyle.parse.invalid.hsl-5.html [ Crash Pass ] crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/fill-and-stroke-styles/2d.gradient.object.current.html [ Crash Pass ] @@ -7307,21 +6500,9 @@ crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/line-styles/2d.line.miter.obtuse.html [ Crash Pass ] crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/manual/fill-and-stroke-styles/2d.fillStyle.parse.current.notrendered.html [ Crash Pass ] crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/manual/wide-gamut-canvas/canvas-drawImage-offscreenCanvas.html [ Crash Pass ] -crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/path-objects/2d.path.isPointInPath.transform.1.html [ Crash Pass ] -crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/path-objects/2d.path.roundrect.3.radii.1.double.html [ Crash Pass ] -crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/path-objects/2d.path.roundrect.4.radii.4.dompointinit.html [ Crash Pass ] -crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/pixel-manipulation/2d.imageData.create2.type.html [ Crash Pass ] crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/pixel-manipulation/2d.imageData.get.order.cols.html [ Crash Pass ] -crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/pixel-manipulation/2d.imageData.object.round.html [ Crash Pass ] -crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/shadows/2d.shadow.canvas.transparent.2.html [ Crash Pass ] -crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/shadows/2d.shadow.enable.off.2.html [ Crash Pass ] -crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/text-styles/2d.text.draw.space.collapse.start.html [ Crash Pass ] crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/text-styles/2d.text.font.parse.tiny.html [ Crash Pass ] -crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/the-canvas-state/2d.state.saverestore.shadowOffsetY.html [ Crash Pass ] crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/transformations/2d.transformation.transform.multiply.html [ Crash Pass ] -crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/offscreen/2d.conformance.requirements.missingargs.html [ Crash Pass ] -crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/offscreen/compositing/2d.composite.globalAlpha.default.html [ Crash Pass ] -crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/offscreen/drawing-images-to-the-canvas/2d.drawImage.5arg.html [ Crash Pass ] crbug.com/1281782 [ Mac ] virtual/no-alloc-direct-call/external/wpt/html/canvas/element/manual/wide-gamut-canvas/canvas-display-p3-drawImage-ImageBitmap-cloned.html [ Pass Timeout ] crbug.com/1281792 external/wpt/event-timing/min-duration-threshold.html [ Failure Pass ] @@ -7338,7 +6519,6 @@ # Sheriff 2021-12-30 crbug.com/1229096 [ Win ] fast/scrolling/events/overscroll-event-fired-to-scrolled-element.html [ Failure Pass ] crbug.com/1279758 [ Win10.20h2 ] virtual/threaded-prefer-compositing/fast/scrolling/scroll-animation-on-by-default.html [ Failure Pass ] -crbug.com/1229095 [ Linux ] virtual/gpu/fast/canvas/canvas-getImageData.html [ Failure Pass ] crbug.com/1280736 [ Win10.20h2 ] http/tests/inspector-protocol/network/blocked-setcookie-same-site-strict.js [ Pass Timeout ] crbug.com/1280736 [ Win10.20h2 ] http/tests/inspector-protocol/network/blocked-setcookie-same-site-lax.js [ Pass Timeout ] @@ -7366,7 +6546,6 @@ # Flaky failures in finding the reference file on Mac crbug.com/1286944 [ Mac10.15 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/color-custom-property-animation.https.html [ Failure Pass ] -crbug.com/1286944 [ Mac10.15 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/dynamic-import.https.html [ Failure Pass ] crbug.com/1286944 [ Mac ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/geometry-border-image-002.https.html [ Failure Pass ] crbug.com/1286944 [ Mac10.15 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/geometry-border-image-005.https.html [ Failure Pass ] crbug.com/1286944 [ Mac ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/hidpi/canvas-transform.https.html [ Failure Pass ] @@ -7379,9 +6558,7 @@ crbug.com/1286944 [ Mac10.15 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/paint2d-conicGradient.https.html [ Failure Pass ] crbug.com/1286944 [ Mac10.15 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/paint2d-gradient.https.html [ Failure Pass ] crbug.com/1286944 [ Mac11 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/paint2d-rects.https.html [ Failure Pass ] -crbug.com/1286944 [ Mac10.15 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/paint2d-transform.https.html [ Failure Pass ] crbug.com/1286944 [ Mac10.15 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/parse-input-arguments-002.https.html [ Failure Pass ] -crbug.com/1286944 [ Mac10.15 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/parse-input-arguments-003.https.html [ Failure ] crbug.com/1286944 [ Mac11 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/parse-input-arguments-009.https.html [ Failure Pass ] crbug.com/1286944 [ Mac10.15 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/parse-input-arguments-013.https.html [ Failure Pass ] crbug.com/1286944 [ Mac10.15 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/parse-input-arguments-017.https.html [ Failure Pass ] @@ -7392,13 +6569,9 @@ crbug.com/1286944 [ Mac10.15 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/registered-property-value-001.https.html [ Failure Pass ] crbug.com/1286944 [ Mac11 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/registered-property-value-001.https.html [ Failure Pass ] crbug.com/1286944 [ Mac11 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/registered-property-value-002.https.html [ Failure Pass ] -crbug.com/1286944 [ Mac10.15 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/registered-property-value-008.https.html [ Failure Pass ] crbug.com/1286944 [ Mac ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/registered-property-value-009.https.html [ Failure Pass ] -crbug.com/1286944 [ Mac10.15 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/registered-property-value-010.https.html [ Failure Pass ] -crbug.com/1286944 [ Mac10.15 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/registered-property-value-014.https.html [ Failure Pass ] crbug.com/1286944 [ Mac10.15 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/registered-property-value-016.https.html [ Failure Pass ] crbug.com/1286944 [ Mac10.15 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/setTransform-004.https.html [ Failure Pass ] -crbug.com/1286944 [ Mac10.15 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/two-custom-property-animation.https.html [ Failure Pass ] crbug.com/1250666 crbug.com/1286944 [ Mac ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/valid-image-before-load.https.html [ Failure Pass Timeout ] crbug.com/1250666 crbug.com/1286944 [ Mac ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/valid-image-after-load.https.html [ Failure Pass Timeout ] crbug.com/1286944 [ Mac10.15 ] virtual/off-main-thread-css-paint/external/wpt/css/css-paint-api/registered-property-interpolation-009.https.html [ Failure ] @@ -7416,12 +6589,7 @@ crbug.com/1288264 [ Win ] http/tests/fetch/serviceworker/thorough/nocors-base-https-other-https.html [ Pass Timeout ] crbug.com/1288264 [ Win ] http/tests/security/aboutBlank/xss-DENIED-navigate-opener-document-write.html [ Pass Timeout ] -# Flaky test on mac. -crbug.com/1282347 [ Mac ] virtual/clipboard-custom-formats/clipboard/async-clipboard/async-custom-formats-write-read.tentative.https.html [ Failure Pass ] -crbug.com/1282347 [ Mac ] virtual/clipboard-custom-formats/clipboard/async-clipboard/async-custom-format-write-read.tentative.https.html [ Failure Pass ] - # Flakiness of WIP MediaStreamTrack on workers. -crbug.com/1290767 external/wpt/mediacapture-insertable-streams/MediaStreamTrackGenerator-in-worker.https.html [ Crash Pass ] crbug.com/1290767 external/wpt/mediacapture-insertable-streams/MediaStreamTrackGenerator-pipes-data-in-worker.https.html [ Crash Pass ] crbug.com/1290976 external/wpt/mediacapture-insertable-streams/MediaStreamTrackGenerator-in-shared-worker.https.html [ Crash Pass ] crbug.com/1291850 external/wpt/mediacapture-insertable-streams/MediaStreamTrackGenerator-in-service-worker.https.html [ Crash Pass ] @@ -7505,9 +6673,6 @@ crbug.com/1297416 [ Linux Release ] virtual/fenced-frame-shadow-dom/http/tests/fenced_frame/coop-bcg-swap-rendering.https.html [ Failure Pass ] crbug.com/1297416 [ Release Win10.20h2 ] virtual/fenced-frame-shadow-dom/http/tests/fenced_frame/coop-bcg-swap-rendering.https.html [ Failure Pass ] -# Fails flakily on Win -crbug.com/1173382 [ Win ] virtual/stable/http/tests/navigation/replacestate-base-legal.html [ Failure Pass ] - # Sheriff 2022-02-22 crbug.com/1299858 [ Win ] http/tests/fetch/serviceworker-proxied/thorough/nocors-base-https-other-https.html [ Pass Timeout ] crbug.com/1299858 [ Win ] http/tests/fetch/serviceworker/thorough/redirect-nocors-base-https-other-https.html [ Pass Timeout ] @@ -7518,10 +6683,6 @@ crbug.com/1299948 [ Mac ] external/wpt/css/css-tables/crashtests/textarea-intrinsic-size-crash.html [ Pass Timeout ] crbug.com/1299972 [ Linux ] screen_orientation/screenorientation-unsupported-no-crash.html [ Failure Pass Timeout ] -# Until Plan B is removed on Fuchsia, allow these tests to fail to allow contradictory expectations. -crbug.com/1302249 [ Fuchsia ] external/wpt/webrtc/RTCPeerConnection-plan-b-is-not-supported.html [ Failure Pass ] -crbug.com/1302249 [ Fuchsia ] virtual/webrtc-wpt-plan-b/external/wpt/webrtc/RTCPeerConnection-plan-b-is-not-supported.html [ Failure Pass ] - # Disable flaky test for further investigation crbug.com/1229801 http/tests/devtools/elements/css-rule-hover-highlights-selectors.js [ Failure Pass ] @@ -7572,7 +6733,6 @@ # WebAudio flaky timeout (crbug.com/1307741) crbug.com/1307741 [ Mac ] external/wpt/webaudio/the-audio-api/the-mediastreamaudiosourcenode-interface/mediastreamaudiosourcenode-routing.html [ Timeout ] -crbug.com/1307741 external/wpt/webaudio/the-audio-api/the-pannernode-interface/pannernode-basic.html [ Timeout ] crbug.com/1307741 webaudio/AudioParam/audioparam-k-rate.html [ Timeout ] # WebAudio internals flaky GC (crbug.com/1312164) @@ -7625,7 +6785,6 @@ crbug.com/1312469 [ Mac10.12 ] external/wpt/hr-time/clamped-time-origin-isolated.https.html [ Skip ] crbug.com/1312469 [ Mac10.12 ] fast/forms/calendar-picker/date-picker-select-value-with-keyboard.html [ Skip ] crbug.com/1312469 [ Mac10.12 ] virtual/scroll-unification-prefer_compositing_to_lcd_text/fast/scroll-behavior/smooth-scroll/mousewheel-scroll.html [ Skip ] -crbug.com/1313476 [ Mac10.12 ] virtual/threaded-no-composited-antialiasing/animations/interpolation/svg-d-interpolation-001.html [ Failure Pass ] crbug.com/1312469 [ Mac10.12 ] virtual/fledge/http/tests/inspector-protocol/storage/interest-groups.js [ Skip ] crbug.com/1312469 [ Mac10.12 ] virtual/partitioned-cookies-first-party-sets/http/tests/inspector-protocol/network/blocked-setcookie-same-site-lax.js [ Skip ] crbug.com/1312469 [ Mac10.12 ] virtual/partitioned-cookies/http/tests/inspector-protocol/network/blocked-cookie-same-site-strict.js [ Skip ] @@ -7635,8 +6794,6 @@ crbug.com/1203491 [ Linux ] fast/events/touch/gesture/touch-gesture-scroll-listbox.html [ Failure Pass ] crbug.com/1203491 [ Win ] fast/events/touch/gesture/touch-gesture-scroll-listbox.html [ Failure Pass ] crbug.com/1313282 inspector-protocol/input/dispatchMouseEvent.js [ Skip ] -crbug.com/1313331 [ Mac10.13 ] virtual/compositor-threaded-percent-based-scrolling/fast/scrolling/subpixel-overflow-mouse-drag.html [ Failure Pass ] -crbug.com/1313331 [ Debug Linux ] virtual/compositor-threaded-percent-based-scrolling/fast/scrolling/subpixel-overflow-mouse-drag.html [ Failure Pass ] crbug.com/1095540 [ Mac ] virtual/compositor-threaded-percent-based-scrolling/fast/scrolling/resize-corner-tracking-touch.html [ Skip ] crbug.com/1254163 [ Mac10.12 ] ietestcenter/css3/bordersbackgrounds/background-attachment-local-scrolling.htm [ Failure ] crbug.com/1254163 [ Mac10.13 ] ietestcenter/css3/bordersbackgrounds/background-attachment-local-scrolling.htm [ Failure ] @@ -7739,7 +6896,6 @@ crbug.com/1267538 [ Mac ] http/tests/csspaint/border-color.html [ Failure Pass ] # Sheriff 2022-04-26 -crbug.com/1320120 [ Mac10.13 ] fast/harness/perftests/runs-per-second-log.html [ Failure Pass Timeout ] crbug.com/1320140 [ Win ] virtual/fenced-frame-mparch/wpt_internal/fenced_frame/disallowed-navigations.https.html [ Pass Timeout ] crbug.com/1320140 [ Win ] virtual/fenced-frame-mparch/wpt_internal/fenced_frame/opaque-ad-sizes.https.html [ Pass Timeout ] crbug.com/1320140 [ Win ] virtual/fenced-frame-shadow-dom/wpt_internal/fenced_frame/disallowed-navigations.https.html [ Pass Timeout ] @@ -7757,7 +6913,6 @@ # Sheriff 2022-05-02 crbug.com/1321293 fast/forms/calendar-picker/week-picker-choose-default-value-after-set-value.html [ Failure Pass ] crbug.com/1322072 [ Mac10.15 ] external/wpt/fetch/content-type/script.window.html [ Failure Pass ] -crbug.com/1322134 [ Mac11 ] virtual/gpu/fast/canvas/OffscreenCanvasImageRenderingPixelatedWorker.html [ Failure Pass ] # Sheriff 2022-05-04 crbug.com/1309533 [ Win ] virtual/threaded-prefer-compositing/external/wpt/css/cssom-view/idlharness.html [ Failure ]
diff --git a/third_party/blink/web_tests/external/wpt/css/css-contain/content-visibility/slot-content-visibility-22-crash.html b/third_party/blink/web_tests/external/wpt/css/css-contain/content-visibility/slot-content-visibility-22-crash.html new file mode 100644 index 0000000..c8b4935 --- /dev/null +++ b/third_party/blink/web_tests/external/wpt/css/css-contain/content-visibility/slot-content-visibility-22-crash.html
@@ -0,0 +1,9 @@ +<!DOCTYPE html> +<link rel=help href="https://bugs.chromium.org/p/chromium/issues/detail?id=1318401"> +<details> + <details style="column-count:5" open> + <select size="2"> + <option selected>text</option> + </select> + </details> +</details>
diff --git a/third_party/blink/web_tests/external/wpt/media-source/dedicated-worker/mediasource-message-util.js b/third_party/blink/web_tests/external/wpt/media-source/dedicated-worker/mediasource-message-util.js index f2682e3..247071db 100644 --- a/third_party/blink/web_tests/external/wpt/media-source/dedicated-worker/mediasource-message-util.js +++ b/third_party/blink/web_tests/external/wpt/media-source/dedicated-worker/mediasource-message-util.js
@@ -2,8 +2,14 @@ // and worker thread communication. const messageSubject = { - ERROR: "error", - OBJECT_URL: "object url", + ERROR: "error", // info field may contain more detail + OBJECT_URL: "object url", // info field contains object URL STARTED_BUFFERING: "started buffering", FINISHED_BUFFERING: "finished buffering", -} + VERIFY_DURATION: "verify duration", // info field contains expected duration + AWAIT_DURATION: "await duration", // wait for element duration to match the expected duration in the info field + VERIFY_HAVE_NOTHING: "verify have nothing readyState", + VERIFY_AT_LEAST_HAVE_METADATA: "verify readyState is at least HAVE_METADATA", + ACK_VERIFIED: "verified", // info field contains the message values that requested the verification + WORKER_DONE: "worker done", // this lets worker signal main to successfully end the test +};
diff --git a/third_party/blink/web_tests/external/wpt/media-source/dedicated-worker/mediasource-worker-duration.html b/third_party/blink/web_tests/external/wpt/media-source/dedicated-worker/mediasource-worker-duration.html new file mode 100644 index 0000000..2cb834a5 --- /dev/null +++ b/third_party/blink/web_tests/external/wpt/media-source/dedicated-worker/mediasource-worker-duration.html
@@ -0,0 +1,87 @@ +<!DOCTYPE html> +<html> +<title>Test MediaSource-in-Worker duration updates before and after HAVE_METADATA</title> +<script src="/resources/testharness.js"></script> +<script src="/resources/testharnessreport.js"></script> +<script src="mediasource-message-util.js"></script> +<body> +<script> + +function awaitDuration(t, video, worker, requestingMessage, expectedDuration) { + let durationAwaiter = t.step_func(() => { + if ((!Number.isNaN(expectedDuration) && video.duration === expectedDuration) || + (Number.isNaN(expectedDuration) && Number.isNaN(video.duration))) { + worker.postMessage({ subject: messageSubject.ACK_VERIFIED, info: requestingMessage }); + return; + } + + // Otherwise, wait for one or more 'durationchange' events to see if video + // eventually has the expectedDuration. + video.addEventListener('durationchange', durationAwaiter, { once: true }); + }); + + durationAwaiter(); +} + +async_test(t => { + // Fail fast if MSE-in-Workers is not supported. + assert_true(MediaSource.hasOwnProperty("canConstructInDedicatedWorker"), "MediaSource hasOwnProperty 'canConstructInDedicatedWorker'"); + assert_true(MediaSource.canConstructInDedicatedWorker, "MediaSource.canConstructInDedicatedWorker"); + + const video = document.createElement("video"); + document.body.appendChild(video); + video.onerror = t.unreached_func("video element error"); + video.onended = t.unreached_func("video element ended"); + assert_equals(video.duration, NaN, "initial video duration before attachment should be NaN"); + assert_equals(video.readyState, HTMLMediaElement.HAVE_NOTHING, "initial video readyState before attachment should be HAVE_NOTHING"); + + let worker = new Worker("mediasource-worker-duration.js"); + worker.onerror = t.step_func(e => { + assert_unreached("worker error: [" + e.filename + ":" + e.lineno + ":" + e.colno + ":" + e.error + ":" + e.message + "]"); + }); + worker.onmessage = t.step_func(e => { + let subject = e.data.subject; + assert_true(subject !== undefined, "message must have a subject field"); + switch (subject) { + case messageSubject.ERROR: + assert_unreached("Worker error: " + e.data.info); + break; + case messageSubject.OBJECT_URL: + const url = e.data.info; + assert_true(url.match(/^blob:.+/) !== null); + assert_equals(video.duration, NaN, "initial video duration before attachment should still be NaN"); + assert_equals(video.readyState, HTMLMediaElement.HAVE_NOTHING, + "initial video readyState before attachment should still be HAVE_NOTHING"); + video.src = url; + break; + case messageSubject.VERIFY_DURATION: + assert_equals(video.duration, e.data.info, "duration should match expectation"); + worker.postMessage({ subject: messageSubject.ACK_VERIFIED, info: e.data }); + break; + case messageSubject.AWAIT_DURATION: + awaitDuration(t, video, worker, e.data, e.data.info); + break; + case messageSubject.VERIFY_HAVE_NOTHING: + assert_equals(video.readyState, HTMLMediaElement.HAVE_NOTHING, "readyState should match expectation"); + worker.postMessage({ subject: messageSubject.ACK_VERIFIED, info: e.data }); + break; + case messageSubject.VERIFY_AT_LEAST_HAVE_METADATA: + assert_greater_than_equal(video.readyState, HTMLMediaElement.HAVE_METADATA, "readyState should match expectation"); + worker.postMessage({ subject: messageSubject.ACK_VERIFIED, info: e.data }); + break; + case messageSubject.WORKER_DONE: + // This test is a worker-driven set of verifications, and it will send + // this message when it is complete. See comment in the worker script + // that describes the phases of this test case. + assert_not_equals(video.src, "", "test should at least have set src."); + t.done(); + break; + default: + assert_unreached("Unexpected message subject: " + subject); + } + }); +}, "Test worker MediaSource duration updates before and after HAVE_METADATA"); + +</script> +</body> +</html>
diff --git a/third_party/blink/web_tests/external/wpt/media-source/dedicated-worker/mediasource-worker-duration.js b/third_party/blink/web_tests/external/wpt/media-source/dedicated-worker/mediasource-worker-duration.js new file mode 100644 index 0000000..8060594 --- /dev/null +++ b/third_party/blink/web_tests/external/wpt/media-source/dedicated-worker/mediasource-worker-duration.js
@@ -0,0 +1,290 @@ +importScripts("mediasource-worker-util.js"); + +// Note, we do not use testharness.js utilities within the worker context +// because it also communicates using postMessage to the main HTML document's +// harness, and would confuse the test case message parsing there. + +let util = new MediaSourceWorkerUtil(); +let sourceBuffer; + +// Phases of this test case, in sequence: +const testPhase = { + // Main thread verifies initial unattached HTMLMediaElement duration is NaN + // and readyState is HAVE_NOTHING, then starts this worker. + // This worker creates a MediaSource, verifies its initial duration + // is NaN, creates an object URL for the MediaSource and sends the URL to the + // main thread. + kInitial: "Initial", + + // Main thread receives object URL, re-verifies that the media element + // duration is still NaN and readyState is still HAVE_NOTHING, and then sets + // the URL as the src of the media element, eventually causing worker + // mediaSource 'onsourceopen' event dispatch. + kAttaching: "Awaiting sourceopen event that signals attachment is setup", + + kRequestNaNDurationCheck: + "Sending request to main thread to verify expected duration of the freshly setup attachment", + kConfirmNaNDurationResult: + "Checking that main thread correctly ACK'ed the freshly setup attachment's duration verification request", + + kRequestHaveNothingReadyStateCheck: + "Sending request to main thread to verify expected readyState of HAVE_NOTHING of the freshly setup attachment", + kConfirmHaveNothingReadyStateResult: + "Checking that main thread correctly ACK'ed the freshly setup attachment's readyState HAVE_NOTHING verification request", + + kRequestSetDurationCheck: + "Sending request to main thread to verify explicitly set duration before any media data has been appended", + kConfirmSetDurationResult: + "Checking that main thread correctly ACK'ed the duration verification request of explicitly set duration before any media data has been appended", + + kRequestHaveNothingReadyStateRecheck: + "Sending request to main thread to recheck that the readyState is still HAVE_NOTHING", + kConfirmHaveNothingReadyStateRecheckResult: + "Checking that main thread correctly ACK'ed the request to recheck readyState of HAVE_NOTHING", + + kRequestAwaitNewDurationCheck: + "Buffering media and then sending request to main thread to await duration reaching the expected value due to buffering", + kConfirmAwaitNewDurationResult: + "Checking that main thread correctly ACK'ed the request to await duration reaching the expected value due to buffering", + + kRequestAtLeastHaveMetadataReadyStateCheck: + "Sending request to main thread to verify expected readyState of at least HAVE_METADATA due to buffering", + kConfirmAtLeastHaveMetadataReadyStateResult: + "Checking that main thread correctly ACK'ed the request to verify expected readyState of at least HAVE_METADATA due to buffering", + +}; + +let phase = testPhase.kInitial; + +// Setup handler for receipt of attachment completion. +util.mediaSource.addEventListener("sourceopen", () => { + URL.revokeObjectURL(util.mediaSourceObjectUrl); + assert(phase === testPhase.kAttaching, "Unexpected sourceopen received by Worker mediaSource."); + phase = testPhase.kRequestNaNDurationCheck; + processPhase(); +}, { once : true }); + +// Setup handler for receipt of acknowledgement of successful verifications from +// main thread. |ackVerificationData| contains the round-tripped verification +// request that the main thread just sent, and is used in processPhase to ensure +// the ACK for this phase matched the request for verification. +let ackVerificationData; +onmessage = e => { + if (e.data === undefined || e.data.subject !== messageSubject.ACK_VERIFIED || e.data.info === undefined) { + postMessage({ + subject: messageSubject.ERROR, + info: "Invalid message received by Worker" + }); + return; + } + + ackVerificationData = e.data.info; + processPhase(/* isResponseToAck */ true); +}; + +processPhase(); + + +// Returns true if checks succeed, false otherwise. +function checkAckVerificationData(expectedRequest) { + + // Compares only subject and info fields. Uses logic similar to testharness.js's + // same_value(x,y) to correctly handle NaN, but doesn't distinguish +0 from -0. + function messageValuesEqual(m1, m2) { + if (m1.subject !== m1.subject) { + // NaN case + if (m2.subject === m2.subject) + return false; + } else if (m1.subject !== m2.subject) { + return false; + } + + if (m1.info !== m1.info) { + // NaN case + return (m2.info !== m2.info); + } + + return m1.info === m2.info; + } + + if (messageValuesEqual(expectedRequest, ackVerificationData)) { + ackVerificationData = undefined; + return true; + } + + postMessage({ + subject: messageSubject.ERROR, + info: "ACK_VERIFIED message from main thread was for a mismatching request for this phase. phase=[" + phase + + "], expected request that would produce ACK in this phase=[" + JSON.stringify(expectedRequest) + + "], actual request reported with the ACK=[" + JSON.stringify(ackVerificationData) + "]" + }); + + ackVerificationData = undefined; + return false; +} + +function bufferMediaAndSendDurationVerificationRequest() { + sourceBuffer = util.mediaSource.addSourceBuffer(util.mediaMetadata.type); + sourceBuffer.onerror = (err) => { + postMessage({ subject: messageSubject.ERROR, info: err }); + }; + sourceBuffer.onupdateend = () => { + // Sanity check the duration. + // Unnecessary for this buffering, except helps with test coverage. + var duration = util.mediaSource.duration; + if (isNaN(duration) || duration <= 0.0) { + postMessage({ + subject: messageSubject.ERROR, + info: "mediaSource.duration " + duration + " is not within expected range (0,1)" + }); + return; + } + + // Await the main thread media element duration matching the worker + // mediaSource duration. + postMessage(getAwaitCurrentDurationRequest()); + }; + + util.mediaLoadPromise.then(mediaData => { sourceBuffer.appendBuffer(mediaData); }, + err => { postMessage({ subject: messageSubject.ERROR, info: err }) }); +} + + +function getAwaitCurrentDurationRequest() { + // Sanity check that we have a numeric duration value now. + const dur = util.mediaSource.duration; + assert(!Number.isNaN(dur), "Unexpected NaN duration in worker"); + return { subject: messageSubject.AWAIT_DURATION, info: dur }; +} + +function assert(conditionBool, description) { + if (conditionBool !== true) { + postMessage({ + subject: messageSubject.ERROR, + info: "Current test phase [" + phase + "] failed worker assertion. " + description + }); + } +} + +function processPhase(isResponseToAck = false) { + assert(!isResponseToAck || (phase !== testPhase.kInitial && phase !== testPhase.kAttaching), + "Phase does not expect verification ack receipt from main thread"); + + // Some static request messages useful in transmission and ACK verification. + const nanDurationCheckRequest = { subject: messageSubject.VERIFY_DURATION, info: NaN }; + const haveNothingReadyStateCheckRequest = { subject: messageSubject.VERIFY_HAVE_NOTHING }; + const setDurationCheckRequest = { subject: messageSubject.AWAIT_DURATION, info: 0.1 }; + const atLeastHaveMetadataReadyStateCheckRequest = { subject: messageSubject.VERIFY_AT_LEAST_HAVE_METADATA }; + + switch (phase) { + + case testPhase.kInitial: + assert(Number.isNaN(util.mediaSource.duration), "Initial unattached MediaSource duration must be NaN, but instead is " + util.mediaSource.duration); + phase = testPhase.kAttaching; + postMessage({ subject: messageSubject.OBJECT_URL, info: util.mediaSourceObjectUrl }); + break; + + case testPhase.kAttaching: + postMessage({ + subject: messageSubject.ERROR, + info: "kAttaching phase is handled by main thread and by worker onsourceopen, not this switch case." + }); + break; + + case testPhase.kRequestNaNDurationCheck: + assert(!isResponseToAck); + postMessage(nanDurationCheckRequest); + phase = testPhase.kConfirmNaNDurationResult; + break; + + case testPhase.kConfirmNaNDurationResult: + assert(isResponseToAck); + if (checkAckVerificationData(nanDurationCheckRequest)) { + phase = testPhase.kRequestHaveNothingReadyStateCheck; + processPhase(); + } + break; + + case testPhase.kRequestHaveNothingReadyStateCheck: + assert(!isResponseToAck); + postMessage(haveNothingReadyStateCheckRequest); + phase = testPhase.kConfirmHaveNothingReadyStateResult; + break; + + case testPhase.kConfirmHaveNothingReadyStateResult: + assert(isResponseToAck); + if (checkAckVerificationData(haveNothingReadyStateCheckRequest)) { + phase = testPhase.kRequestSetDurationCheck; + processPhase(); + } + break; + + case testPhase.kRequestSetDurationCheck: + assert(!isResponseToAck); + const newDuration = setDurationCheckRequest.info; + assert(!Number.isNaN(newDuration) && newDuration > 0); + + // Set the duration, then request verification. + util.mediaSource.duration = newDuration; + postMessage(setDurationCheckRequest); + phase = testPhase.kConfirmSetDurationResult; + break; + + case testPhase.kConfirmSetDurationResult: + assert(isResponseToAck); + if (checkAckVerificationData(setDurationCheckRequest)) { + phase = testPhase.kRequestHaveNothingReadyStateRecheck; + processPhase(); + } + break; + + case testPhase.kRequestHaveNothingReadyStateRecheck: + assert(!isResponseToAck); + postMessage(haveNothingReadyStateCheckRequest); + phase = testPhase.kConfirmHaveNothingReadyStateRecheckResult; + break; + + case testPhase.kConfirmHaveNothingReadyStateRecheckResult: + assert(isResponseToAck); + if (checkAckVerificationData(haveNothingReadyStateCheckRequest)) { + phase = testPhase.kRequestAwaitNewDurationCheck; + processPhase(); + } + break; + + case testPhase.kRequestAwaitNewDurationCheck: + assert(!isResponseToAck); + bufferMediaAndSendDurationVerificationRequest(); + phase = testPhase.kConfirmAwaitNewDurationResult; + break; + + case testPhase.kConfirmAwaitNewDurationResult: + assert(isResponseToAck); + if (checkAckVerificationData(getAwaitCurrentDurationRequest())) { + phase = testPhase.kRequestAtLeastHaveMetadataReadyStateCheck; + processPhase(); + } + break; + + case testPhase.kRequestAtLeastHaveMetadataReadyStateCheck: + assert(!isResponseToAck); + postMessage(atLeastHaveMetadataReadyStateCheckRequest); + phase = testPhase.kConfirmAtLeastHaveMetadataReadyStateResult; + break; + + case testPhase.kConfirmAtLeastHaveMetadataReadyStateResult: + assert(isResponseToAck); + if (checkAckVerificationData(atLeastHaveMetadataReadyStateCheckRequest)) { + postMessage({ subject: messageSubject.WORKER_DONE }); + } + phase = "No further phase processing should occur once WORKER_DONE message has been sent"; + break; + + default: + postMessage({ + subject: messageSubject.ERROR, + info: "Unexpected test phase in worker:" + phase, + }); + } + +}
diff --git a/third_party/blink/web_tests/external/wpt/pointerevents/pointerevent_touch-action-modified_touch.html b/third_party/blink/web_tests/external/wpt/pointerevents/pointerevent_touch-action-modified_touch.html new file mode 100644 index 0000000..c53264d --- /dev/null +++ b/third_party/blink/web_tests/external/wpt/pointerevents/pointerevent_touch-action-modified_touch.html
@@ -0,0 +1,60 @@ +<!doctype html> +<html> + <head> + <title>Deleting touch-action elem after pointerdown has no effect</title> + <meta name="viewport" content="width=device-width"> + <link rel="stylesheet" type="text/css" href="pointerevent_styles.css"> + <script src="/resources/testharness.js"></script> + <script src="/resources/testharnessreport.js"></script> + <script src="/resources/testdriver.js"></script> + <script src="/resources/testdriver-actions.js"></script> + <script src="/resources/testdriver-vendor.js"></script> + <script src="pointerevent_support.js"></script> + <style> + div.box { + margin: 10px; + height: 25vh; + border: 1px solid black; + } + #target { + background-color: lightgreen; + touch-action:none; + } + </style> + </head> + <body> + <h1>Deleting touch-action elem after pointerdown has no effect</h1> + <h4 id="desc"> + Try to scroll up/down starting at the green element. Expectation: the + green element would vanish immediately and the content won't scroll. + </h4> + <p>Note: this test is for touch-devices only</p> + <div class="box"></div> + <div class="box"></div> + <div class="box" id="target">Drag up or down from here</div> + <div class="box"></div> + <div class="box"></div> + </body> + <script> + let target = document.getElementById("target"); + let pointercancel_received = false; + + document.body.addEventListener("pointerdown", () => target.parentElement.removeChild(target)); + document.body.addEventListener("pointercancel", () => pointercancel_received = true); + + var detected_pointertypes = {}; + add_completion_callback(showPointerTypes); + + promise_test(async () => { + let pointerup_event = getEvent("pointerup", document.body); + + await touchScrollInTarget(target, "down"); + await pointerup_event; + + assert_false(pointercancel_received, + "a pointercancel event is unexpected because there should be no scrolling"); + + updateDescriptionComplete(); + }, "Deleting touch-action elem after pointerdown"); + </script> +</html>
diff --git a/third_party/blink/web_tests/fast/scrolling/scrollbars/mouse-scrolling-on-div-scrollbar-thumb.html b/third_party/blink/web_tests/fast/scrolling/scrollbars/mouse-scrolling-on-div-scrollbar-thumb.html index 0c9ad8e8..b1d16ec 100644 --- a/third_party/blink/web_tests/fast/scrolling/scrollbars/mouse-scrolling-on-div-scrollbar-thumb.html +++ b/third_party/blink/web_tests/fast/scrolling/scrollbars/mouse-scrolling-on-div-scrollbar-thumb.html
@@ -45,13 +45,16 @@ const SCROLL_CORNER = TRACK_WIDTH; const SCROLL_DELTA = 50; - promise_test (async () => { + async function testNonScrolls() { await waitForCompositorCommit(); resetScrollOffset(standardDivFast); + // Direction: rtl changes the x-wise position of the vertical scrollbar + const rtl = standardDivFast.style.direction === "rtl"; + // Testing the vertical scrollbar thumb. - let x = standardRectFast.right - TRACK_WIDTH / 2; - let y = standardRectFast.top + (platform == "mac" ? 0 : BUTTON_WIDTH) + 2; + const x = rtl ? standardRectFast.left + TRACK_WIDTH / 2 : standardRectFast.right - TRACK_WIDTH / 2; + const y = standardRectFast.top + (platform == "mac" ? 0 : BUTTON_WIDTH) + 2; await mouseMoveTo(x, y); await mouseDownAt(x, y); @@ -64,14 +67,17 @@ assert_equals(standardDivFast.scrollTop, 0, "Vertical thumb drag beyond the track and back should not cause a scroll."); await mouseUpAt(x, y); - }, "Test thumb drags beyond scrollbar track."); + } - promise_test (async () => { + async function testThumbScrolls() { await waitForCompositorCommit(); resetScrollOffset(standardDivFast); + // Direction: rtl changes the x-wise position of the vertical scrollbar + const rtl = standardDivFast.style.direction === "rtl"; + // Testing the vertical scrollbar thumb. - let x = standardRectFast.right - TRACK_WIDTH / 2; + let x = rtl ? standardRectFast.left + TRACK_WIDTH / 2 : standardRectFast.right - TRACK_WIDTH / 2; let y = standardRectFast.top + (platform == "mac" ? 0 : BUTTON_WIDTH) + 2; let asc_increments = [15, 10, 7, 6, 2]; let asc_offsets = {linux: [549, 915, 915, 915, 915], win: [361, 601, 770, 915, 915], mac: [211, 351, 450, 534, 563]}[platform]; @@ -103,6 +109,24 @@ // Since the horizontal scrolling is essentially the same codepath as vertical, // this need not be tested in the interest of making the test run faster. - }, "Test mouse drags in intervals on non-custom composited div scrollbar thumb."); + } + + function ltr(test) { + return async function () { + standardDivFast.style.direction = "ltr"; + await test(); + }; + } + function rtl(test) { + return async function () { + standardDivFast.style.direction = "rtl"; + await test(); + }; + } + + promise_test(ltr(testNonScrolls), "Test thumb drags beyond scrollbar track."); + promise_test(ltr(testThumbScrolls), "Test mouse drags in intervals on non-custom composited div scrollbar thumb."); + promise_test(rtl(testNonScrolls), "Test thumb drags beyond scrollbar track. (RTL)"); + promise_test(rtl(testThumbScrolls), "Test mouse drags in intervals on non-custom composited div scrollbar thumb. (RTL)"); } </script>
diff --git a/third_party/blink/web_tests/fast/scrolling/scrollbars/mouse-scrolling-on-div-scrollbar.html b/third_party/blink/web_tests/fast/scrolling/scrollbars/mouse-scrolling-on-div-scrollbar.html index bb63248..dee2967e 100644 --- a/third_party/blink/web_tests/fast/scrolling/scrollbars/mouse-scrolling-on-div-scrollbar.html +++ b/third_party/blink/web_tests/fast/scrolling/scrollbars/mouse-scrolling-on-div-scrollbar.html
@@ -43,7 +43,7 @@ "This test assumes that the height and width of 'standardDivFast' are equivalent. If this changes please update SCROLL_AMOUNT to be X/Y specific"); const SCROLL_AMOUNT = getScrollbarButtonScrollDelta(standardDivFast).y; - promise_test (async () => { + async function testArrows() { // Scrollbars on Mac don't have arrows. This test is irrelevant. if(navigator.userAgent.includes("Mac OS X")) return; @@ -51,67 +51,120 @@ await waitForCompositorCommit(); resetScrollOffset(standardDivFast); + // For testing on RTL divs, two things are different. The vertical scrollbar is on the opposite side, + // including the scroll corner. Horizontal scrolling on RTL starts at 0 for the rightmost position + // and counts downwards into the negatives. + const rtl = standardDivFast.style.direction === "rtl"; + // Click on the Down arrow for standardRectFast. - let x = standardRectFast.right - BUTTON_WIDTH / 2; + let x = rtl ? standardRectFast.left + BUTTON_WIDTH / 2 : standardRectFast.right - BUTTON_WIDTH / 2; let y = standardRectFast.bottom - SCROLL_CORNER - BUTTON_WIDTH / 2; await mouseClickOn(x, y); await waitForAnimationEndTimeBased(() => {return standardDivFast.scrollTop;}); assert_equals(standardDivFast.scrollTop, SCROLL_AMOUNT, "Pressing the down arrow didn't scroll."); // Click on the Up arrow for standardRectFast. - x = standardRectFast.right - BUTTON_WIDTH / 2; + x = rtl ? standardRectFast.left + BUTTON_WIDTH / 2 : standardRectFast.right - BUTTON_WIDTH / 2; y = standardRectFast.top + BUTTON_WIDTH / 2; await mouseClickOn(x, y); await waitForAnimationEndTimeBased(() => {return standardDivFast.scrollTop;}); assert_equals(standardDivFast.scrollTop, 0, "Pressing the up arrow didn't scroll."); - // Click on the Right arrow for standardRectFast. - x = standardRectFast.right - SCROLL_CORNER - BUTTON_WIDTH / 2; - y = standardRectFast.bottom - BUTTON_WIDTH / 2; - await mouseClickOn(x, y); - await waitForAnimationEndTimeBased(() => {return standardDivFast.scrollLeft;}); - assert_equals(standardDivFast.scrollLeft, SCROLL_AMOUNT, "Pressing the right arrow didn't scroll."); + async function scrollRight() { + // Click on the Right arrow for standardRectFast. + x = rtl ? standardRectFast.right - BUTTON_WIDTH / 2 : standardRectFast.right - SCROLL_CORNER - BUTTON_WIDTH / 2; + y = standardRectFast.bottom - BUTTON_WIDTH / 2; + await mouseClickOn(x, y); + await waitForAnimationEndTimeBased(() => {return standardDivFast.scrollLeft;}); + assert_equals(standardDivFast.scrollLeft, rtl ? 0 : SCROLL_AMOUNT, "Pressing the right arrow didn't scroll."); + } - // Click on the Left arrow for standardRectFast. - x = standardRectFast.left + BUTTON_WIDTH / 2; - y = standardRectFast.bottom - BUTTON_WIDTH / 2; - await mouseClickOn(x, y); - await waitForAnimationEndTimeBased(() => {return standardDivFast.scrollLeft;}); - assert_equals(standardDivFast.scrollLeft, 0, "Pressing the left arrow didn't scroll."); - }, "Test mouse click on non-custom composited div scrollbar arrows."); + async function scrollLeft() { + // Click on the Left arrow for standardRectFast. + x = rtl ? standardRectFast.left + SCROLL_CORNER + BUTTON_WIDTH / 2 : standardRectFast.left + BUTTON_WIDTH / 2; + y = standardRectFast.bottom - BUTTON_WIDTH / 2; + await mouseClickOn(x, y); + await waitForAnimationEndTimeBased(() => {return standardDivFast.scrollLeft;}); + assert_equals(standardDivFast.scrollLeft, rtl ? -SCROLL_AMOUNT : 0, "Pressing the left arrow didn't scroll."); + } - promise_test (async () => { + //For RTL, horizontal scrollbar starts on the rightmost position, so we need to scroll left first; + if (rtl) { + await scrollLeft(); + await scrollRight(); + } else { + await scrollRight(); + await scrollLeft(); + } + }; // + + async function testTrackparts() { await waitForCompositorCommit(); resetScrollOffset(standardDivFast); + // For testing on RTL divs, two things are different. The vertical scrollbar is on the opposite side, + // including the scroll corner. Horizontal scrolling on RTL starts at 0 for the rightmost position + // and counts downwards into the negatives. + const rtl = standardDivFast.style.direction === "rtl"; + // Click on the track part just above the down arrow. assert_equals(standardDivFast.scrollTop, 0, "Div is not at 0 offset."); - let x = standardRectFast.right - BUTTON_WIDTH / 2; + let x = rtl ? standardRectFast.left + BUTTON_WIDTH / 2 : standardRectFast.right - BUTTON_WIDTH / 2; let y = standardRectFast.bottom - SCROLL_CORNER - BUTTON_WIDTH - 2; await mouseClickOn(x, y); await waitForAnimationEndTimeBased(() => {return standardDivFast.scrollTop;}); assert_approx_equals(standardDivFast.scrollTop, 74, 1, "Pressing the down trackpart didn't scroll."); // Click on the track part just below the up arrow. - x = standardRectFast.right - BUTTON_WIDTH / 2; + x = rtl ? standardRectFast.left + BUTTON_WIDTH / 2 : standardRectFast.right - BUTTON_WIDTH / 2; y = standardRectFast.top + BUTTON_WIDTH + 2; await mouseClickOn(x, y); await waitForAnimationEndTimeBased(() => {return standardDivFast.scrollTop;}); assert_equals(standardDivFast.scrollTop, 0, "Pressing the up trackpart didn't scroll."); - // Click on the track part just to the left of the right arrow. - x = standardRectFast.right - SCROLL_CORNER - BUTTON_WIDTH - 2; - y = standardRectFast.bottom - BUTTON_WIDTH / 2; - await mouseClickOn(x, y); - await waitForAnimationEndTimeBased(() => {return standardDivFast.scrollLeft;}); - assert_approx_equals(standardDivFast.scrollLeft, 74, 1, "Pressing the right trackpart didn't scroll."); + async function scrollRight() { + // Click on the track part just to the left of the right arrow. + x = rtl ? standardRectFast.right - BUTTON_WIDTH - 2 : standardRectFast.right - SCROLL_CORNER - BUTTON_WIDTH - 2; + y = standardRectFast.bottom - BUTTON_WIDTH / 2; + await mouseClickOn(x, y); + await waitForAnimationEndTimeBased(() => {return standardDivFast.scrollLeft;}); + assert_approx_equals(standardDivFast.scrollLeft, rtl ? 0 : 74, 1, "Pressing the right trackpart didn't scroll."); + } - // Click on the track part just to the right of the left arrow. - x = standardRectFast.left + BUTTON_WIDTH + 2; - y = standardRectFast.bottom - BUTTON_WIDTH / 2; - await mouseClickOn(x, y); - await waitForAnimationEndTimeBased(() => {return standardDivFast.scrollLeft;}); - assert_equals(standardDivFast.scrollLeft, 0, "Pressing the left trackpart didn't scroll."); - }, "Test mouse click on non-custom composited div scrollbar empty trackparts."); + async function scrollLeft() { + // Click on the track part just to the right of the left arrow. + x = rtl ? standardRectFast.left + SCROLL_CORNER + BUTTON_WIDTH + 2 : standardRectFast.left + BUTTON_WIDTH + 2; + y = standardRectFast.bottom - BUTTON_WIDTH / 2; + await mouseClickOn(x, y); + await waitForAnimationEndTimeBased(() => {return standardDivFast.scrollLeft;}); + assert_approx_equals(standardDivFast.scrollLeft, rtl ? -74 : 0, 1, "Pressing the left trackpart didn't scroll."); + } + + if (rtl) { + await scrollLeft(); + await scrollRight(); + } else { + await scrollRight(); + await scrollLeft(); + } + }// "Test mouse click on non-custom composited div scrollbar empty trackparts."); + + function ltr(test) { + return async function () { + standardDivFast.style.direction = "ltr"; + await test(); + }; + } + function rtl(test) { + return async function () { + standardDivFast.style.direction = "rtl"; + await test(); + }; + } + + promise_test(ltr(testArrows), "Test mouse click on non-custom composited div scrollbar arrows."); + promise_test(ltr(testTrackparts), "Test mouse click on non-custom composited div scrollbar empty trackparts."); + promise_test(rtl(testArrows), "Test mouse click on non-custom composited div scrollbar arrows. (RTL)"); + promise_test(rtl(testTrackparts), "Test mouse click on non-custom composited div scrollbar empty trackparts. (RTL)"); } </script>
diff --git a/third_party/blink/web_tests/platform/mac-mac10.14/external/wpt/scheduler/post-task-with-abort-signal-in-handler.any-expected.txt b/third_party/blink/web_tests/platform/mac-mac10.14/external/wpt/scheduler/post-task-with-abort-signal-in-handler.any-expected.txt deleted file mode 100644 index 3b8e8a0..0000000 --- a/third_party/blink/web_tests/platform/mac-mac10.14/external/wpt/scheduler/post-task-with-abort-signal-in-handler.any-expected.txt +++ /dev/null
@@ -1,5 +0,0 @@ -This is a testharness.js-based test. -PASS Posting a task with a signal and abort the signal when running the sync callback -FAIL Posting a task with a signal and abort the signal when running the async callback assert_unreached: Should have rejected: undefined Reached unreachable code -Harness: the test ran to completion. -
diff --git a/third_party/blink/web_tests/platform/mac-mac10.14/external/wpt/scheduler/post-task-with-abort-signal-in-handler.any.serviceworker-expected.txt b/third_party/blink/web_tests/platform/mac-mac10.14/external/wpt/scheduler/post-task-with-abort-signal-in-handler.any.serviceworker-expected.txt deleted file mode 100644 index 3b8e8a0..0000000 --- a/third_party/blink/web_tests/platform/mac-mac10.14/external/wpt/scheduler/post-task-with-abort-signal-in-handler.any.serviceworker-expected.txt +++ /dev/null
@@ -1,5 +0,0 @@ -This is a testharness.js-based test. -PASS Posting a task with a signal and abort the signal when running the sync callback -FAIL Posting a task with a signal and abort the signal when running the async callback assert_unreached: Should have rejected: undefined Reached unreachable code -Harness: the test ran to completion. -
diff --git a/third_party/blink/web_tests/platform/mac-mac10.14/external/wpt/scheduler/post-task-with-abort-signal-in-handler.any.sharedworker-expected.txt b/third_party/blink/web_tests/platform/mac-mac10.14/external/wpt/scheduler/post-task-with-abort-signal-in-handler.any.sharedworker-expected.txt deleted file mode 100644 index 3b8e8a0..0000000 --- a/third_party/blink/web_tests/platform/mac-mac10.14/external/wpt/scheduler/post-task-with-abort-signal-in-handler.any.sharedworker-expected.txt +++ /dev/null
@@ -1,5 +0,0 @@ -This is a testharness.js-based test. -PASS Posting a task with a signal and abort the signal when running the sync callback -FAIL Posting a task with a signal and abort the signal when running the async callback assert_unreached: Should have rejected: undefined Reached unreachable code -Harness: the test ran to completion. -
diff --git a/third_party/blink/web_tests/platform/mac-mac10.14/external/wpt/scheduler/post-task-with-abort-signal-in-handler.any.worker-expected.txt b/third_party/blink/web_tests/platform/mac-mac10.14/external/wpt/scheduler/post-task-with-abort-signal-in-handler.any.worker-expected.txt deleted file mode 100644 index 3b8e8a0..0000000 --- a/third_party/blink/web_tests/platform/mac-mac10.14/external/wpt/scheduler/post-task-with-abort-signal-in-handler.any.worker-expected.txt +++ /dev/null
@@ -1,5 +0,0 @@ -This is a testharness.js-based test. -PASS Posting a task with a signal and abort the signal when running the sync callback -FAIL Posting a task with a signal and abort the signal when running the async callback assert_unreached: Should have rejected: undefined Reached unreachable code -Harness: the test ran to completion. -
diff --git a/third_party/unrar/README.chromium b/third_party/unrar/README.chromium index 1aefd1a..bddb93d 100644 --- a/third_party/unrar/README.chromium +++ b/third_party/unrar/README.chromium
@@ -32,5 +32,6 @@ - Fix a bug with NOVOLUME implementation (https://crbug.com/949787). This should be temporary, until the fix can be pulled from upstream. - More static initializers removed. +- Changes to support building in -std=c++20 mode. All these changes are included in one patch file (chromium_changes.v6.0.3.patch)
diff --git a/third_party/unrar/patches/chromium_changes.v6.0.3.patch b/third_party/unrar/patches/chromium_changes.v6.0.3.patch index 9829c783..2c98ab5 100644 --- a/third_party/unrar/patches/chromium_changes.v6.0.3.patch +++ b/third_party/unrar/patches/chromium_changes.v6.0.3.patch
@@ -1,5 +1,5 @@ diff --git a/third_party/unrar/src/archive.cpp b/third_party/unrar/src/archive.cpp -index 8c5a1da81d14239cb363146cdee7620fc02c318b..cac841747d867bd82ff91fb43e52fe2bf758b864 100644 +index 8c5a1da81d142..cac841747d867 100644 --- a/third_party/unrar/src/archive.cpp +++ b/third_party/unrar/src/archive.cpp @@ -336,3 +336,12 @@ int64 Archive::Tell() @@ -16,7 +16,7 @@ +} +#endif diff --git a/third_party/unrar/src/archive.hpp b/third_party/unrar/src/archive.hpp -index d9518f1dc491a225c61eb82a47285fa0b0ade8cd..08fef7b0e6c0ec066cd0133b5072891e2b43ac94 100644 +index d9518f1dc491a..08fef7b0e6c0e 100644 --- a/third_party/unrar/src/archive.hpp +++ b/third_party/unrar/src/archive.hpp @@ -57,6 +57,13 @@ class Archive:public File @@ -45,7 +45,7 @@ BaseBlock ShortBlock; MarkHeader MarkHead; diff --git a/third_party/unrar/src/arcread.cpp b/third_party/unrar/src/arcread.cpp -index d1df6c04108cddcf18af7058046a0468f627f72c..468d387a24721b651fde2745dd6c2434d9a140e0 100644 +index d1df6c04108cd..468d387a24721 100644 --- a/third_party/unrar/src/arcread.cpp +++ b/third_party/unrar/src/arcread.cpp @@ -142,7 +142,8 @@ size_t Archive::ReadHeader15() @@ -67,8 +67,39 @@ return 0; #else +diff --git a/third_party/unrar/src/blake2s.hpp b/third_party/unrar/src/blake2s.hpp +index f88ef37802c44..d8b30f94d0518 100644 +--- a/third_party/unrar/src/blake2s.hpp ++++ b/third_party/unrar/src/blake2s.hpp +@@ -5,11 +5,8 @@ + #define BLAKE2_DIGEST_SIZE 32 + #define BLAKE2_THREADS_NUMBER 8 + +-enum blake2s_constant +-{ +- BLAKE2S_BLOCKBYTES = 64, +- BLAKE2S_OUTBYTES = 32 +-}; ++constexpr size_t BLAKE2S_BLOCKBYTES = 64; ++constexpr size_t BLAKE2S_OUTBYTES = 32; + + + // Alignment to 64 improves performance of both SSE and non-SSE versions. +@@ -20,10 +17,10 @@ enum blake2s_constant + // 'new' operator. + struct blake2s_state + { +- enum { BLAKE_ALIGNMENT = 64 }; ++ static constexpr size_t BLAKE_ALIGNMENT = 64; + + // buffer and uint32 h[8], t[2], f[2]; +- enum { BLAKE_DATA_SIZE = 48 + 2 * BLAKE2S_BLOCKBYTES }; ++ static constexpr size_t BLAKE_DATA_SIZE = 48 + 2 * BLAKE2S_BLOCKBYTES; + + byte ubuf[BLAKE_DATA_SIZE + BLAKE_ALIGNMENT]; + diff --git a/third_party/unrar/src/crc.cpp b/third_party/unrar/src/crc.cpp -index cf23bbf4f2afa61f1d17ac854d73a1a1452a4e43..4c86c09e3b4f20c37e75140f755811ec476fd5b0 100644 +index cf23bbf4f2afa..4c86c09e3b4f2 100644 --- a/third_party/unrar/src/crc.cpp +++ b/third_party/unrar/src/crc.cpp @@ -15,6 +15,7 @@ @@ -96,7 +127,7 @@ // Align Data to 8 for better performance. diff --git a/third_party/unrar/src/errhnd.cpp b/third_party/unrar/src/errhnd.cpp -index 18e91973e61b7569b5cbf5f5e7b22e4b90452bac..ddbc751b57f8635f5985d076bed916b13c7c576f 100644 +index 18e91973e61b7..ddbc751b57f86 100644 --- a/third_party/unrar/src/errhnd.cpp +++ b/third_party/unrar/src/errhnd.cpp @@ -1,10 +1,13 @@ @@ -131,7 +162,7 @@ diff --git a/third_party/unrar/src/errhnd.hpp b/third_party/unrar/src/errhnd.hpp -index 06f4f616fd96b620ce717f072c0f34d42dd8f59f..3c5c54c490f7ae9b8b2cc30f2d8e04c15bccc398 100644 +index 06f4f616fd96b..3c5c54c490f7a 100644 --- a/third_party/unrar/src/errhnd.hpp +++ b/third_party/unrar/src/errhnd.hpp @@ -23,14 +23,13 @@ enum RAR_EXIT // RAR exit code. @@ -167,7 +198,7 @@ diff --git a/third_party/unrar/src/extract.cpp b/third_party/unrar/src/extract.cpp -index abcd3c3385c5db501402ab91b79efb7a9eb6c3d7..2c264b107040130d2d4fd8172d4a34e52dee2a24 100644 +index abcd3c3385c5d..2c264b1070401 100644 --- a/third_party/unrar/src/extract.cpp +++ b/third_party/unrar/src/extract.cpp @@ -524,6 +524,11 @@ bool CmdExtract::ExtractCurrentFile(Archive &Arc,size_t HeaderSize,bool &Repeat) @@ -190,7 +221,7 @@ \ No newline at end of file +#endif diff --git a/third_party/unrar/src/extract.hpp b/third_party/unrar/src/extract.hpp -index 159759b563f5f056e647b2e2e63f1162cdf118af..9a659591d4f3578061c45bbbdb055d439b44a0a6 100644 +index 159759b563f5f..9a659591d4f35 100644 --- a/third_party/unrar/src/extract.hpp +++ b/third_party/unrar/src/extract.hpp @@ -37,8 +37,8 @@ class CmdExtract @@ -216,7 +247,7 @@ #endif diff --git a/third_party/unrar/src/file.cpp b/third_party/unrar/src/file.cpp -index 5a8099ec5bd1c8a8cb5b2d1a78d58df655d01948..cd6be338e486f4376ce4df9c34b9ca0553ccd21a 100644 +index 5a8099ec5bd1c..cd6be338e486f 100644 --- a/third_party/unrar/src/file.cpp +++ b/third_party/unrar/src/file.cpp @@ -19,6 +19,10 @@ File::File() @@ -314,7 +345,7 @@ +} +#endif // defined(CHROMIUM_UNRAR) diff --git a/third_party/unrar/src/file.hpp b/third_party/unrar/src/file.hpp -index 1c436d4ef7bc0c9df6b468caf651e9bc2ec1f9da..baf366dfa4a34b2691bca999a4704f66e7ce0a7f 100644 +index 1c436d4ef7bc0..baf366dfa4a34 100644 --- a/third_party/unrar/src/file.hpp +++ b/third_party/unrar/src/file.hpp @@ -76,6 +76,10 @@ class File @@ -343,8 +374,35 @@ #ifdef _UNIX int GetFD() { +diff --git a/third_party/unrar/src/hash.cpp b/third_party/unrar/src/hash.cpp +index a4559e05c3cce..106cc6083333e 100644 +--- a/third_party/unrar/src/hash.cpp ++++ b/third_party/unrar/src/hash.cpp +@@ -26,7 +26,7 @@ void HashValue::Init(HASH_TYPE Type) + } + + +-bool HashValue::operator == (const HashValue &cmp) ++bool HashValue::operator == (const HashValue &cmp) const + { + if (Type==HASH_NONE || cmp.Type==HASH_NONE) + return true; +diff --git a/third_party/unrar/src/hash.hpp b/third_party/unrar/src/hash.hpp +index b7d879f66a280..923260064f894 100644 +--- a/third_party/unrar/src/hash.hpp ++++ b/third_party/unrar/src/hash.hpp +@@ -6,8 +6,7 @@ enum HASH_TYPE {HASH_NONE,HASH_RAR14,HASH_CRC32,HASH_BLAKE2}; + struct HashValue + { + void Init(HASH_TYPE Type); +- bool operator == (const HashValue &cmp); +- bool operator != (const HashValue &cmp) {return !(*this==cmp);} ++ bool operator == (const HashValue &cmp) const; + + HASH_TYPE Type; + union diff --git a/third_party/unrar/src/isnt.cpp b/third_party/unrar/src/isnt.cpp -index 6fadec049fe4cf9865c41c6dce8d6c459b6cd184..d30adf550925f90492a602d2dc1a757465a0bdcf 100644 +index 6fadec049fe4c..d30adf550925f 100644 --- a/third_party/unrar/src/isnt.cpp +++ b/third_party/unrar/src/isnt.cpp @@ -1,24 +1,18 @@ @@ -384,7 +442,7 @@ } #endif diff --git a/third_party/unrar/src/isnt.hpp b/third_party/unrar/src/isnt.hpp -index 85790da462902fe88c6bc2ba0364b57e1e343ebb..a02174447e29fd2f248c0f37f748c8df85445d02 100644 +index 85790da462902..a02174447e29f 100644 --- a/third_party/unrar/src/isnt.hpp +++ b/third_party/unrar/src/isnt.hpp @@ -1,6 +1,8 @@ @@ -403,7 +461,7 @@ - #endif diff --git a/third_party/unrar/src/model.cpp b/third_party/unrar/src/model.cpp -index 83391c5a45107e2c68d3d990946f7f0426e5a542..1ca9f03e9bcc54c1febbe5fb1820a312739b1ed0 100644 +index 83391c5a45107..1ca9f03e9bcc5 100644 --- a/third_party/unrar/src/model.cpp +++ b/third_party/unrar/src/model.cpp @@ -43,13 +43,27 @@ void ModelPPM::RestartModelRare() @@ -435,7 +493,7 @@ { MinContext->U.Stats[i].Symbol=i; diff --git a/third_party/unrar/src/os.hpp b/third_party/unrar/src/os.hpp -index b69f34878b3dff1acea25635ce44958f8784b01b..51d547b0f68ba0840bcf37d9ace64a2a424acedf 100644 +index b69f34878b3df..51d547b0f68ba 100644 --- a/third_party/unrar/src/os.hpp +++ b/third_party/unrar/src/os.hpp @@ -32,6 +32,7 @@ @@ -476,7 +534,7 @@ #include <dirent.h> #endif // _MSC_VER diff --git a/third_party/unrar/src/secpassword.cpp b/third_party/unrar/src/secpassword.cpp -index 4865b3fd02e25312d4390e34cad87c513adcfbe7..c292b0e002853fa815ec84b4870ec7636531c58c 100644 +index 4865b3fd02e25..c292b0e002853 100644 --- a/third_party/unrar/src/secpassword.cpp +++ b/third_party/unrar/src/secpassword.cpp @@ -25,6 +25,7 @@ class CryptLoader @@ -542,7 +600,7 @@ ErrHandler.SysErrMsg(); ErrHandler.Exit(RARX_FATAL); diff --git a/third_party/unrar/src/unicode.cpp b/third_party/unrar/src/unicode.cpp -index 641f6c892a3f33f271dceac276f1c550af500ed2..48d7bb2fc44e791d9b1fc4fd79e747fc4bbde2c8 100644 +index 641f6c892a3f3..48d7bb2fc44e7 100644 --- a/third_party/unrar/src/unicode.cpp +++ b/third_party/unrar/src/unicode.cpp @@ -576,7 +576,6 @@ int64 atoilw(const wchar *s) @@ -566,7 +624,7 @@ char* SupportDBCS::charnext(const char *s) { diff --git a/third_party/unrar/src/unicode.hpp b/third_party/unrar/src/unicode.hpp -index 031ac09ab94b6f5fd5f38d25c0bac5aa93dfab7c..c66cc95a34cc3ac1edcba80b22d61d73864928cf 100644 +index 031ac09ab94b6..c66cc95a34cc3 100644 --- a/third_party/unrar/src/unicode.hpp +++ b/third_party/unrar/src/unicode.hpp @@ -33,6 +33,7 @@ class SupportDBCS @@ -601,7 +659,7 @@ #else #define charnext(s) ((s)+1) diff --git a/third_party/unrar/src/unpack.cpp b/third_party/unrar/src/unpack.cpp -index 037c35546a894bba79225b1e0f3750807a3284af..7f579ff06ab38cf4a3f268252106e22cba420358 100644 +index 037c35546a894..7f579ff06ab38 100644 --- a/third_party/unrar/src/unpack.cpp +++ b/third_party/unrar/src/unpack.cpp @@ -1,3 +1,9 @@ @@ -651,7 +709,7 @@ if (!Fragmented) { diff --git a/third_party/unrar/src/unpack50frag.cpp b/third_party/unrar/src/unpack50frag.cpp -index 3c008ff245390a35334c43b71e5fdd283b8815d1..16d5b1c3d5ef368e4888831bf16edd4f1025f655 100644 +index 3c008ff245390..16d5b1c3d5ef3 100644 --- a/third_party/unrar/src/unpack50frag.cpp +++ b/third_party/unrar/src/unpack50frag.cpp @@ -46,8 +46,14 @@ void FragmentedWindow::Init(size_t WinSize)
diff --git a/third_party/unrar/src/blake2s.hpp b/third_party/unrar/src/blake2s.hpp index f88ef37..d8b30f94 100644 --- a/third_party/unrar/src/blake2s.hpp +++ b/third_party/unrar/src/blake2s.hpp
@@ -5,11 +5,8 @@ #define BLAKE2_DIGEST_SIZE 32 #define BLAKE2_THREADS_NUMBER 8 -enum blake2s_constant -{ - BLAKE2S_BLOCKBYTES = 64, - BLAKE2S_OUTBYTES = 32 -}; +constexpr size_t BLAKE2S_BLOCKBYTES = 64; +constexpr size_t BLAKE2S_OUTBYTES = 32; // Alignment to 64 improves performance of both SSE and non-SSE versions. @@ -20,10 +17,10 @@ // 'new' operator. struct blake2s_state { - enum { BLAKE_ALIGNMENT = 64 }; + static constexpr size_t BLAKE_ALIGNMENT = 64; // buffer and uint32 h[8], t[2], f[2]; - enum { BLAKE_DATA_SIZE = 48 + 2 * BLAKE2S_BLOCKBYTES }; + static constexpr size_t BLAKE_DATA_SIZE = 48 + 2 * BLAKE2S_BLOCKBYTES; byte ubuf[BLAKE_DATA_SIZE + BLAKE_ALIGNMENT];
diff --git a/third_party/unrar/src/hash.cpp b/third_party/unrar/src/hash.cpp index a4559e05..106cc608 100644 --- a/third_party/unrar/src/hash.cpp +++ b/third_party/unrar/src/hash.cpp
@@ -26,7 +26,7 @@ } -bool HashValue::operator == (const HashValue &cmp) +bool HashValue::operator == (const HashValue &cmp) const { if (Type==HASH_NONE || cmp.Type==HASH_NONE) return true;
diff --git a/third_party/unrar/src/hash.hpp b/third_party/unrar/src/hash.hpp index b7d879f..92326006 100644 --- a/third_party/unrar/src/hash.hpp +++ b/third_party/unrar/src/hash.hpp
@@ -6,8 +6,7 @@ struct HashValue { void Init(HASH_TYPE Type); - bool operator == (const HashValue &cmp); - bool operator != (const HashValue &cmp) {return !(*this==cmp);} + bool operator == (const HashValue &cmp) const; HASH_TYPE Type; union
diff --git a/tools/android/checkxmlstyle/checkxmlstyle.py b/tools/android/checkxmlstyle/checkxmlstyle.py index 5149245..84ed9704 100644 --- a/tools/android/checkxmlstyle/checkxmlstyle.py +++ b/tools/android/checkxmlstyle/checkxmlstyle.py
@@ -368,6 +368,7 @@ 'android:fontFamily', 'android:textAllCaps'] namespace = {'android': 'http://schemas.android.com/apk/res/android'} errors = [] + differences = False for f in IncludedFiles(input_api): try: root = ET.fromstring(input_api.ReadFile(f)) @@ -398,17 +399,19 @@ errors.append(' %s:%d contains attribute %s\n \t%s' % ( f.LocalPath(), line_number+1, attribute, line.strip())) style_count += 1 + if f.ChangedContents(): + differences = True # Error for text attributes in layout. if widget_count > 0 and attribute in line: errors.append(' %s:%d contains attribute %s\n \t%s' % ( f.LocalPath(), line_number+1, attribute, line.strip())) widget_count -= 1 + if f.ChangedContents(): + differences = True # TODO(huayinz): Change the path on the error message to the corresponding # styles.xml when this check applies to all resource directories. if errors: - return [ - output_api.PresubmitError( - ''' + message = (''' Android Text Appearance Check failed: Your modified files contain Android text attributes defined outside text appearance styles, listed below. @@ -438,8 +441,13 @@ Please contact arminaforoughi@chromium.org for UX approval, and src/chrome/android/java/res/OWNERS for questions. See https://crbug.com/775198 for more information. - ''', errors) - ] + ''') + if differences: + return [output_api.PresubmitError(message, errors)] + else: + # Report a warning instead of an error when running "presubmit --all" or + # "presubmit --files" so that these can run error free. + return [output_api.PresubmitPromptWarning(message, errors)] return []
diff --git a/tools/json_schema_compiler/test/crossref_unittest.cc b/tools/json_schema_compiler/test/crossref_unittest.cc index 4680ee7..0d50682 100644 --- a/tools/json_schema_compiler/test/crossref_unittest.cc +++ b/tools/json_schema_compiler/test/crossref_unittest.cc
@@ -17,12 +17,12 @@ namespace { -std::unique_ptr<base::DictionaryValue> CreateTestTypeValue() { - auto value = std::make_unique<base::DictionaryValue>(); - value->SetDouble("number", 1.1); - value->SetInteger("integer", 4); - value->SetString("string", "bling"); - value->SetBoolean("boolean", true); +base::DictionaryValue CreateTestTypeValue() { + base::DictionaryValue value; + value.SetDouble("number", 1.1); + value.SetInteger("integer", 4); + value.SetString("string", "bling"); + value.SetBoolean("boolean", true); return value; } @@ -30,8 +30,7 @@ TEST(JsonSchemaCompilerCrossrefTest, CrossrefTypePopulateAndToValue) { base::DictionaryValue crossref_orig; - crossref_orig.SetKey("testType", - base::Value::FromUniquePtrValue(CreateTestTypeValue())); + crossref_orig.SetKey("testType", CreateTestTypeValue()); crossref_orig.SetString("testEnumRequired", "one"); crossref_orig.SetString("testEnumOptional", "two"); @@ -61,14 +60,13 @@ params_value->GetListDeprecated())); EXPECT_TRUE(params.get()); EXPECT_TRUE(params->test_type.get()); - EXPECT_EQ(*CreateTestTypeValue(), *params->test_type->ToValue()); + EXPECT_EQ(CreateTestTypeValue(), *params->test_type->ToValue()); } TEST(JsonSchemaCompilerCrossrefTest, TestTypeOptionalParamFail) { auto params_value = std::make_unique<base::ListValue>(); - std::unique_ptr<base::DictionaryValue> test_type_value = - CreateTestTypeValue(); - test_type_value->RemoveKey("number"); + base::DictionaryValue test_type_value = CreateTestTypeValue(); + test_type_value.RemoveKey("number"); params_value->Append(std::move(test_type_value)); std::unique_ptr<crossref::TestTypeOptionalParam::Params> params( crossref::TestTypeOptionalParam::Params::Create( @@ -77,65 +75,63 @@ } TEST(JsonSchemaCompilerCrossrefTest, GetTestType) { - std::unique_ptr<base::DictionaryValue> value = CreateTestTypeValue(); + base::DictionaryValue value = CreateTestTypeValue(); auto test_type = std::make_unique<simple_api::TestType>(); - EXPECT_TRUE(simple_api::TestType::Populate(*value, test_type.get())); + EXPECT_TRUE(simple_api::TestType::Populate(value, test_type.get())); std::vector<base::Value> results = crossref::GetTestType::Results::Create(*test_type); ASSERT_EQ(1u, results.size()); - EXPECT_EQ(*value, results[0]); + EXPECT_EQ(value, results[0]); } TEST(JsonSchemaCompilerCrossrefTest, TestTypeInObjectParamsCreate) { { - auto params_value = std::make_unique<base::ListValue>(); - auto param_object_value = std::make_unique<base::DictionaryValue>(); - param_object_value->SetKey( - "testType", base::Value::FromUniquePtrValue(CreateTestTypeValue())); - param_object_value->SetBoolean("boolean", true); - params_value->Append(std::move(param_object_value)); + base::Value params_value(base::Value::Type::LIST); + base::Value::Dict param_object_value; + param_object_value.Set("testType", CreateTestTypeValue()); + param_object_value.Set("boolean", true); + params_value.GetList().Append(std::move(param_object_value)); std::unique_ptr<crossref::TestTypeInObject::Params> params( crossref::TestTypeInObject::Params::Create( - params_value->GetListDeprecated())); + params_value.GetListDeprecated())); EXPECT_TRUE(params.get()); EXPECT_TRUE(params->param_object.test_type.get()); EXPECT_TRUE(params->param_object.boolean); - EXPECT_EQ(*CreateTestTypeValue(), + EXPECT_EQ(CreateTestTypeValue(), *params->param_object.test_type->ToValue()); } { - auto params_value = std::make_unique<base::ListValue>(); - auto param_object_value = std::make_unique<base::DictionaryValue>(); - param_object_value->SetBoolean("boolean", true); - params_value->Append(std::move(param_object_value)); + base::Value params_value(base::Value::Type::LIST); + base::Value::Dict param_object_value; + param_object_value.Set("boolean", true); + params_value.GetList().Append(std::move(param_object_value)); std::unique_ptr<crossref::TestTypeInObject::Params> params( crossref::TestTypeInObject::Params::Create( - params_value->GetListDeprecated())); + params_value.GetListDeprecated())); EXPECT_TRUE(params.get()); EXPECT_FALSE(params->param_object.test_type.get()); EXPECT_TRUE(params->param_object.boolean); } { - auto params_value = std::make_unique<base::ListValue>(); - auto param_object_value = std::make_unique<base::DictionaryValue>(); - param_object_value->SetString("testType", "invalid"); - param_object_value->SetBoolean("boolean", true); - params_value->Append(std::move(param_object_value)); + base::Value params_value(base::Value::Type::LIST); + base::Value::Dict param_object_value; + param_object_value.Set("testType", "invalid"); + param_object_value.Set("boolean", true); + params_value.GetList().Append(std::move(param_object_value)); std::unique_ptr<crossref::TestTypeInObject::Params> params( crossref::TestTypeInObject::Params::Create( - params_value->GetListDeprecated())); + params_value.GetListDeprecated())); EXPECT_FALSE(params.get()); } { - auto params_value = std::make_unique<base::ListValue>(); - auto param_object_value = std::make_unique<base::DictionaryValue>(); - param_object_value->SetKey( - "testType", base::Value::FromUniquePtrValue(CreateTestTypeValue())); - params_value->Append(std::move(param_object_value)); + base::Value params_value(base::Value::Type::LIST); + base::Value::Dict param_object_value; + param_object_value.Set("testType", CreateTestTypeValue()); + params_value.GetList().Append(std::move(param_object_value)); std::unique_ptr<crossref::TestTypeInObject::Params> params( crossref::TestTypeInObject::Params::Create( - params_value->GetListDeprecated())); + params_value.GetListDeprecated())); EXPECT_FALSE(params.get()); } }
diff --git a/tools/json_schema_compiler/test/test_util.cc b/tools/json_schema_compiler/test/test_util.cc index 61076b5..b27c9a0 100644 --- a/tools/json_schema_compiler/test/test_util.cc +++ b/tools/json_schema_compiler/test/test_util.cc
@@ -24,23 +24,23 @@ std::unique_ptr<base::ListValue> List(std::unique_ptr<base::Value> a) { auto list = std::make_unique<base::ListValue>(); - list->Append(std::move(a)); + list->GetList().Append(base::Value::FromUniquePtrValue(std::move(a))); return list; } std::unique_ptr<base::ListValue> List(std::unique_ptr<base::Value> a, std::unique_ptr<base::Value> b) { auto list = std::make_unique<base::ListValue>(); - list->Append(std::move(a)); - list->Append(std::move(b)); + list->GetList().Append(base::Value::FromUniquePtrValue(std::move(a))); + list->GetList().Append(base::Value::FromUniquePtrValue(std::move(b))); return list; } std::unique_ptr<base::ListValue> List(std::unique_ptr<base::Value> a, std::unique_ptr<base::Value> b, std::unique_ptr<base::Value> c) { auto list = std::make_unique<base::ListValue>(); - list->Append(std::move(a)); - list->Append(std::move(b)); - list->Append(std::move(c)); + list->GetList().Append(base::Value::FromUniquePtrValue(std::move(a))); + list->GetList().Append(base::Value::FromUniquePtrValue(std::move(b))); + list->GetList().Append(base::Value::FromUniquePtrValue(std::move(c))); return list; }
diff --git a/tools/mb/mb_config.pyl b/tools/mb/mb_config.pyl index 6a5d16f..3408ca42 100644 --- a/tools/mb/mb_config.pyl +++ b/tools/mb/mb_config.pyl
@@ -172,7 +172,7 @@ 'chromeos-kevin-rel (reclient shadow)': 'chromeos_kevin_dchecks_reclient', 'lacros-amd64-generic-binary-size-rel': 'chromeos_amd64-generic_lacros_rel', 'lacros-amd64-generic-rel': 'chromeos_amd64-generic_lacros_rel_reclient', - 'lacros-arm-generic-rel': 'chromeos_arm-generic_lacros_rel', + 'lacros-arm-generic-rel': 'chromeos_arm-generic_lacros_rel_reclient', 'linux-ash-chromium-generator-rel': 'chromeos_with_codecs_release_bot', 'linux-cfm-rel': 'linux_cfm_release_bot_reclient', 'linux-chromeos-dbg': 'chromeos_with_codecs_debug_bot_reclient', @@ -2033,14 +2033,14 @@ 'chromeos_arm-generic-crostoolchain', 'lacros', 'official', 'minimal_symbols', 'cfi', 'thin_lto', 'is_skylab', ], - 'chromeos_arm-generic_lacros_rel': [ - 'chromeos_arm-generic-crostoolchain', 'lacros', 'release', - ], - 'chromeos_arm-generic_lacros_rel_dchecks': [ 'chromeos_arm-generic-crostoolchain', 'lacros', 'release', 'dcheck_always_on', ], + 'chromeos_arm-generic_lacros_rel_reclient': [ + 'chromeos_arm-generic-crostoolchain_reclient', 'lacros', 'release', + ], + 'chromeos_arm-generic_reclient': [ 'chromeos_device_reclient', 'arm-generic', ], @@ -3639,6 +3639,10 @@ 'mixins': ['chromeos_device', 'arm-generic-crostoolchain',] }, + 'chromeos_arm-generic-crostoolchain_reclient': { + 'mixins': ['chromeos_device_reclient', 'arm-generic-crostoolchain',] + }, + 'chromeos_codecs': { 'mixins': ['ffmpeg_branding_chromeos', 'proprietary_codecs'], },
diff --git a/tools/mb/mb_config_expectations/chromium.chromiumos.json b/tools/mb/mb_config_expectations/chromium.chromiumos.json index c4a64cc7..747375f 100644 --- a/tools/mb/mb_config_expectations/chromium.chromiumos.json +++ b/tools/mb/mb_config_expectations/chromium.chromiumos.json
@@ -213,7 +213,8 @@ "is_debug": false, "ozone_platform_headless": true, "target_os": "chromeos", - "use_goma": true + "use_rbe": true, + "use_remoteexec": true } }, "linux-ash-chromium-generator-rel": {
diff --git a/tools/metrics/histograms/enums.xml b/tools/metrics/histograms/enums.xml index b38bcce6..c6eccd2 100644 --- a/tools/metrics/histograms/enums.xml +++ b/tools/metrics/histograms/enums.xml
@@ -16709,11 +16709,6 @@ <int value="7" label="No overlap not seen from Longpress"/> </enum> -<enum name="ContextualSearchBasePageProtocol"> - <int value="0" label="Is HTTP"/> - <int value="1" label="Not HTTP"/> -</enum> - <enum name="ContextualSearchBlacklistSeen"> <obsolete> Deprecated as of 5/2017. Experiment is finished. @@ -16933,11 +16928,6 @@ <int value="5" label="Not activated nor seen"/> </enum> -<enum name="ContextualSearchResolvedTermWords"> - <int value="0" label="Single Word"/> - <int value="1" label="Multi Word"/> -</enum> - <enum name="ContextualSearchResultsSeen"> <int value="0" label="Seen"/> <int value="1" label="Unseen"/> @@ -53113,6 +53103,7 @@ <int value="-1661282561" label="SharingHubDesktopOmnibox:enabled"/> <int value="-1660972490" label="gpu-rasterization-msaa-sample-count"/> <int value="-1660884825" label="ReadLaterNewBadgePromo:enabled"/> + <int value="-1658461830" label="SharedHighlightingRefinedBlocklist:enabled"/> <int value="-1656667928" label="UseSyncInvalidationsForWalletAndOffer:disabled"/> <int value="-1656179450" label="EnableOmniboxRichEntities:enabled"/> @@ -55589,6 +55580,7 @@ label="NTPArticleSuggestionsExpandableHeader:disabled"/> <int value="-23090520" label="disable-search-button-in-omnibox"/> <int value="-22544408" label="enable-video-player-chromecast-support"/> + <int value="-22506564" label="OptimizeDataUrls:disabled"/> <int value="-20597579" label="UseMultiloginEndpoint:enabled"/> <int value="-20438829" label="SyncUSSAutofillProfile:enabled"/> <int value="-20329017" label="EduCoexistence:disabled"/> @@ -56136,6 +56128,7 @@ <int value="350611185" label="SharingDesktopScreenshotsEdit:enabled"/> <int value="350635266" label="TabGroupsContinuationAndroid:enabled"/> <int value="351005753" label="enable-experimental-accessibility-autoclick"/> + <int value="351231040" label="OptimizeDataUrls:enabled"/> <int value="352191859" label="disabled-new-style-notification"/> <int value="352937987" label="OverflowIconsForMediaControls:disabled"/> <int value="353898777" label="ClipboardHistoryScreenshotNudge:disabled"/> @@ -58431,6 +58424,7 @@ <int value="1907273605" label="NtpZeroSuggest:disabled"/> <int value="1909117215" label="animated-image-resume"/> <int value="1910240042" label="enable-experimental-fullscreen-exit-ui"/> + <int value="1910562940" label="SharedHighlightingRefinedBlocklist:disabled"/> <int value="1911002680" label="TFLiteLanguageDetectionEnabled:enabled"/> <int value="1913263516" label="OculusVR:enabled"/> <int value="1913298816" label="OverlayScrollbar:enabled"/> @@ -79900,19 +79894,6 @@ <int value="7" label="Error parsing certificate"/> </enum> -<enum name="RsaPssClassification"> - <int value="0" label="The MGF-1 digest and signing digest did not match"/> - <int value="1" label="The digest algorithm was MD5 or older"/> - <int value="2" label="SHA-1 with salt length of 20"/> - <int value="3" label="SHA-1 with a non-standard salt length"/> - <int value="4" label="SHA-256 with a salt length of 32"/> - <int value="5" label="SHA-256 with a non-standard salt length"/> - <int value="6" label="SHA-384 with a salt length of 48"/> - <int value="7" label="SHA-384 with a non-standard salt length"/> - <int value="8" label="SHA-512 with a salt length of 64"/> - <int value="9" label="SHA-512 with a non-standard salt length"/> -</enum> - <enum name="RTCAPIName"> <int value="0" label="GetUserMedia"/> <int value="1" label="PeerConnection00"/>
diff --git a/tools/metrics/histograms/metadata/blink/histograms.xml b/tools/metrics/histograms/metadata/blink/histograms.xml index b6fe6b5e..b50b8cc 100644 --- a/tools/metrics/histograms/metadata/blink/histograms.xml +++ b/tools/metrics/histograms/metadata/blink/histograms.xml
@@ -885,18 +885,20 @@ </summary> </histogram> -<histogram name="Blink.Fetch.RequestResourceTime" units="microseconds" - expires_after="M82"> +<histogram name="Blink.Fetch.RequestResourceTime2{Scheme}" units="microseconds" + expires_after="2022-11-02"> <owner>csharrison@chromium.org</owner> + <owner>cduvall@chromium.org</owner> <summary> - The total microseconds spent in ResourceFetcher::requestResource. + The total microseconds spent in ResourceFetcher::requestResource for + {Scheme}. - Warning: This metric may include reports from clients with low-resolution - clocks (i.e. on Windows, ref. |TimeTicks::IsHighResolution()|). Such reports - will cause this metric to have an abnormal distribution. When considering - revising this histogram, see UMA_HISTOGRAM_CUSTOM_MICROSECONDS_TIMES for the - solution. + This histogram only records metrics on machines with high-resolution clocks. </summary> + <token key="Scheme"> + <variant name="" summary="all URLs"/> + <variant name=".Data" summary="data URLs"/> + </token> </histogram> <histogram name="Blink.FetchQueuedPreloadsTime.{FrameType}.{IsInitial}"
diff --git a/tools/metrics/histograms/metadata/enterprise/histograms.xml b/tools/metrics/histograms/metadata/enterprise/histograms.xml index 77c8d1a..cee12d5 100644 --- a/tools/metrics/histograms/metadata/enterprise/histograms.xml +++ b/tools/metrics/histograms/metadata/enterprise/histograms.xml
@@ -67,7 +67,7 @@ </variants> <histogram name="Enterprise.AccountStatusCheckResult" - enum="EnterpriseAccountStatus" expires_after="2022-05-01"> + enum="EnterpriseAccountStatus" expires_after="2022-10-01"> <owner>raleksandrov@google.com</owner> <owner>cros-oac@google.com</owner> <summary> @@ -1264,7 +1264,7 @@ </histogram> <histogram name="Enterprise.EnrollmentForced" enum="EnterpriseEnrollmentType" - expires_after="2022-05-01"> + expires_after="2022-10-01"> <owner>raleksandrov@google.com</owner> <owner>cros-oac@google.com</owner> <summary> @@ -1273,7 +1273,7 @@ </histogram> <histogram name="Enterprise.EnrollmentForcedAttestationBased" - enum="EnterpriseEnrollmentType" expires_after="2022-05-01"> + enum="EnterpriseEnrollmentType" expires_after="2022-10-01"> <owner>raleksandrov@google.com</owner> <owner>cros-oac@google.com</owner> <summary>
diff --git a/tools/metrics/histograms/metadata/gpu/histograms.xml b/tools/metrics/histograms/metadata/gpu/histograms.xml index 3583dd4..b92e435 100644 --- a/tools/metrics/histograms/metadata/gpu/histograms.xml +++ b/tools/metrics/histograms/metadata/gpu/histograms.xml
@@ -23,7 +23,7 @@ <histograms> <histogram name="ConfigureDisplays.External.Modeset.AttemptSucceeded" - enum="BooleanSuccess" expires_after="2022-09-01"> + enum="BooleanSuccess" expires_after="2023-05-01"> <owner>gildekel@chromium.org</owner> <owner>seanpaul@chromium.org</owner> <owner>chromeos-gfx-display@chromium.org</owner> @@ -37,7 +37,7 @@ </histogram> <histogram name="ConfigureDisplays.External.Modeset.FinalStatus" - enum="BooleanSuccess" expires_after="2022-09-01"> + enum="BooleanSuccess" expires_after="2023-05-01"> <owner>gildekel@chromium.org</owner> <owner>seanpaul@chromium.org</owner> <owner>chromeos-gfx-display@chromium.org</owner> @@ -51,6 +51,9 @@ <histogram name="ConfigureDisplays.External.Modeset.RefreshRate" units="Hz" expires_after="2022-09-01"> + <obsolete> + Replaced by ConfigureDisplays.External.Modeset.Success.RefreshRate in M103. + </obsolete> <owner>gildekel@chromium.org</owner> <owner>seanpaul@chromium.org</owner> <owner>chromeos-gfx-display@chromium.org</owner> @@ -63,6 +66,10 @@ <histogram name="ConfigureDisplays.External.Modeset.Resolution" enum="DisplayResolution" expires_after="2022-09-01"> + <obsolete> + Split into ConfigureDisplays.External.Modeset.OriginalRequest.Resolution and + ConfigureDisplays.External.Modeset.Success.Resolution in M103. + </obsolete> <owner>gildekel@chromium.org</owner> <owner>seanpaul@chromium.org</owner> <owner>chromeos-gfx-display@chromium.org</owner> @@ -75,7 +82,7 @@ </histogram> <histogram name="ConfigureDisplays.Internal.Modeset.AttemptSucceeded" - enum="BooleanSuccess" expires_after="2022-09-01"> + enum="BooleanSuccess" expires_after="2023-05-01"> <owner>gildekel@chromium.org</owner> <owner>seanpaul@chromium.org</owner> <owner>chromeos-gfx-display@chromium.org</owner> @@ -90,7 +97,7 @@ </histogram> <histogram name="ConfigureDisplays.Internal.Modeset.FinalStatus" - enum="BooleanSuccess" expires_after="2022-09-01"> + enum="BooleanSuccess" expires_after="2023-05-01"> <owner>gildekel@chromium.org</owner> <owner>seanpaul@chromium.org</owner> <owner>chromeos-gfx-display@chromium.org</owner> @@ -104,6 +111,9 @@ <histogram name="ConfigureDisplays.Internal.Modeset.RefreshRate" units="Hz" expires_after="2022-09-01"> + <obsolete> + Replaced by ConfigureDisplays.Internal.Modeset.Success.RefreshRate in M103. + </obsolete> <owner>gildekel@chromium.org</owner> <owner>seanpaul@chromium.org</owner> <owner>chromeos-gfx-display@chromium.org</owner> @@ -116,6 +126,10 @@ <histogram name="ConfigureDisplays.Internal.Modeset.Resolution" enum="DisplayResolution" expires_after="2022-09-01"> + <obsolete> + Split into ConfigureDisplays.Internal.Modeset.OriginalRequest.Resolution and + ConfigureDisplays.Internal.Modeset.Success.Resolution in M103. + </obsolete> <owner>gildekel@chromium.org</owner> <owner>seanpaul@chromium.org</owner> <owner>chromeos-gfx-display@chromium.org</owner> @@ -128,7 +142,7 @@ </histogram> <histogram name="ConfigureDisplays.Modeset.MstExternalDisplaysCount" - units="count" expires_after="2022-09-01"> + units="count" expires_after="2023-05-01"> <owner>gildekel@chromium.org</owner> <owner>seanpaul@chromium.org</owner> <owner>chromeos-gfx-display@chromium.org</owner> @@ -140,7 +154,7 @@ </histogram> <histogram name="ConfigureDisplays.Modeset.MstExternalDisplaysPercentage" - units="%" expires_after="2022-09-01"> + units="%" expires_after="2023-05-01"> <owner>gildekel@chromium.org</owner> <owner>seanpaul@chromium.org</owner> <owner>chromeos-gfx-display@chromium.org</owner> @@ -152,7 +166,7 @@ </histogram> <histogram name="ConfigureDisplays.Modeset.TotalExternalDisplaysCount" - units="count" expires_after="2022-09-01"> + units="count" expires_after="2023-05-01"> <owner>gildekel@chromium.org</owner> <owner>seanpaul@chromium.org</owner> <owner>chromeos-gfx-display@chromium.org</owner> @@ -163,8 +177,42 @@ </summary> </histogram> +<histogram name="ConfigureDisplays.{Connection}.Modeset.Success.RefreshRate" + units="Hz" expires_after="2023-05-01"> + <owner>gildekel@chromium.org</owner> + <owner>seanpaul@chromium.org</owner> + <owner>chromeos-gfx-display@chromium.org</owner> + <summary> + Tracks an {Connection} display's resulting refresh rate after a successful + display configuration. + </summary> + <token key="Connection"> + <variant name="External" summary="external"/> + <variant name="Internal" summary="internal"/> + </token> +</histogram> + +<histogram name="ConfigureDisplays.{Connection}.Modeset.{Report}.Resolution" + enum="DisplayResolution" expires_after="2023-05-01"> + <owner>gildekel@chromium.org</owner> + <owner>seanpaul@chromium.org</owner> + <owner>chromeos-gfx-display@chromium.org</owner> + <summary>{Connection} {Report}</summary> + <token key="Connection"> + <variant name="External" summary="Tracks an external display's"/> + <variant name="Internal" summary="Tracks an internal display's"/> + </token> + <token key="Report"> + <variant name="OriginalRequest" + summary="original resolution request during display configuration."/> + <variant name="Success" + summary="resulting resolution after a successful display + configuration."/> + </token> +</histogram> + <histogram name="Display.External.BlockZeroSerialNumberType" - enum="BlockZeroSerialNumberType" expires_after="2022-09-01"> + enum="BlockZeroSerialNumberType" expires_after="2023-05-01"> <owner>gildekel@chromium.org</owner> <owner>seanpaul@chromium.org</owner> <owner>chromeos-gfx-display@google.com</owner> @@ -175,7 +223,7 @@ </histogram> <histogram name="Display.External.NumOfSerialNumbersProvided" units="count" - expires_after="2022-09-01"> + expires_after="2023-05-01"> <owner>gildekel@chromium.org</owner> <owner>seanpaul@chromium.org</owner> <owner>chromeos-gfx-display@google.com</owner> @@ -186,7 +234,7 @@ </histogram> <histogram name="Display.External.ParseEdidOptionals" enum="ParseEdidOptionals" - expires_after="2022-09-01"> + expires_after="2023-05-01"> <owner>gildekel@chromium.org</owner> <owner>seanpaul@chromium.org</owner> <owner>chromeos-gfx-display@google.com</owner> @@ -197,7 +245,7 @@ </histogram> <histogram name="Display.MultipleDisplays.GenerateId.CollisionDetection" - enum="BooleanDisplayIdCollision" expires_after="2022-09-01"> + enum="BooleanDisplayIdCollision" expires_after="2023-05-01"> <owner>gildekel@chromium.org</owner> <owner>seanpaul@chromium.org</owner> <owner>chromeos-gfx-display@google.com</owner> @@ -211,7 +259,7 @@ </histogram> <histogram name="Display.ParseEdidFailure" enum="ParseEdidFailure" - expires_after="2022-09-01"> + expires_after="2023-05-01"> <owner>gildekel@chromium.org</owner> <owner>sashamcintosh@chromium.org</owner> <owner>seanpaul@chromium.org</owner>
diff --git a/tools/metrics/histograms/metadata/net/histograms.xml b/tools/metrics/histograms/metadata/net/histograms.xml index d0d885db..794df36 100644 --- a/tools/metrics/histograms/metadata/net/histograms.xml +++ b/tools/metrics/histograms/metadata/net/histograms.xml
@@ -296,16 +296,6 @@ </summary> </histogram> -<histogram name="Net.CertVerifier.RsaPssClassification" - enum="RsaPssClassification" expires_after="2022-12-31"> - <owner>davidben@chromium.org</owner> - <owner>src/net/cert/OWNERS</owner> - <summary> - While parsing an RSASSA-PSS signature algorithm, the kinds of parameters - that were encountered. - </summary> -</histogram> - <histogram name="Net.CertVerifier_First_Job_Latency" units="ms" expires_after="never"> <!-- expires-never: core cert verifier metric; monitored by Chirps -->
diff --git a/tools/metrics/histograms/metadata/oobe/histograms.xml b/tools/metrics/histograms/metadata/oobe/histograms.xml index a0efb66..62e885c 100644 --- a/tools/metrics/histograms/metadata/oobe/histograms.xml +++ b/tools/metrics/histograms/metadata/oobe/histograms.xml
@@ -23,7 +23,7 @@ <histograms> <histogram name="OOBE.ArcTermsOfServiceScreen.ReviewFollowingSetup" - enum="BooleanChecked" expires_after="2022-05-01"> + enum="BooleanChecked" expires_after="2022-10-01"> <owner>raleksandrov@google.com</owner> <owner>cros-oac@google.com</owner> <summary> @@ -81,7 +81,7 @@ </histogram> <histogram name="OOBE.EulaScreen.UserActions" enum="EulaScreenUserAction" - expires_after="2022-05-01"> + expires_after="2022-10-01"> <owner>raleksandrov@google.com</owner> <owner>cros-oac@google.com</owner> <summary>
diff --git a/tools/metrics/histograms/metadata/optimization/histograms.xml b/tools/metrics/histograms/metadata/optimization/histograms.xml index 067695e..d05e8fc 100644 --- a/tools/metrics/histograms/metadata/optimization/histograms.xml +++ b/tools/metrics/histograms/metadata/optimization/histograms.xml
@@ -646,6 +646,17 @@ </histogram> <histogram + name="OptimizationGuide.PageContentAnnotations.TemplateURLServiceLoadedAtNavigationFinish" + enum="BooleanLoaded" expires_after="M106"> + <owner>sophiechang@chromium.org</owner> + <owner>chrome-intelligence-core@google.com</owner> + <summary> + Records whether the TemplateURLService was available and loaded at + navigation finish. Recorded once per page load. + </summary> +</histogram> + +<histogram name="OptimizationGuide.PageContentAnnotationsService.ContentAnnotated" enum="BooleanAnnotated" expires_after="M106"> <owner>sophiechang@chromium.org</owner>
diff --git a/tools/metrics/histograms/metadata/others/histograms.xml b/tools/metrics/histograms/metadata/others/histograms.xml index cc0576c..a2c9f8d9 100644 --- a/tools/metrics/histograms/metadata/others/histograms.xml +++ b/tools/metrics/histograms/metadata/others/histograms.xml
@@ -3852,7 +3852,7 @@ </histogram> <histogram name="Crashpad.AnrUpload.Skipped" enum="AnrSkippedReason" - expires_after="2022-06-15"> + expires_after="2022-12-15"> <owner>smaier@chromium.org</owner> <owner>crashpad-dev@chromium.org</owner> <summary>The reason that an ANR upload was skipped.</summary> @@ -13667,7 +13667,7 @@ </histogram> <histogram name="VoiceInteraction.AssistantActionPerformed{Source}" - enum="AssistantActionPerformed" expires_after="2022-06-12"> + enum="AssistantActionPerformed" expires_after="2022-10-23"> <owner>jds@google.com</owner> <owner>chrome-language@google.com</owner> <summary> @@ -13688,7 +13688,7 @@ </histogram> <histogram name="VoiceInteraction.AssistantIntent.TranslateExtrasAttached" - enum="BooleanSuccess" expires_after="2022-06-12"> + enum="BooleanSuccess" expires_after="2022-10-23"> <owner>jds@google.com</owner> <owner>chrome-language@google.com</owner> <summary> @@ -13699,7 +13699,7 @@ </histogram> <histogram name="VoiceInteraction.AudioPermissionEvent{Timing}" - enum="AudioPermissionState" expires_after="2022-06-12"> + enum="AudioPermissionState" expires_after="2022-10-23"> <owner>basiaz@google.com</owner> <owner>chrome-language@google.com</owner> <summary> @@ -13716,10 +13716,9 @@ </histogram> <histogram name="VoiceInteraction.DismissedEventSource" - enum="VoiceInteractionEventSource" expires_after="2022-10-16"> - <owner>wylieb@chromium.org</owner> - <owner>tedchoc@chromium.org</owner> - <owner>yusufo@chromium.org</owner> + enum="VoiceInteractionEventSource" expires_after="2022-10-23"> + <owner>jds@google.com</owner> + <owner>chrome-language@google.com</owner> <summary> Android: The source of a dismissed voice search, such as omnibox or NTP. This is recorded after the dismissed intent returns to Chrome. @@ -13727,10 +13726,9 @@ </histogram> <histogram name="VoiceInteraction.DismissedEventTarget" - enum="VoiceIntentTarget" expires_after="2022-10-16"> - <owner>wylieb@chromium.org</owner> - <owner>tedchoc@chromium.org</owner> - <owner>yusufo@chromium.org</owner> + enum="VoiceIntentTarget" expires_after="2022-10-23"> + <owner>jds@google.com</owner> + <owner>chrome-language@google.com</owner> <summary> Android: The target of a dismissed voice search, such as the system transcription dialog or Assistant. This is recorded after the dismissed @@ -13740,9 +13738,8 @@ <histogram name="VoiceInteraction.FailureEventSource" enum="VoiceInteractionEventSource" expires_after="2022-10-23"> - <owner>wylieb@chromium.org</owner> - <owner>tedchoc@chromium.org</owner> - <owner>yusufo@chromium.org</owner> + <owner>jds@google.com</owner> + <owner>chrome-language@google.com</owner> <summary> Android: The source of a failed voice search, such as omnibox or NTP. This is recorded after any intent failure, which could occur before an intent is @@ -13753,9 +13750,8 @@ <histogram name="VoiceInteraction.FailureEventTarget" enum="VoiceIntentTarget" expires_after="2022-10-23"> - <owner>wylieb@chromium.org</owner> - <owner>tedchoc@chromium.org</owner> - <owner>yusufo@chromium.org</owner> + <owner>jds@google.com</owner> + <owner>chrome-language@google.com</owner> <summary> Android: The target of a failed voice search, such as the system transcription dialog or Assistant. This is recorded after any intent @@ -13765,10 +13761,9 @@ </histogram> <histogram name="VoiceInteraction.FinishEventSource" - enum="VoiceInteractionEventSource" expires_after="2022-10-16"> - <owner>wylieb@chromium.org</owner> - <owner>tedchoc@chromium.org</owner> - <owner>yusufo@chromium.org</owner> + enum="VoiceInteractionEventSource" expires_after="2022-10-23"> + <owner>jds@google.com</owner> + <owner>chrome-language@google.com</owner> <summary> Android: The source of a successful voice search, such as omnibox or NTP. This is recorded immediately after the successful intent returns to Chrome. @@ -13776,10 +13771,9 @@ </histogram> <histogram name="VoiceInteraction.FinishEventTarget" enum="VoiceIntentTarget" - expires_after="2022-10-16"> - <owner>wylieb@chromium.org</owner> - <owner>tedchoc@chromium.org</owner> - <owner>yusufo@chromium.org</owner> + expires_after="2022-10-23"> + <owner>jds@google.com</owner> + <owner>chrome-language@google.com</owner> <summary> Android: The target of a successful voice search, such as the system transcription dialog or Assistant. This is recorded immediately after the @@ -13798,8 +13792,8 @@ <histogram name="VoiceInteraction.QueryDuration.Android" units="ms" expires_after="2022-10-23"> - <owner>wylieb@chromium.org</owner> - <owner>tedchoc@chromium.org</owner> + <owner>jds@google.com</owner> + <owner>chrome-language@google.com</owner> <summary> Records the time it takes between the user clicking the mic and chrome receiving the transcribed voice query. This is recorded after an Assistant @@ -13808,9 +13802,9 @@ </histogram> <histogram name="VoiceInteraction.QueryDuration.Android.Target.{Target}" - units="ms" expires_after="2022-06-12"> - <owner>wylieb@chromium.org</owner> - <owner>tedchoc@chromium.org</owner> + units="ms" expires_after="2022-10-23"> + <owner>jds@google.com</owner> + <owner>chrome-language@google.com</owner> <summary> Records the time it takes between the user clicking the mic and chrome receiving the transcribed voice query. This is recorded after an Assistant @@ -13822,9 +13816,9 @@ </histogram> <histogram name="VoiceInteraction.QueryDuration.Android{Action}" units="ms" - expires_after="2022-06-12"> - <owner>wylieb@chromium.org</owner> - <owner>tedchoc@chromium.org</owner> + expires_after="2022-10-23"> + <owner>jds@google.com</owner> + <owner>chrome-language@google.com</owner> <summary> Records the time it takes between the user clicking the mic and chrome receiving the intent response for {Action} actions. This is recorded after @@ -13844,10 +13838,9 @@ </histogram> <histogram name="VoiceInteraction.StartEventSource" - enum="VoiceInteractionEventSource" expires_after="2022-10-16"> - <owner>wylieb@chromium.org</owner> - <owner>tedchoc@chromium.org</owner> - <owner>yusufo@chromium.org</owner> + enum="VoiceInteractionEventSource" expires_after="2022-10-23"> + <owner>jds@google.com</owner> + <owner>chrome-language@google.com</owner> <summary> Android: The source of a voice search start event, such as omnibox or NTP. This is recorded immediately before the voice transcription intent is sent. @@ -13855,10 +13848,9 @@ </histogram> <histogram name="VoiceInteraction.StartEventTarget" enum="VoiceIntentTarget" - expires_after="2022-10-16"> - <owner>wylieb@chromium.org</owner> - <owner>tedchoc@chromium.org</owner> - <owner>yusufo@chromium.org</owner> + expires_after="2022-10-23"> + <owner>jds@google.com</owner> + <owner>chrome-language@google.com</owner> <summary> Android: The target of a voice search start event, such as the system transcription dialog or Assistant. This is recorded immediately before the @@ -13867,9 +13859,9 @@ </histogram> <histogram name="VoiceInteraction.UnexpectedResultSource" - enum="VoiceInteractionEventSource" expires_after="2022-06-12"> - <owner>wylieb@chromium.org</owner> - <owner>tedchoc@chromium.org</owner> + enum="VoiceInteractionEventSource" expires_after="2022-10-23"> + <owner>jds@google.com</owner> + <owner>chrome-language@google.com</owner> <summary> Android: The source of an incoming result that doesn't align with an outgoing request from Chrome. This is recorded when the extraneous intent @@ -13878,9 +13870,9 @@ </histogram> <histogram name="VoiceInteraction.UnexpectedResultTarget" - enum="VoiceIntentTarget" expires_after="2022-06-12"> - <owner>wylieb@chromium.org</owner> - <owner>tedchoc@chromium.org</owner> + enum="VoiceIntentTarget" expires_after="2022-10-23"> + <owner>jds@google.com</owner> + <owner>chrome-language@google.com</owner> <summary> Android: The target of an intent result that doesn't align with an outgoing request from Chrome. This is recorded when the extraneous intent response is @@ -13898,9 +13890,8 @@ <histogram name="VoiceInteraction.VoiceResultConfidenceValue" units="%" expires_after="2022-10-23"> - <owner>wylieb@chromium.org</owner> - <owner>tedchoc@chromium.org</owner> - <owner>yusufo@chromium.org</owner> + <owner>jds@google.com</owner> + <owner>chrome-language@google.com</owner> <summary> Android: Records the confidence value of a successful voice search as a percentage. This is recorded when the voice intent returns successfully. @@ -13908,10 +13899,9 @@ </histogram> <histogram name="VoiceInteraction.VoiceResultConfidenceValue.{Target}" - units="%" expires_after="2022-06-12"> - <owner>wylieb@chromium.org</owner> - <owner>tedchoc@chromium.org</owner> - <owner>yusufo@chromium.org</owner> + units="%" expires_after="2022-10-23"> + <owner>jds@google.com</owner> + <owner>chrome-language@google.com</owner> <summary> Android: Records the confidence value of a successful voice search as a percentage, limited to intents sent to {Target}. This is recorded when the @@ -13922,9 +13912,8 @@ <histogram name="VoiceInteraction.VoiceSearchResult" enum="BooleanSuccess" expires_after="2022-10-23"> - <owner>wylieb@chromium.org</owner> - <owner>tedchoc@chromium.org</owner> - <owner>yusufo@chromium.org</owner> + <owner>jds@google.com</owner> + <owner>chrome-language@google.com</owner> <summary> Android: Records whether the voice search produced results. This is recorded when the voice intent returns successfully. @@ -13932,10 +13921,9 @@ </histogram> <histogram name="VoiceInteraction.VoiceSearchResult.{Target}" - enum="BooleanSuccess" expires_after="2022-06-12"> - <owner>wylieb@chromium.org</owner> - <owner>tedchoc@chromium.org</owner> - <owner>yusufo@chromium.org</owner> + enum="BooleanSuccess" expires_after="2022-10-23"> + <owner>jds@google.com</owner> + <owner>chrome-language@google.com</owner> <summary> Android: Records whether the voice search produced results, limited to intents sent to {Target}. This is recorded when the voice intent returns
diff --git a/tools/metrics/histograms/metadata/search/histograms.xml b/tools/metrics/histograms/metadata/search/histograms.xml index d898a30..c93650f 100644 --- a/tools/metrics/histograms/metadata/search/histograms.xml +++ b/tools/metrics/histograms/metadata/search/histograms.xml
@@ -390,16 +390,6 @@ </summary> </histogram> -<histogram name="Search.ContextualSearchBasePageProtocol" - enum="ContextualSearchBasePageProtocol" expires_after="M72"> - <owner>donnd@chromium.org</owner> - <owner>twellington@chromium.org</owner> - <summary> - The protocol of the base page, logged at the time that any Search Term - Resolution Response is received. - </summary> -</histogram> - <histogram name="Search.ContextualSearchContextualCardsIntegration.DataShown" enum="Boolean" expires_after="never"> <!-- expires-never: key metric on usefulness of Touch to Search. --> @@ -413,17 +403,6 @@ </summary> </histogram> -<histogram name="Search.ContextualSearchContextualCardsIntegration.ResultsSeen" - enum="ContextualSearchResultsSeen" expires_after="M85"> - <owner>donnd@chromium.org</owner> - <owner>twellington@chromium.org</owner> - <summary> - Whether search results were seen as part of a Contextual Search when - Contextual Cards data was shown. This indicates that the panel was opened. - Implemented for Android. - </summary> -</histogram> - <histogram name="Search.ContextualSearchDurationBetweenTriggerAndScrollNotSeen" units="ms" expires_after="M72"> <owner>donnd@chromium.org</owner> @@ -893,16 +872,6 @@ </summary> </histogram> -<histogram name="Search.ContextualSearchResolvedTermWords" - enum="ContextualSearchResolvedTermWords" expires_after="M72"> - <owner>donnd@chromium.org</owner> - <owner>twellington@chromium.org</owner> - <summary> - Whether the search term was single or multi-word, logged at the time that - any Search Term Resolution Response is received. - </summary> -</histogram> - <histogram name="Search.ContextualSearchResultsSeen" enum="ContextualSearchResultsSeen" expires_after="never"> <!-- expires-never: dashboard metric (internal: go/cs-metrics-dashboard) -->
diff --git a/tools/metrics/histograms/metadata/storage/histograms.xml b/tools/metrics/histograms/metadata/storage/histograms.xml index b621c96..627340c 100644 --- a/tools/metrics/histograms/metadata/storage/histograms.xml +++ b/tools/metrics/histograms/metadata/storage/histograms.xml
@@ -255,15 +255,6 @@ </summary> </histogram> -<histogram name="Storage.Blob.BuildFromStreamResult" - enum="BlobBuildFromStreamResult" expires_after="M87"> - <owner>mek@chromium.org</owner> - <summary> - The result of constructing a blob using the BlobRegistry.RegisterFromStream - API. - </summary> -</histogram> - <histogram name="Storage.Blob.CleanupSuccess" enum="Boolean" expires_after="M95"> <owner>mek@chromium.org</owner> @@ -456,17 +447,6 @@ </summary> </histogram> -<histogram name="Storage.BlobItemSize.File.Unknown" enum="BooleanUnknown" - expires_after="M87"> - <owner>mek@chromium.org</owner> - <owner>dmurph@chromium.org</owner> - <summary> - True if the file size on blob append is unknown (which means the full file), - or false if a specific file length was populated. Recorded in - BlobStorageContext when we are adding a file item to a blob. - </summary> -</histogram> - <histogram name="Storage.FileSystemAccess.PersistedPermissions.Age.{Type}" units="ms" expires_after="2023-01-01"> <owner>asully@chromium.org</owner>
diff --git a/tools/metrics/histograms/metadata/windows/histograms.xml b/tools/metrics/histograms/metadata/windows/histograms.xml index e5ead29..c53476fef 100644 --- a/tools/metrics/histograms/metadata/windows/histograms.xml +++ b/tools/metrics/histograms/metadata/windows/histograms.xml
@@ -217,6 +217,19 @@ </token> </histogram> +<histogram name="Windows.OnCurrentWorkspaceCached" enum="BooleanCacheHit" + expires_after="2022-10-01"> + <owner>davidbienvenu@chromium.org</owner> + <owner>sky@chromium.org</owner> + <summary> + Indicates if the current workspace state of a window is cached or not. If + it's known that the window is on the current workspace or not, then we can + avoid the COM method call IsWindowOnCurrentVirtualDesktop. This is recorded + in BrowserView::IsOnCurrentWorkspace. In general, the state should almost + always be cached. + </summary> +</histogram> + <histogram name="Windows.OOPSelectFileDialog.ProcessError" enum="BooleanError" expires_after="M82"> <owner>pmonette@chromium.org</owner>
diff --git a/tools/perf/core/minidump_unittest.py b/tools/perf/core/minidump_unittest.py index 546bab2e..7da66c3 100644 --- a/tools/perf/core/minidump_unittest.py +++ b/tools/perf/core/minidump_unittest.py
@@ -62,7 +62,6 @@ # Minidump symbolization doesn't work in ChromeOS local mode if the rootfs is # still read-only, so skip the test in that case. @decorators.Disabled( - 'chromeos-board-kevin', # https://crbug.com/1149237 'chromeos-local', 'mac', # https://crbug.com/1271097 'win7' # https://crbug.com/1084931 @@ -109,7 +108,6 @@ # Minidump symbolization doesn't work in ChromeOS local mode if the rootfs is # still read-only, so skip the test in that case. @decorators.Disabled( - 'chromeos-board-kevin', # https://crbug.com/1138060 'chromeos-local', 'mac', # https://crbug.com/1271097 'win7' # https://crbug.com/1084931
diff --git a/tools/perf/core/perfetto_binary_roller/binary_deps.json b/tools/perf/core/perfetto_binary_roller/binary_deps.json index cd2a196c..a32e52c 100644 --- a/tools/perf/core/perfetto_binary_roller/binary_deps.json +++ b/tools/perf/core/perfetto_binary_roller/binary_deps.json
@@ -21,8 +21,8 @@ "full_remote_path": "perfetto-luci-artifacts/v25.0/mac-arm64/trace_processor_shell" }, "linux": { - "hash": "bac72259adf9b15ae9730679fef86a90b56ef772", - "full_remote_path": "chromium-telemetry/perfetto_binaries/trace_processor_shell/linux/69bc804a183b29d2eeaa9a61a589127db9228fe1/trace_processor_shell" + "hash": "11709e5dd13e29603c6c70aa5e28be4832c7c2ed", + "full_remote_path": "chromium-telemetry/perfetto_binaries/trace_processor_shell/linux/f15232e63448819d1d629d153c102be7fc06e263/trace_processor_shell" } }, "power_profile.sql": {
diff --git a/ui/aura/native_window_occlusion_tracker.cc b/ui/aura/native_window_occlusion_tracker.cc index 4d70911..74ad6b5 100644 --- a/ui/aura/native_window_occlusion_tracker.cc +++ b/ui/aura/native_window_occlusion_tracker.cc
@@ -39,6 +39,7 @@ #if BUILDFLAG(IS_WIN) if (host->IsNativeWindowOcclusionEnabled()) { host->SetNativeWindowOcclusionState(Window::OcclusionState::UNKNOWN, {}); + host->set_on_current_workspace(absl::nullopt); NativeWindowOcclusionTrackerWin::GetOrCreateInstance()->Disable( host->window()); }
diff --git a/ui/aura/native_window_occlusion_tracker_win.cc b/ui/aura/native_window_occlusion_tracker_win.cc index f0d96bb..01d9ccb 100644 --- a/ui/aura/native_window_occlusion_tracker_win.cc +++ b/ui/aura/native_window_occlusion_tracker_win.cc
@@ -315,6 +315,8 @@ // The window was destroyed while processing occlusion. if (it == hwnd_root_window_map_.end()) continue; + it->second->GetHost()->set_on_current_workspace( + root_window_pair.second.on_current_workspace); // Check Window::IsVisible here, on the UI thread, because it can't be // checked on the occlusion calculation thread. Do this first before // checking screen_locked_ or display_on_ so that hidden windows remain @@ -584,11 +586,13 @@ // Reset RootOcclusionState to a clean state. root_window_pair.second = {}; + root_window_pair.second.on_current_workspace = + IsWindowOnCurrentVirtualDesktop(hwnd); // IsIconic() checks for a minimized window. Immediately set the state of // minimized windows to HIDDEN. if (IsIconic(hwnd)) { root_window_pair.second.occlusion_state = Window::OcclusionState::HIDDEN; - } else if (IsWindowOnCurrentVirtualDesktop(hwnd) == false) { + } else if (root_window_pair.second.on_current_workspace == false) { // If window is not on the current virtual desktop, immediately // set the state of the window to OCCLUDED. root_window_pair.second.occlusion_state =
diff --git a/ui/aura/native_window_occlusion_tracker_win.h b/ui/aura/native_window_occlusion_tracker_win.h index 7e47a66..d6a1789 100644 --- a/ui/aura/native_window_occlusion_tracker_win.h +++ b/ui/aura/native_window_occlusion_tracker_win.h
@@ -20,6 +20,7 @@ #include "base/memory/weak_ptr.h" #include "base/task/sequenced_task_runner.h" #include "base/timer/timer.h" +#include "third_party/abseil-cpp/absl/types/optional.h" #include "third_party/skia/include/core/SkRegion.h" #include "ui/aura/aura_export.h" #include "ui/aura/window.h" @@ -75,7 +76,7 @@ // Tracks the occlusion state of HWNDs registered via Enable(). struct RootOcclusionState { Window::OcclusionState occlusion_state = Window::OcclusionState::UNKNOWN; - + absl::optional<bool> on_current_workspace; // If `occlusion_state` is VISIBLE, this gives the occluded region. It may // be empty (which indicates the the window is entirely visible). This is // relative to the origin of the HWND. In other words, it's in window
diff --git a/ui/aura/window_tree_host.h b/ui/aura/window_tree_host.h index 91d2236..a8135ae 100644 --- a/ui/aura/window_tree_host.h +++ b/ui/aura/window_tree_host.h
@@ -299,6 +299,20 @@ bool holding_pointer_moves() const { return holding_pointer_moves_; } +#if BUILDFLAG(IS_WIN) + // Returns whether a host's window is on the current workspace or not, + // absl::nullopt if the state is not known. + absl::optional<bool> on_current_workspace() const { + return on_current_workspace_; + }; + + // Determining if a host's window is on the current workspace can be very + // expensive COM call on Windows, so this caches that information. + void set_on_current_workspace(absl::optional<bool> on_current_workspace) { + on_current_workspace_ = on_current_workspace; + } +#endif // BUILDFLAG_(IS_WIN) + protected: friend class ScopedKeyboardHook; friend class TestScreen; // TODO(beng): see if we can remove/consolidate. @@ -436,6 +450,12 @@ // Keeps track of the occlusion state of the host, and used to send // notifications to observers when it changes. Window::OcclusionState occlusion_state_ = Window::OcclusionState::UNKNOWN; + + // This is set if we know whether the window is on the current workspace. + // This is useful on Windows, where a COM call is required to determine this, + // which can block the UI. The native window occlusion tracking code already + // figures this out, so it's cheaper to store the fact here. + absl::optional<bool> on_current_workspace_; SkRegion occluded_region_; base::ObserverList<WindowTreeHostObserver>::Unchecked observers_;
diff --git a/ui/display/manager/configure_displays_task.cc b/ui/display/manager/configure_displays_task.cc index 59d65ff..6485a85 100644 --- a/ui/display/manager/configure_displays_task.cc +++ b/ui/display/manager/configure_displays_task.cc
@@ -5,6 +5,7 @@ #include "ui/display/manager/configure_displays_task.h" #include <cstddef> +#include <string> #include "base/auto_reset.h" #include "base/bind.h" @@ -13,6 +14,7 @@ #include "base/logging.h" #include "base/metrics/histogram_functions.h" #include "base/metrics/histogram_macros.h" +#include "base/metrics/sparse_histogram.h" #include "base/numerics/safe_conversions.h" #include "ui/display/manager/display_manager_util.h" #include "ui/display/types/display_configuration_params.h" @@ -25,6 +27,12 @@ namespace { +// The epsilon by which a refresh rate value may drift. For example: +// 239.76Hz --> 240Hz. This value was chosen with the consideration of the +// refresh rate value drifts presented in the "Video Formats—Video ID Code and +// Aspect Ratios" table on p.40 of the CTA-861-G standard. +constexpr float kRefreshRateEpsilon = 0.5f; + // Because we do not offer hardware mirroring, the maximal number of external // displays that can be configured is limited by the number of available CRTCs, // which is usually three. Since the lifetime of the UMA using this value is one @@ -32,6 +40,15 @@ // its histogram (between 0 to 4 external monitors). constexpr int kMaxDisplaysCount = 5; +// Consolidates the UMA name prefix creation to one location, since it is used +// in many different call-sites. +const std::string GetUmaNamePrefixForRequest( + const DisplayConfigureRequest& request) { + return request.display->type() == DISPLAY_CONNECTION_TYPE_INTERNAL + ? std::string("ConfigureDisplays.Internal.Modeset.") + : std::string("ConfigureDisplays.External.Modeset."); +} + // Find the next best mode that is smaller than |request->mode|. The next best // mode is found by comparing resolutions, and if those are similar, comparing // refresh rates. If no mode is found, return nullptr. @@ -82,63 +99,79 @@ const int32_t kDisplayResolutionSamples[] = {1024, 1280, 1440, 1920, 2560, 3840, 5120, 7680}; -// Computes the index of the enum DisplayResolution. -// The index has to match the definition of the enum in enums.xml -int ComputeDisplayResolutionEnum(const DisplayMode* mode) { - if (!mode) - return 0; // Display is powered off +void UpdateResolutionUma(const DisplayConfigureRequest& request, + const std::string& uma_name) { + // Display is powered off. + if (!request.mode) + return; - const gfx::Size size = mode->size(); + // First, compute the index of the enum DisplayResolution. + // The index has to match the definition of the enum in enums.xml. + const uint32_t samples_list_size = std::size(kDisplayResolutionSamples); + const gfx::Size size = request.mode->size(); uint32_t width_idx = 0; uint32_t height_idx = 0; - for (; width_idx < std::size(kDisplayResolutionSamples); width_idx++) { + for (; width_idx < samples_list_size; width_idx++) { if (size.width() <= kDisplayResolutionSamples[width_idx]) break; } - for (; height_idx < std::size(kDisplayResolutionSamples); height_idx++) { + for (; height_idx < samples_list_size; height_idx++) { if (size.height() <= kDisplayResolutionSamples[height_idx]) break; } - if (width_idx == std::size(kDisplayResolutionSamples) || - height_idx == std::size(kDisplayResolutionSamples)) - return std::size(kDisplayResolutionSamples) * - std::size(kDisplayResolutionSamples) + - 1; // Overflow bucket - // Computes the index of DisplayResolution, starting from 1, since 0 is used - // when powering off the display. - return width_idx * std::size(kDisplayResolutionSamples) + height_idx + 1; + int display_resolution_index = 0; + if (width_idx == samples_list_size || height_idx == samples_list_size) { + // Check if we are in the overflow bucket. + display_resolution_index = samples_list_size * samples_list_size + 1; + } else { + // Compute the index of DisplayResolution, starting from 1, since 0 is used + // when powering off the display. + display_resolution_index = width_idx * samples_list_size + height_idx + 1; + } + + base::UmaHistogramExactLinear(uma_name, display_resolution_index, + samples_list_size * samples_list_size + 2); } -void UpdateResolutionAndRefreshRateUma(const DisplayConfigureRequest& request) { - const bool internal = - request.display->type() == DISPLAY_CONNECTION_TYPE_INTERNAL; +// A list of common refresh rates that are used to help fit approximate refresh +// rate values into one of the common refresh rate bins. +constexpr float kCommonDisplayRefreshRates[] = { + 24.0, 25.0, 30.0, 45.0, 48.0, 50.0, 60.0, 75.0, + 90.0, 100.0, 120.0, 144.0, 165.0, 200.0, 240.0}; - base::UmaHistogramExactLinear( - internal ? "ConfigureDisplays.Internal.Modeset.Resolution" - : "ConfigureDisplays.External.Modeset.Resolution", - ComputeDisplayResolutionEnum(request.mode), - std::size(kDisplayResolutionSamples) * - std::size(kDisplayResolutionSamples) + - 2); +void UpdateRefreshRateUma(const DisplayConfigureRequest& request, + const std::string& uma_name) { + // Display is powered off. + if (!request.mode) + return; - base::HistogramBase* histogram = base::LinearHistogram::FactoryGet( - internal ? "ConfigureDisplays.Internal.Modeset.RefreshRate" - : "ConfigureDisplays.External.Modeset.RefreshRate", - 1, 240, 18, base::HistogramBase::kUmaTargetedHistogramFlag); - histogram->Add(request.mode ? std::round(request.mode->refresh_rate()) : 0); + base::HistogramBase* histogram = base::SparseHistogram::FactoryGet( + uma_name, base::HistogramBase::kUmaTargetedHistogramFlag); + + // Check if the refresh value is within an epsilon from one of the common + // refresh rate values. + for (size_t i = 0; i < std::size(kCommonDisplayRefreshRates); ++i) { + const bool is_within_epsilon = + std::abs(request.mode->refresh_rate() - kCommonDisplayRefreshRates[i]) < + kRefreshRateEpsilon; + if (is_within_epsilon) { + histogram->Add(kCommonDisplayRefreshRates[i]); + return; + } + } + + // Since this is not a common refresh rate value, report it as is. + histogram->Add(request.mode->refresh_rate()); } void UpdateAttemptSucceededUma( const std::vector<DisplayConfigureRequest>& requests, bool display_success) { for (const auto& request : requests) { - const bool internal = - request.display->type() == DISPLAY_CONNECTION_TYPE_INTERNAL; - base::UmaHistogramBoolean( - internal ? "ConfigureDisplays.Internal.Modeset.AttemptSucceeded" - : "ConfigureDisplays.External.Modeset.AttemptSucceeded", - display_success); + const std::string uma_name_prefix = GetUmaNamePrefixForRequest(request); + base::UmaHistogramBoolean(uma_name_prefix + "AttemptSucceeded", + display_success); VLOG(2) << "Configured status=" << display_success << " display=" << request.display->display_id() @@ -155,19 +188,21 @@ const DisplayConfigureRequest& request = request_and_status.first; // Is this display SST (single-stream vs. MST multi-stream). - bool sst_display = request.display->base_connector_id() && - request.display->path_topology().empty(); + const bool sst_display = request.display->base_connector_id() && + request.display->path_topology().empty(); if (!sst_display) mst_external_displays++; - bool internal = request.display->type() == DISPLAY_CONNECTION_TYPE_INTERNAL; - if (internal) + if (request.display->type() == DISPLAY_CONNECTION_TYPE_INTERNAL) total_external_displays--; - base::UmaHistogramBoolean( - internal ? "ConfigureDisplays.Internal.Modeset.FinalStatus" - : "ConfigureDisplays.External.Modeset.FinalStatus", - request_and_status.second); + const std::string uma_name_prefix = GetUmaNamePrefixForRequest(request); + if (request_and_status.second) { + UpdateResolutionUma(request, uma_name_prefix + "Success.Resolution"); + UpdateRefreshRateUma(request, uma_name_prefix + "Success.RefreshRate"); + } + base::UmaHistogramBoolean(uma_name_prefix + "FinalStatus", + request_and_status.second); } base::UmaHistogramExactLinear( @@ -212,6 +247,7 @@ void ConfigureDisplaysTask::Run() { DCHECK(!requests_.empty()); + const bool is_first_attempt = pending_display_group_requests_.empty(); std::vector<display::DisplayConfigurationParams> config_requests; for (const auto& request : requests_) { LogIfInvalidRequestForInternalDisplay(request); @@ -219,13 +255,16 @@ config_requests.emplace_back(request.display->display_id(), request.origin, request.mode); - UpdateResolutionAndRefreshRateUma(request); + if (is_first_attempt) { + const std::string uma_name_prefix = GetUmaNamePrefixForRequest(request); + UpdateResolutionUma(request, + uma_name_prefix + "OriginalRequest.Resolution"); + } } const auto& on_configured = - pending_display_group_requests_.empty() - ? &ConfigureDisplaysTask::OnFirstAttemptConfigured - : &ConfigureDisplaysTask::OnRetryConfigured; + is_first_attempt ? &ConfigureDisplaysTask::OnFirstAttemptConfigured + : &ConfigureDisplaysTask::OnRetryConfigured; delegate_->Configure( config_requests,
diff --git a/ui/views/widget/desktop_aura/desktop_native_widget_aura.cc b/ui/views/widget/desktop_aura/desktop_native_widget_aura.cc index e5a3e90..987d0ae 100644 --- a/ui/views/widget/desktop_aura/desktop_native_widget_aura.cc +++ b/ui/views/widget/desktop_aura/desktop_native_widget_aura.cc
@@ -887,10 +887,8 @@ const gfx::Rect& restore_bounds) { if (!content_window_) return; - // Avoid changing desktop window visibility state when browser is running in - // headless mode, see https://crbug.com/1237546. - if (!headless_mode_) - desktop_window_tree_host_->Show(show_state, restore_bounds); + + desktop_window_tree_host_->Show(show_state, restore_bounds); } void DesktopNativeWidgetAura::Hide() {
diff --git a/ui/views/widget/desktop_aura/desktop_native_widget_aura.h b/ui/views/widget/desktop_aura/desktop_native_widget_aura.h index 3fb6734..c1f79975 100644 --- a/ui/views/widget/desktop_aura/desktop_native_widget_aura.h +++ b/ui/views/widget/desktop_aura/desktop_native_widget_aura.h
@@ -113,6 +113,9 @@ // DesktopWindowTreeHost's transparency. void UpdateWindowTransparency(); + // Returns true if the desktop window was created in headless mode. + bool IsHeadlessMode() const { return headless_mode_; } + protected: // internal::NativeWidgetPrivate: void InitNativeWidget(Widget::InitParams params) override;
diff --git a/ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc b/ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc index ece3dfb..2715b3a1 100644 --- a/ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc +++ b/ui/views/widget/desktop_aura/desktop_window_tree_host_win.cc
@@ -802,6 +802,10 @@ return native_widget_delegate_->IsModal(); } +bool DesktopWindowTreeHostWin::IsHeadless() const { + return desktop_native_widget_aura_->IsHeadlessMode(); +} + int DesktopWindowTreeHostWin::GetInitialShowState() const { return CanActivate() ? SW_SHOWNORMAL : SW_SHOWNOACTIVATE; }
diff --git a/ui/views/widget/desktop_aura/desktop_window_tree_host_win.h b/ui/views/widget/desktop_aura/desktop_window_tree_host_win.h index 444581249..acd6f44 100644 --- a/ui/views/widget/desktop_aura/desktop_window_tree_host_win.h +++ b/ui/views/widget/desktop_aura/desktop_window_tree_host_win.h
@@ -205,6 +205,7 @@ bool WantsMouseEventsWhenInactive() const override; bool WidgetSizeIsClientSize() const override; bool IsModal() const override; + bool IsHeadless() const override; int GetInitialShowState() const override; int GetNonClientComponent(const gfx::Point& point) const override; void GetWindowMask(const gfx::Size& size, SkPath* path) override;
diff --git a/ui/views/win/hwnd_message_handler.cc b/ui/views/win/hwnd_message_handler.cc index 2b69f47..4b8e6a7 100644 --- a/ui/views/win/hwnd_message_handler.cc +++ b/ui/views/win/hwnd_message_handler.cc
@@ -694,6 +694,14 @@ break; } + // In headless mode the platform window is always hidden, so instead of + // showing it just maintain a local flag to track the expected headless + // window visibility state. + if (delegate_->IsHeadless()) { + headless_window_visibility_state_ = true; + return; + } + ShowWindow(hwnd(), native_show_state); // When launched from certain programs like bash and Windows Live // Messenger, show_state is set to SW_HIDE, so we need to correct that @@ -720,6 +728,14 @@ } void HWNDMessageHandler::Hide() { + // In headless mode the platform window is always hidden, so instead of + // hiding it just maintain a local flag to track the expected headless + // window visibility state. + if (delegate_->IsHeadless()) { + headless_window_visibility_state_ = false; + return; + } + if (IsWindow(hwnd())) { // NOTE: Be careful not to activate any windows here (for example, calling // ShowWindow(SW_HIDE) will automatically activate another window). This @@ -772,7 +788,11 @@ } bool HWNDMessageHandler::IsVisible() const { - return !!::IsWindowVisible(hwnd()); + // In headless mode the platform window is always hidden, so instead of + // returning the actual window visibility state return the expected visibility + // state maintained by Show/Hide() calls. + return delegate_->IsHeadless() ? headless_window_visibility_state_ + : !!::IsWindowVisible(hwnd()); } bool HWNDMessageHandler::IsActive() const { @@ -907,6 +927,10 @@ } void HWNDMessageHandler::SetFullscreen(bool fullscreen) { + // Avoid setting fullscreen mode when in headless mode. + if (delegate_->IsHeadless()) + return; + background_fullscreen_hack_ = false; auto ref = msg_handler_weak_factory_.GetWeakPtr(); fullscreen_handler()->SetFullscreen(fullscreen);
diff --git a/ui/views/win/hwnd_message_handler.h b/ui/views/win/hwnd_message_handler.h index f4efdc71..b6fd6bb6 100644 --- a/ui/views/win/hwnd_message_handler.h +++ b/ui/views/win/hwnd_message_handler.h
@@ -810,6 +810,11 @@ // call HandleWindowMinimizedOrRestored() when we get a WM_ACTIVATE message. bool notify_restore_on_activate_ = false; + // This tracks headless window visibility state. In headless mode + // the platform window is always hidden, so we use this boolean + // to track the window's requested visibility state. + bool headless_window_visibility_state_ = false; + // This is a map of the HMONITOR to full screeen window instance. It is safe // to keep a raw pointer to the HWNDMessageHandler instance as we track the // window destruction and ensure that the map is cleaned up.
diff --git a/ui/views/win/hwnd_message_handler_delegate.h b/ui/views/win/hwnd_message_handler_delegate.h index d8e0f1d..caff85f 100644 --- a/ui/views/win/hwnd_message_handler_delegate.h +++ b/ui/views/win/hwnd_message_handler_delegate.h
@@ -78,6 +78,9 @@ // Returns true if the delegate represents a modal window. virtual bool IsModal() const = 0; + // Returns true if the delegate represents a headless window. + virtual bool IsHeadless() const = 0; + // Returns the show state that should be used for the application's first // window. virtual int GetInitialShowState() const = 0;
diff --git a/url/gurl.cc b/url/gurl.cc index fd8e35c..e013646 100644 --- a/url/gurl.cc +++ b/url/gurl.cc
@@ -439,12 +439,16 @@ } std::string GURL::GetContent() const { + return std::string(GetContentPiece()); +} + +base::StringPiece GURL::GetContentPiece() const { if (!is_valid_) - return std::string(); - std::string content = ComponentString(parsed_.GetContent()); + return base::StringPiece(); + url::Component content_component = parsed_.GetContent(); if (!SchemeIs(url::kJavaScriptScheme) && parsed_.ref.len >= 0) - content.erase(content.size() - parsed_.ref.len - 1); - return content; + content_component.len -= parsed_.ref.len + 1; + return ComponentStringPiece(content_component); } bool GURL::HostIsIPAddress() const {
diff --git a/url/gurl.h b/url/gurl.h index af401ef..8f4884c 100644 --- a/url/gurl.h +++ b/url/gurl.h
@@ -278,6 +278,7 @@ // It is an error to get the content of an invalid URL: the result will be an // empty string. std::string GetContent() const; + base::StringPiece GetContentPiece() const; // Returns true if the hostname is an IP address. Note: this function isn't // as cheap as a simple getter because it re-parses the hostname to verify.
diff --git a/url/gurl_unittest.cc b/url/gurl_unittest.cc index 4be6e41..c55c5bc 100644 --- a/url/gurl_unittest.cc +++ b/url/gurl_unittest.cc
@@ -929,6 +929,7 @@ for (const auto& test : cases) { GURL url(test.url); EXPECT_EQ(test.expected, url.GetContent()) << test.url; + EXPECT_EQ(test.expected, url.GetContentPiece()) << test.url; } }