New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 650898 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Closed: Dec 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Mac
Pri: 3
Type: Bug

Blocking:
issue 665691



Sign in to add a comment

SSLClientCertificateSelectorCocoaTest.HideShow fails on macOS-Sierra

Project Member Reported by erikc...@chromium.org, Sep 28 2016

Issue description

[ RUN      ] SSLClientCertificateSelectorCocoaTest.HideShow
2016-09-27 16:55:12.310 browser_tests[30443:2012362] NSWindow warning: adding an unknown subview: <FullSizeContentView: 0x7f968f4627f0>. Break on NSLog to debug.
2016-09-27 16:55:12.310 browser_tests[30443:2012362] Call stack:
(
    "+callStackSymbols disabled for performance reasons"
)
../../chrome/browser/ui/cocoa/ssl_client_certificate_selector_cocoa_browsertest.mm:114: Failure
Value of: [sheetWindow frame]
  Actual: {{-207, -205}, {415, 206}}
Expected: ui::kWindowSizeDeterminedLater
Which is: {{0, 0}, {1, 1}}
[  FAILED  ] SSLClientCertificateSelectorCocoaTest.HideShow, where TypeParam =  and GetParam() =  (1586 ms)
[----------] 1 test from SSLClientCertificateSelectorCocoaTest (1586 ms total)

[----------] Global test environment tear-down
[==========] 1 test from 1 test case ran. (1586 ms total)
[  PASSED  ] 0 tests.
[  FAILED  ] 1 test, listed below:
[  FAILED  ] SSLClientCertificateSelectorCocoaTest.HideShow, where TypeParam =  and GetParam() = 

 1 FAILED TEST
[1/1] SSLClientCertificateSelectorCocoaTest.HideShow (1846 ms)
1 test failed:
    SSLClientCertificateSelectorCocoaTest.HideShow (../../chrome/browser/ui/cocoa/ssl_client_certificate_selector_cocoa_browsertest.mm:95)
 

Comment 1 by mmenke@chromium.org, Sep 28 2016

Components: -Internals>Network Internals>Network>Certificate
I guess this is Internals>Network>Certificate, and not Internals>Network>SSL?
Cc: tapted@chromium.org ellyjo...@chromium.org shrike@chromium.org
Sounds like Mac-Views issue; is there a better category for these?

(CC'ing based on  Issue 643123 )
Owner: tapted@chromium.org
Status: Assigned (was: Untriaged)
MacViews is not used for any UI by default, so this isn't a MacViews bug, just a general mac UI bug. tapted@ is probably a good candidate.

Comment 4 by tapted@chromium.org, Sep 29 2016

Owner: patricia...@chromium.org
I'll bump this to patti, since she's been deep in this logic. Specifically the test is:

  // Switch to another tab and verify that the sheet is hidden.
  AddBlankTabAndShow(browser());
  EXPECT_EQ(0.0, [sheetWindow alphaValue]);
  EXPECT_NSEQ(ui::kWindowSizeDeterminedLater, [sheetWindow frame]);


The first EXPECT succeeds, the second fails. But I think that's fine - this is actually a bug that patti fixed in r400627 - moving an invisible window to ui::kWindowSizeDeterminedLater actually makes the bottom left corner pixel of the screen unclickable. r400627 fixed that.

The weirder things to investigate are
 - why isn't this failing on other OSX versions already
 - why is [sheetWindow frame] getting a negative origin
 - is tab-switching with the SSL certificate showing actually working OK in Sierra (I did some spot checks earlier and it seemed fine, but patti knows all the corner cases better than I do).
I tested beta build 54.0.2840.50 on 10.12 Sierra and the SSL Client Certificate selection box is displayed and allows me to log into a website with a certificate.
Blocking: 665691
Ping, this is now blocking our 10.12 rollout.
Thanks for the heads up on this Erik. The expectation that this test was failing on has been replaced (in r400627, as Trent mentioned). The test seems to be passing fine as well on Sierra, but I did a couple manual checks and it seems like the invisible overlay window which is used to block interaction with the tab while the certificate viewer is open isn't working again when switching between two tabs with certificate viewers open. (The first certificate viewer becomes unclickable, but is still key window.) I'm not sure why this is the case, will look into that now.
Cc: sdy@chromium.org mattm@chromium.org
While poking around some unconverted dialogs, I realised that this is actually the SSLCertificate *Selector* not the SSLCertificate *Viewer*.

So this test might actually be failing (indirectly?) because of  Issue 653093  ~"AppKit does dodgy stuff with SFChooseIdentityPanel on macOS 10.12 Sierra"

There is also Issue 671889 "SecTrustSetKeychains does not work on Mac OS 10.12", and  Issue 666733  "[Mac] Client certificate modal is not keyboard-navigable".

One option available is to put the client certificate selection dialog behind --secondary-ui-md on Mac. But that might be too big a change. We currently use a (mostly) OS-provided dialog (similar to the SSL certificate viewer). Also the toolkit-views dialog has a views::TableView which lacks a good deal of polish (and is the reason we are deferring conversion of the task manager).
You're right Trent, I was also looking at the certificate viewer instead of the selector. Not sure how to answer the questions you had in #c4, but the test can be fixed by applying the same code used for the certificate viewer to the selector in this CL: https://codereview.chromium.org/2559763003/. This introduces the unclickable-ness to the certificate selector now though too (mentioned in #c7), so there's a fix for the certificate viewer (Cocoa + MacViews) and the certificate selector in a follow-up here: https://codereview.chromium.org/2562653002/.
Project Member

Comment 10 by bugdroid1@chromium.org, Dec 13 2016

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

commit 88fc23eb6caa37caec392c54ceeab245e5adaac3
Author: patricialor <patricialor@chromium.org>
Date: Tue Dec 13 05:40:20 2016

Mac: Fix SSLClientCertificateSelectorCocoaTest.HideShow (fails on macOS Sierra).

SSLClientCertificateSelectorCocoaTest.HideShow is failing on macOS Sierra,
blocking 10.12 rollout for Chrome. Fix this using the same refactor as seen in
r400627, which ignores mouse events instead of resizing the certificate selector
window when it's hidden.

BUG= 650898 

Review-Url: https://codereview.chromium.org/2559763003
Cr-Commit-Position: refs/heads/master@{#438065}

[modify] https://crrev.com/88fc23eb6caa37caec392c54ceeab245e5adaac3/chrome/browser/ui/cocoa/ssl_client_certificate_selector_cocoa.h
[modify] https://crrev.com/88fc23eb6caa37caec392c54ceeab245e5adaac3/chrome/browser/ui/cocoa/ssl_client_certificate_selector_cocoa.mm
[modify] https://crrev.com/88fc23eb6caa37caec392c54ceeab245e5adaac3/chrome/browser/ui/cocoa/ssl_client_certificate_selector_cocoa_browsertest.mm

Status: Fixed (was: Assigned)
As mentioned previously, the above change introduces  Issue 671150  to the certificate selector also (along with the certificate viewer for MacViews and Cocoa for which it already exists). Since 671150 is a rare repro case and it's easy to recover from it, putting that on the backburner (see bug for more details). Closing this bug as fixed now :)

Sign in to add a comment