commit | 0db267e941f1c227914d20cc272617188bd3fd04 | [log] [tgz] |
---|---|---|
author | Vaclav Brozek <vabr@chromium.org> | Wed Dec 06 10:36:25 2017 |
committer | Commit Bot <commit-bot@chromium.org> | Wed Dec 06 10:36:25 2017 |
tree | 591ba4c1d0af889f361f9991347b3b4c5d49b3cb | |
parent | 8dea498d5fcc87730ac1f9e294d08a053184e68c [diff] |
Allow mocking PasswordUIView.java Tests are needed for viewing passwords in settings. Those tests need an easy way to mock PasswordUIView, which communicates with C++ in the production version. Therefore this CL does: (1) Define an interface, PasswordManagerHandler, for the public methods of PasswordUIView to be mocked in the tests (coming in https://crrev.com/c/797453). (2) Create PasswordManagerHandlerProvider which encapsulates the logic for managing observers, life-time and test-replacement of the PasswordManagerHandler implementations. (3) Lift SavedPasswordEntry to top level for reasons explained in its class comment. This CL should not change any functionality, so current test coverage is assumed to be sufficient for the new code. The new tests are postponed until https://crrev.com/c/797453, which also introduces other test utilities to make writing them less of a pain. Bug: 788701 Change-Id: I2b90a613065df50cad85de85ffa620a88df61a6e Reviewed-on: https://chromium-review.googlesource.com/806155 Commit-Queue: Vaclav Brozek <vabr@chromium.org> Reviewed-by: Tommy Nyquist <nyquist@chromium.org> Cr-Commit-Position: refs/heads/master@{#522059}
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure .