• David Benjamin's avatar
    Extensions logic should not participate in LoginHandler dedup. · 11badda3
    David Benjamin authored
    In the network service path, the extensions onAuthRequired hook is
    implemented up in LoginHandler, rather than deep in the NetworkDelegate.
    
    This causes it to inherit the login prompt deduplication logic, which
    results in strange behavior for an extension. Fix this by only
    deduplicating after the extension stuff is resolved, matching the
    pre-network-service behavior.
    
    This also fixes the test that was disabled in issue #928465. (Mostly.
    That test is still making some *slightly* incorrect timing assumptions,
    but this no longer makes the issue net-svc-specific, so remove the test
    suppression and add a TODO to the effect.)
    
    Also add a regression test. In doing so, generalize retval_function to
    control when the callback is called, and fix a bug around finding the
    right retval_function to use.
    
    Bug: 931479, 928465
    Change-Id: I0431b115f64f145ed4201b8944e86b56994ec1fd
    Reviewed-on: https://chromium-review.googlesource.com/c/1469289
    Commit-Queue: David Benjamin <davidben@chromium.org>
    Reviewed-by: default avatarCarlos IL <carlosil@chromium.org>
    Reviewed-by: default avatarKaran Bhatia <karandeepb@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#634445}
    11badda3
login_handler.cc 25 KB