Context: https://ci.chromium.org/p/chromium/builders/luci.chromium.try/linux-chromeos-rel/4989
two jobs fail in mash_browser_tests:
- ModeIndicatorBrowserTest.NumOfWidgets
- ModeIndicatorBrowserTest.Bounds
void DesktopWindowTreeHostMus::SetBoundsInPixels() clamps the |size| passed to CenterWindow to WidgetDelegate::GetMin/MaximumSize
NativeWidgetAura and DesktopWindowTreeHostX11 do not
DesktopWindowTreeHostX11 does
NativeWidgetMac does not.
It's unlikely there's a bug -- calls to CenterWindow are almost always overridden by a call to SetBounds just after a Widget is created.
Widget calls CenterWindow during initializtion by passing non_client_view_->GetPreferredSize() -- (clients should never give a preferred size that disagrees with their min/max size). But it can also be called via Widget::CenterWindow.
ModeIndicatorBrowserTest fails on https://chromium-review.googlesource.com/c/chromium/src/+/790175 because ModeIndicatorView is a BubbleDialogDelegateView but it provides a custom ModeIndicatorFrameView inheriting from BubbleFrameView directly rather than relying on BubbleDialogDelegateView::CreateNonClientFrameView().
But it only fails on Mus (it should fail on non-mus as well except for this bug).